{
  "version": 3,
  "sources": ["/cdn/shop/t/35/assets/custom-st-rc-dev.js?test=25112025319"],
  "sourcesContent": ["$(document).ready(function() {\r\n    console.log(`[EQ] - DEBUG: Initializing custom-st-rc-dev.js.liquid for Recharge Portal - Production.`);\r\n});\r\n\r\nconst take_payment_now_delay_time = 5;\r\n  const post_take_payment_now_text_delivery = `<span>Your next delivery:</span><p class=\"post-take-payment-now-text\" style=\"line-height:1.3;\">It looks like your payment was taken in the last 5 minutes - if the delivery date isn't what you were expecting then please check back in a few minutes once the system has had a chance to update!</p>`;\r\n\r\n  const post_take_payment_now_text_payment = `<span>Your next payment:</span><br/><br/><p class=\"post-take-payment-now-text\" style=\"line-height:1.3;\">It looks like your payment was taken in the last 5 minutes - if the delivery date isn't what you were expecting then please check back in a few minutes once the system has had a chance to update!</p>`;\r\n  \r\n  function updateTemporaryDeliveryData(doCheckForTiming, nextDeliveryFormatedDate = \"\", nextPaymentFormatedDate = \"\") {\r\n    if(doCheckForTiming) {\r\n      if( isWithinTimeLimit('takePaymentNow',take_payment_now_delay_time) ) {\r\n        if(typeof nextDeliveryFormatedDate != \"undefined\" && nextDeliveryFormatedDate != null && nextDeliveryFormatedDate != \"\" && \r\n         typeof nextPaymentFormatedDate != \"undefined\" && nextPaymentFormatedDate != null && nextPaymentFormatedDate != \"\")\r\n        {\r\n          var post_take_payment_now_text_delivery_new = `<span>Your next delivery</span><h1>`+nextDeliveryFormatedDate+`</h1><p class=\"post-take-payment-now-text\" style=\"line-height:1.3;\">It looks like your payment was taken in the last 5 minutes - if the delivery date isn't what you were expecting then please check back in a few minutes once the system has had a chance to update!</p>`;\r\n          var post_take_payment_now_text_payment_new = `<span>Your next payment will be taken:</span><br/><br/><h2 role=\"heading\" aria-level=\"2\" class=\"_15b7gxl0 recharge-heading recharge-heading-h1 _1brvylo1 _1brvylo0 _1brvylo4 _1brvylo8 _1brvylob\">`+nextPaymentFormatedDate+`</h2><br/><p class=\"post-take-payment-now-text\" style=\"line-height:1.3;\">It looks like your payment was taken in the last 5 minutes - if the delivery date isn't what you were expecting then please check back in a few minutes once the system has had a chance to update!</p>`;\r\n          $(\".custom-recent-order-slot\").html(post_take_payment_now_text_delivery_new);\r\n          $(\".custom-header-slot\").html(post_take_payment_now_text_delivery_new);\r\n          $(\".recharge-section-next-order-actions .recharge-card\").html(post_take_payment_now_text_payment_new);  \r\n        }\r\n        else\r\n        {\r\n          $(\".custom-recent-order-slot\").html(post_take_payment_now_text_delivery);\r\n          $(\".custom-header-slot\").html(post_take_payment_now_text_delivery);\r\n          $(\".recharge-section-next-order-actions .recharge-card\").html(post_take_payment_now_text_payment);  \r\n        }\r\n      } else {\r\n        //DO NOTHING\r\n      }\r\n    } else {\r\n      if(typeof nextDeliveryFormatedDate != \"undefined\" && nextDeliveryFormatedDate != null && nextDeliveryFormatedDate != \"\" && \r\n         typeof nextPaymentFormatedDate != \"undefined\" && nextPaymentFormatedDate != null && nextPaymentFormatedDate != \"\")\r\n      {\r\n        var post_take_payment_now_text_delivery_new = `<span>Your next delivery</span><h1>`+nextDeliveryFormatedDate+`</h1><p class=\"post-take-payment-now-text\" style=\"line-height:1.3;\">It looks like your payment was taken in the last 5 minutes - if the delivery date isn't what you were expecting then please check back in a few minutes once the system has had a chance to update!</p>`;\r\n        var post_take_payment_now_text_payment_new = `<span>Your next payment will be taken:</span><br/><br/><h2 role=\"heading\" aria-level=\"2\" class=\"_15b7gxl0 recharge-heading recharge-heading-h1 _1brvylo1 _1brvylo0 _1brvylo4 _1brvylo8 _1brvylob\">`+nextPaymentFormatedDate+`</h2><br/><p class=\"post-take-payment-now-text\" style=\"line-height:1.3;\">It looks like your payment was taken in the last 5 minutes - if the delivery date isn't what you were expecting then please check back in a few minutes once the system has had a chance to update!</p>`;\r\n        $(\".custom-recent-order-slot\").html(post_take_payment_now_text_delivery_new);\r\n        $(\".custom-header-slot\").html(post_take_payment_now_text_delivery_new);\r\n        $(\".recharge-section-next-order-actions .recharge-card\").html(post_take_payment_now_text_payment_new);  \r\n      }\r\n      else\r\n      {\r\n        $(\".custom-recent-order-slot\").html(post_take_payment_now_text_delivery);\r\n        $(\".custom-header-slot\").html(post_take_payment_now_text_delivery);\r\n        $(\".recharge-section-next-order-actions .recharge-card\").html(post_take_payment_now_text_payment);  \r\n      }\r\n    }    \r\n  }\r\n\r\n  function storeDetailWithTimestamp(key, detail) {\r\n    const data = {\r\n        detail: detail,\r\n        timestamp: new Date().toISOString()\r\n    };\r\n    localStorage.setItem(key, JSON.stringify(data));\r\n    console.log(`Stored data with key: ${key} : ${data}`);\r\n  }\r\n\r\n  function isWithinTimeLimit(key, timeLimitMinutes = 10) {\r\n    const data = localStorage.getItem(key);\r\n    if (!data) return false; // If key does not exist, return false\r\n\r\n    const parsedData = JSON.parse(data);\r\n    const storedTimestamp = new Date(parsedData.timestamp).getTime();\r\n    const currentTimestamp = new Date().getTime();\r\n\r\n    // Convert minutes to milliseconds\r\n    const timeLimitMs = timeLimitMinutes * 60 * 1000;\r\n    return (currentTimestamp - storedTimestamp) <= timeLimitMs;\r\n  }\r\n\r\n  var demo = $(location).attr('href');\r\n  var mySubString = demo.split('portal/').pop().split('/')[0];\r\n\r\n  if (typeof window.recharge_live_order_text != \"undefined\" && window.recharge_live_order_text != null && window.recharge_live_order_text != \"\") {\r\n    var recharge_live_order_text_data = window.recharge_live_order_text\r\n  } else {\r\n    var recharge_live_order_text_data = \"You've already paid for this order, due for delivery on {date}. Any changes made here won't be reflected in this order, contact the team at team@stockedfood.com to make changes!\"\r\n  }\r\n  if (typeof window.recharge_out_of__delivery_text != \"undefined\" && window.recharge_out_of__delivery_text != null && window.recharge_out_of__delivery_text != \"\") {\r\n    var recharge_out_of__delivery_text_data = window.recharge_out_of__delivery_text\r\n  } else {\r\n    var recharge_out_of__delivery_text_data = \"Your order is out for delivery and will be with you on {date}.\"\r\n  }\r\n  if (typeof window.recharge_date_not_found_error_text != \"undefined\" && window.recharge_date_not_found_error_text != null && window.recharge_date_not_found_error_text != \"\") {\r\n    var recharge_date_not_found_error_text_data = window.recharge_date_not_found_error_text\r\n  } else {\r\n    var recharge_date_not_found_error_text_data = \"There seems to be an issue displaying your next delivery date. Check again later or reach out to us at team@stockedfood.com\"\r\n  }\r\n  if (typeof window.recharge_reschedule_popup_text != \"undefined\" && window.recharge_reschedule_popup_text != null && window.recharge_reschedule_popup_text != \"\") {\r\n    var recharge_reschedule_popup_text_data = window.recharge_reschedule_popup_text\r\n  } else {\r\n    var recharge_reschedule_popup_text_data = \"When would you like your next payment? (This isn't delivery date. For delivery date info, contact us on Whatsapp or at team@stockedfood.com)\"\r\n  }\r\n  if (typeof window.recharge_schedule_changes_text != \"undefined\" && window.recharge_schedule_changes_text != null && window.recharge_schedule_changes_text != \"\") {\r\n    var recharge_schedule_changes_text_data = window.recharge_schedule_changes_text\r\n  } else {\r\n    var recharge_schedule_changes_text_data = 'Schedule changes will apply to all future orders.'\r\n  }\r\n  if (typeof window.recharge_schedule_order_count_text != \"undefined\" && window.recharge_schedule_order_count_text != null && window.recharge_schedule_order_count_text != \"\") {\r\n    var recharge_schedule_order_count_text_data = window.recharge_schedule_order_count_text\r\n  } else {\r\n    var recharge_schedule_order_count_text_data = 'You have scheduled orders on days with borders'\r\n  }\r\n\r\n  var script = document.createElement('script');\r\n  script.src = \"https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.js\";\r\n  document.getElementsByTagName('head')[0].appendChild(script);\r\n\r\n  var element = document.createElement(\"link\");\r\n  element.setAttribute(\"rel\", \"stylesheet\");\r\n  element.setAttribute(\"type\", \"text/css\");\r\n  element.setAttribute(\"href\", \"//code.jquery.com/ui/1.13.2/themes/base/jquery-ui.css\");\r\n  document.getElementsByTagName(\"head\")[0].appendChild(element);\r\n\r\n  var waitForEl = function (selector, callback) {\r\n    if (jQuery(selector).length) {\r\n      callback();\r\n    } else {\r\n      setTimeout(function () {\r\n        waitForEl(selector, callback);\r\n      }, 100);\r\n    }\r\n  };\r\n\r\n  function main_recharge_working(e) {\r\n    var rechargepageurl = window.location.href;\r\n    if (rechargepageurl.indexOf(\"/overview?\") != -1 && rechargepageurl.indexOf(\"subscription=\") === -1) {\r\n      waitForEl(\".recharge-section-next-order-actions\", function () {\r\n        working_recharge();\r\n      })\r\n    }\r\n\r\n    if (rechargepageurl.indexOf(\"/subscriptions/\") != -1) {\r\n      waitForEl(\".recharge-component-subscription-details [data-recharge-subscription-actions='true']\", function () {\r\n        working_recharge();\r\n      });\r\n    }\r\n\r\n    if (rechargepageurl.indexOf(\"/overview?\") != -1 && rechargepageurl.indexOf(\"subscription=\") != -1) {\r\n      waitForEl(\".recharge-section-next-order-actions\", function () {\r\n        working_recharge();\r\n      })\r\n    }\r\n\r\n    if (rechargepageurl.indexOf(\"/schedule\") != -1) {\r\n      working_recharge();\r\n    }\r\n\r\n    function working_recharge() {\r\n      $('.recharge-section-next-order-actions').prepend($('<div class=\"loading-custom-recharge-content\"><span></span></div>'));\r\n      $('.recharge-component-subscription-details').prepend($('<div class=\"loading-custom-recharge-content\"><span></span></div>'));\r\n      let total_future_delivery = \"\";\r\n      let active_sub_id = \"\";\r\n      let provided_properties_array = \"\";\r\n      let customer_recharge_id = \"\";\r\n      let pass_del_date = \"\";\r\n      let calculation_active_sub_next_charge_date = \"\";\r\n      let customer_shopify_order_id = \"\";\r\n      let orderfulfillment_status = \"\";\r\n      let hasdeliverypropertiesdateadded = false;\r\n\r\n      var scheduledate = \"\";\r\n      let counter = 0;\r\n\r\n      $.ajax({\r\n        url: \"https://stockedfood.eqserver.net/fetchCustomerDetail/\" + mySubString,\r\n        method: \"GET\",\r\n        dataType: \"JSON\",\r\n        headers: {\r\n          \"Content-type\": \"application/json\"\r\n        },\r\n        success: function (resultdata) {\r\n          customer_recharge_id = resultdata.data.Customer[0].id;\r\n\r\n          $.ajax({\r\n            url: \"https://stockedfood.eqserver.net/getDeliverySchedules/\" + customer_recharge_id,\r\n            method: \"GET\",\r\n            dataType: \"JSON\",\r\n            headers: {\r\n              \"Content-type\": \"application/json\"\r\n            },\r\n            success: function (result) {\r\n              var newdeliveryarray = [];\r\n              $(result.customerDeliveriesData.deliveries).each(function (key, value) {\r\n                var ex_payment_date = value.date;\r\n                var ex_deliverty_dates = value.orders[0].line_items[0].properties;\r\n\r\n                for (var x in ex_deliverty_dates) {\r\n                  if (ex_deliverty_dates[x]['name'] == \"_Delivery Date Preference\") {\r\n                    var ex_deliverty_dates_value = ex_deliverty_dates[x]['value'];\r\n                    if (typeof ex_deliverty_dates_value != \"undefined\" && ex_deliverty_dates_value != null && ex_deliverty_dates_value != \"\") {\r\n                      var dateparts = ex_deliverty_dates_value.split('.');\r\n                      var convertedDateD1 = dateparts[2] + '-' + dateparts[1] + '-' + dateparts[0];\r\n                      const dfl_delivery_date = new Date(convertedDateD1);\r\n                      let dfl_delivery_dateweek_day = dfl_delivery_date.getDay();\r\n                      if (dfl_delivery_dateweek_day == 1) {\r\n                        var xpro = new Date(ex_payment_date);\r\n                        var nextThreeDays = new Date(xpro.setDate(xpro.getDate() + 1));\r\n                        var formattedDatenew = nextThreeDays.toISOString().split('T')[0].replace(/-/g, '-');\r\n                        newdeliveryarray.push(formattedDatenew)\r\n                      }\r\n\r\n                      if (dfl_delivery_dateweek_day == 2) {\r\n                        var xpro = new Date(ex_payment_date);\r\n                        var nextThreeDays = new Date(xpro.setDate(xpro.getDate() + 2));\r\n                        var formattedDatenew = nextThreeDays.toISOString().split('T')[0].replace(/-/g, '-');\r\n                        newdeliveryarray.push(formattedDatenew)\r\n                      }\r\n\r\n                      if (dfl_delivery_dateweek_day == 3) {\r\n                        var xpro = new Date(ex_payment_date);\r\n                        var nextThreeDays = new Date(xpro.setDate(xpro.getDate() + 3));\r\n                        var formattedDatenew = nextThreeDays.toISOString().split('T')[0].replace(/-/g, '-');\r\n                        newdeliveryarray.push(formattedDatenew)\r\n                      }\r\n                      if (dfl_delivery_dateweek_day == 4) {\r\n                        var xpro = new Date(ex_payment_date);\r\n                        var nextThreeDays = new Date(xpro.setDate(xpro.getDate() + 4));\r\n                        var formattedDatenew = nextThreeDays.toISOString().split('T')[0].replace(/-/g, '-');\r\n                        newdeliveryarray.push(formattedDatenew)\r\n                      }\r\n                      if (dfl_delivery_dateweek_day == 5) {\r\n                        var xpro = new Date(ex_payment_date);\r\n                        var nextThreeDays = new Date(xpro.setDate(xpro.getDate() + 5));\r\n                        var formattedDatenew = nextThreeDays.toISOString().split('T')[0].replace(/-/g, '-');\r\n                        newdeliveryarray.push(formattedDatenew)\r\n                      }\r\n                    }\r\n                  }\r\n                }\r\n              });\r\n\r\n              total_future_delivery = result.customerDeliveriesData.deliveries.length;\r\n              var demonew = $(location).attr('href');\r\n              if (demonew.indexOf(\"/subscriptions/\") !== -1) {\r\n                active_sub_id = demonew.split('subscriptions/').pop().split('?')[0];\r\n              } else {\r\n                active_sub_id = result.customerDeliveriesData.deliveries[0].orders[0].line_items[0].subscription_id;\r\n              }\r\n              $.ajax({\r\n                url: \"https://stockedfood.eqserver.net/getSubscription/\" + active_sub_id,\r\n                method: \"GET\",\r\n                dataType: \"JSON\",\r\n                headers: {\r\n                  \"Content-type\": \"application/json\"\r\n                },\r\n                success: function (subdatails) {\r\n                  let orderintervalunit = subdatails.data.subscription.order_interval_unit;\r\n                  let orderintervalfrequiency = subdatails.data.subscription.order_interval_frequency;\r\n                  let from_date = \"\"\r\n                  let show_latest_del_date = \"\"\r\n                  calculation_active_sub_next_charge_date = subdatails.data.subscription.next_charge_scheduled_at;\r\n                  provided_properties_array = subdatails.data.subscription.properties;\r\n                  \r\n                  let take_payment_formattedDate = getNextWednesday();\r\n                  let getOrderIntervalFrequency = subdatails.data.subscription.charge_interval_frequency;\r\n                  let getOrderIntervalUnit = subdatails.data.subscription.order_interval_unit;\r\n                  let daysToSkip = 0;\r\n                  if (getOrderIntervalUnit == \"day\") \r\n                  {\r\n                    daysToSkip = getOrderIntervalFrequency * 1;\r\n                  } \r\n                  else if (getOrderIntervalUnit == \"month\") \r\n                  {\r\n                    daysToSkip = getOrderIntervalFrequency * 30;\r\n                  } \r\n                  else \r\n                  {\r\n                    daysToSkip = getOrderIntervalFrequency * 7;\r\n                  }\r\n                  var getFormattedDate = new Date(take_payment_formattedDate); \r\n                  var options = { weekday: 'short', month: 'short', day: 'numeric', year: 'numeric' };\r\n                  var nextDeliveryFormatedDate = getFormattedDate.toLocaleDateString('en-US', options);\r\n                  var getFormattedDateYear = getFormattedDate.getFullYear();\r\n                  var getFormattedDateMonth = ('0' + (getFormattedDate.getMonth() + 1)).slice(-2);\r\n                  var getFormattedDateDay = ('0' + getFormattedDate.getDate()).slice(-2);\r\n                  var nextPaymentDate = getFormattedDateYear + '-' + getFormattedDateMonth + '-' + getFormattedDateDay;\r\n                  var nextPaymentDateToCheck = getFormattedDateDay + '.' + getFormattedDateMonth + '.' + getFormattedDateYear;\r\n                  var getNextPaymentDate = countNextDate(nextPaymentDate, daysToSkip);\r\n                  var getNewNextPaymentDateParts = getNextPaymentDate.split('.');\r\n                  var getNewNextFormatedPaymentDate = new Date(getNewNextPaymentDateParts[2], getNewNextPaymentDateParts[1] - 1, getNewNextPaymentDateParts[0]);\r\n                  nextPaymentFormatedDate = getNewNextFormatedPaymentDate.toLocaleDateString('en-US', options);\r\n\r\n                  if (provided_properties_array.length > 0) {\r\n                    for (var x in provided_properties_array) {\r\n                      if (provided_properties_array[x]['name'] == \"_Delivery Date Preference\") {\r\n                        var ppdate = provided_properties_array[x]['name'];\r\n                        var ppdate_value = provided_properties_array[x]['value']\r\n                        if (typeof ppdate != \"undefined\" && ppdate != null && ppdate != \"\" && typeof ppdate_value != \"undefined\" && ppdate_value != null && ppdate_value != \"\") {\r\n                          hasdeliverypropertiesdateadded = true;\r\n                          pass_del_date = provided_properties_array[x]['value'];\r\n                          from_date = provided_properties_array[x]['value'];\r\n                          show_latest_del_date = provided_properties_array[x]['value'];\r\n                        } else {\r\n                          var makeitDate_01 = new Date(calculation_active_sub_next_charge_date);\r\n                          var new_dayOfWeek_01 = makeitDate_01.getDay();\r\n                          var daysToNextThursday_01 = (4 - new_dayOfWeek_01 + 7) % 7;\r\n                          makeitDate_01.setDate(makeitDate_01.getDate() + daysToNextThursday_01);\r\n                          var pickernewdate_01 = new Date(makeitDate_01);\r\n                          pickernewdate_01 = pickernewdate_01.toISOString().slice(0, 10);\r\n                          var datepartsupdated_01 = pickernewdate_01.split('-');\r\n                          from_date = datepartsupdated_01[2] + '.' + datepartsupdated_01[1] + '.' + datepartsupdated_01[0];\r\n                          show_latest_del_date = datepartsupdated_01[2] + '.' + datepartsupdated_01[1] + '.' + datepartsupdated_01[0];\r\n                        }\r\n                      } else {\r\n                        var makeitDate_01 = new Date(calculation_active_sub_next_charge_date);\r\n                        var new_dayOfWeek_01 = makeitDate_01.getDay();\r\n                        var daysToNextThursday_01 = (4 - new_dayOfWeek_01 + 7) % 7;\r\n                        makeitDate_01.setDate(makeitDate_01.getDate() + daysToNextThursday_01);\r\n                        var pickernewdate_01 = new Date(makeitDate_01);\r\n                        pickernewdate_01 = pickernewdate_01.toISOString().slice(0, 10);\r\n                        var datepartsupdated_01 = pickernewdate_01.split('-');\r\n                        from_date = datepartsupdated_01[2] + '.' + datepartsupdated_01[1] + '.' + datepartsupdated_01[0];\r\n                        show_latest_del_date = datepartsupdated_01[2] + '.' + datepartsupdated_01[1] + '.' + datepartsupdated_01[0];\r\n                      }\r\n                    }\r\n                  } else {\r\n                    var makeitDate_01 = new Date(calculation_active_sub_next_charge_date);\r\n                    var new_dayOfWeek_01 = makeitDate_01.getDay();\r\n                    var daysToNextThursday_01 = (4 - new_dayOfWeek_01 + 7) % 7;\r\n                    makeitDate_01.setDate(makeitDate_01.getDate() + daysToNextThursday_01);\r\n                    var pickernewdate_01 = new Date(makeitDate_01);\r\n                    pickernewdate_01 = pickernewdate_01.toISOString().slice(0, 10);\r\n                    var datepartsupdated_01 = pickernewdate_01.split('-');\r\n                    from_date = datepartsupdated_01[2] + '.' + datepartsupdated_01[1] + '.' + datepartsupdated_01[0];\r\n                    show_latest_del_date = datepartsupdated_01[2] + '.' + datepartsupdated_01[1] + '.' + datepartsupdated_01[0];\r\n                  }\r\n\r\n                  $('.recharge-section-recent-order').hide();\r\n                  $('.custom-header-slot-loader').show();\r\n\r\n                  // code for get order fullfilment status code start here\r\n                  $.ajax({\r\n                    url: \"https://stockedfood.eqserver.net/rechargeCustomerOrder/\" + customer_recharge_id,\r\n                    method: \"GET\",\r\n                    dataType: \"JSON\",\r\n                    headers: {\r\n                      \"Content-type\": \"application/json\"\r\n                    },\r\n                    success: function (newresult) {\r\n                      customer_shopify_order_id = newresult.data.orders[0].external_order_id.ecommerce;\r\n                      $.ajax({\r\n                        url: \"https://stockedfood.eqserver.net/order/getCustomerOrder/\" + customer_shopify_order_id,\r\n                        method: \"GET\",\r\n                        dataType: \"JSON\",\r\n                        headers: {\r\n                          \"Content-type\": \"application/json\"\r\n                        },\r\n                        success: function (orderdetails) {\r\n                          orderfulfillment_status = orderdetails.orders.order.fulfillment_status;\r\n                          ordercancellationstatus = orderdetails.orders.order.cancelled_at;\r\n                          ordertag = orderdetails.orders.order.tags;\r\n\r\n                          function show_recharge_properties_delivery_date(new_from_date) {\r\n                            var passing_del_date = new_from_date;\r\n                            var newdate = passing_del_date.split(\".\").reverse().join(\"-\");\r\n                            var delivery_metafield_date = newdate;\r\n                            var del_date = new Date(delivery_metafield_date);\r\n                            var payment_formated = new Date(calculation_active_sub_next_charge_date);\r\n                            var makeitDate_01 = del_date;\r\n                            var new_dayOfWeek_01 = makeitDate_01.getDay();\r\n                            if (new_dayOfWeek_01 === 3 || new_dayOfWeek_01 === 4 || new_dayOfWeek_01 === 5) {\r\n                              // Move to the beginning of the week of the payment_formated date (Sunday)\r\n                              var startOfPaymentWeek = new Date(payment_formated);\r\n                              startOfPaymentWeek.setDate(startOfPaymentWeek.getDate() - startOfPaymentWeek.getDay());\r\n                              // Calculate the target day in the payment_formated week\r\n                              var targetDateInPaymentWeek = new Date(startOfPaymentWeek);\r\n                              targetDateInPaymentWeek.setDate(startOfPaymentWeek.getDate() + new_dayOfWeek_01);\r\n                              del_date = new Date(targetDateInPaymentWeek);\r\n                            } else if (new_dayOfWeek_01 === 1 || new_dayOfWeek_01 === 6 || new_dayOfWeek_01 === 0) {\r\n                              // Move to the next week after the payment_formated date\r\n                              var startOfNextPaymentWeek = new Date(payment_formated);\r\n                              startOfNextPaymentWeek.setDate(startOfNextPaymentWeek.getDate() + 3); // Wednesday (Day 3)\r\n                              del_date = new Date(startOfNextPaymentWeek);\r\n                            }\r\n\r\n                            var order_weekday = del_date.toLocaleString(\"default\", { weekday: \"short\" })\r\n                            var order_month = del_date.toLocaleString('default', { month: 'long' });\r\n                            var order_day = del_date.getDate();\r\n                            var order_year = del_date.getFullYear();\r\n                            var fulldeliverydate = order_weekday + ',' + ' ' + order_month + ' ' + order_day + ',' + ' ' + order_year;\r\n\r\n                            var optionsToAttribute = { weekday: 'short', month: 'short', day: 'numeric', year: 'numeric' };\r\n                            var nextDeliveryFormatedDateToAttribute = del_date.toLocaleDateString('en-US', optionsToAttribute);\r\n                            var getFormattedDateYearToAttribute = del_date.getFullYear();\r\n                            var getFormattedDateMonthToAttribute = ('0' + (del_date.getMonth() + 1)).slice(-2);\r\n                            var getFormattedDateDayToAttribute = ('0' + del_date.getDate()).slice(-2);\r\n                            var nextPaymentDateToAttribute = getFormattedDateDayToAttribute + '.' + getFormattedDateMonthToAttribute + '.' + getFormattedDateYearToAttribute;\r\n\r\n                            $('.custom-header-slot h1').text(fulldeliverydate);\r\n                            $('.custom-header-slot h1').attr(\"next-date\", nextPaymentDateToAttribute);\r\n                            $('.custom-header-slot').show();\r\n                            updateTemporaryDeliveryData(true, nextDeliveryFormatedDate, nextPaymentFormatedDate);\r\n                            $('.custom-header-slot-loader').hide();\r\n                          }\r\n\r\n                          if (orderfulfillment_status != \"fulfilled\") {\r\n                            if (ordercancellationstatus == null) {\r\n                              const tagarray1 = ordertag.split(',');\r\n                              let deliveryoderdate = \"\";\r\n                              let hasdelivertdatetag = false;\r\n                              if (ordertag.length) {\r\n                                for (var i = 0; i < tagarray1.length; i++) {\r\n                                  if (tagarray1[i].indexOf(\"2024\") !== -1 || tagarray1[i].indexOf(\"2025\") !== -1 || tagarray1[i].indexOf(\"2026\") !== -1 || tagarray1[i].indexOf(\"2027\") !== -1 || tagarray1[i].indexOf(\"2028\") !== -1 || tagarray1[i].indexOf(\"2029\") !== -1 || tagarray1[i].indexOf(\"2030\") !== -1) {\r\n                                    deliveryoderdate = tagarray1[i];\r\n                                    from_date = deliveryoderdate.split(\".\").reverse().join(\"-\");\r\n                                    hasdelivertdatetag = true;\r\n                                    break;\r\n                                  }\r\n                                }\r\n                              }\r\n\r\n                              if (hasdelivertdatetag) {\r\n                                function add_weeks(dt, n) {\r\n                                  if (orderintervalunit == \"day\") {\r\n                                    return new Date(dt.setDate(dt.getDate() + (n * (orderintervalfrequiency * 1))));\r\n                                  } else if (orderintervalunit == \"month\") {\r\n                                    return new Date(dt.setMonth(dt.getMonth() + (n * orderintervalfrequiency)));\r\n                                  }\r\n                                  else {\r\n                                    return new Date(dt.setDate(dt.getDate() + (n * (orderintervalfrequiency * 7))));\r\n                                  }\r\n                                }\r\n\r\n                                dt = new Date(from_date);\r\n                                from_date = add_weeks(dt, counter).toString()\r\n                                var newdate = from_date.split(\".\").reverse().join(\"-\");\r\n                                var delivery_metafield_date = newdate;\r\n                                var del_date = new Date(delivery_metafield_date);\r\n                                var order_weekday = del_date.toLocaleString(\"default\", { weekday: \"short\" })\r\n                                var order_month = del_date.toLocaleString('default', { month: 'long' });\r\n                                var order_day = del_date.getDate();\r\n                                var order_year = del_date.getFullYear();\r\n                                var fulldeliverydate = order_weekday + ',' + ' ' + order_month + ' ' + order_day + ',' + ' ' + order_year;\r\n\r\n                                var recent_delivery_text = 'Your next delivery:<h1>' + fulldeliverydate + '</h1>' + recharge_live_order_text_data.replace('{date}', fulldeliverydate);\r\n                                $('.custom-recent-order-slot span').html(recent_delivery_text);\r\n                                updateTemporaryDeliveryData(true, nextDeliveryFormatedDate, nextPaymentFormatedDate);\r\n                                $('.custom-recent-order-slot').show();\r\n                                $('.custom-header-slot-loader').hide();\r\n                                $('.loading-custom-recharge-content').remove();\r\n                              } else {\r\n                                var recent_delivery_text = recharge_date_not_found_error_text_data;\r\n                                $('.custom-recent-order-slot span').html(recent_delivery_text);\r\n                                updateTemporaryDeliveryData(true, nextDeliveryFormatedDate, nextPaymentFormatedDate);\r\n                                $('.custom-recent-order-slot').show();\r\n                                $('.custom-header-slot-loader').hide();\r\n                                $('.loading-custom-recharge-content').remove();\r\n                              }\r\n                            } else {\r\n                              show_recharge_properties_delivery_date(from_date)\r\n                            }\r\n                          } else {\r\n                            if (ordercancellationstatus == null) {\r\n                              const tagarray1 = ordertag.split(',');\r\n                              let deliveryoderdate = \"\";\r\n                              let hasdelivertdatetag = false;\r\n                              let btcdate = \"\";\r\n                              if (ordertag.length) {\r\n                                for (var i = 0; i < tagarray1.length; i++) {\r\n                                  if (tagarray1[i].indexOf(\"2024\") !== -1 || tagarray1[i].indexOf(\"2025\") !== -1 || tagarray1[i].indexOf(\"2026\") !== -1 || tagarray1[i].indexOf(\"2027\") !== -1 || tagarray1[i].indexOf(\"2028\") !== -1 || tagarray1[i].indexOf(\"2029\") !== -1 || tagarray1[i].indexOf(\"2030\") !== -1) {\r\n                                    deliveryoderdate = tagarray1[i];\r\n                                    from_date = deliveryoderdate.split(\".\").reverse().join(\"-\");\r\n                                    btcdate = deliveryoderdate.split(\".\").reverse().join(\"-\");\r\n                                    hasdelivertdatetag = true\r\n                                    break;\r\n                                  }\r\n                                }\r\n                              }\r\n\r\n                              if (hasdelivertdatetag) {\r\n                                function add_weeks(dt, n) {\r\n                                  if (orderintervalunit == \"day\") {\r\n                                    return new Date(dt.setDate(dt.getDate() + (n * (orderintervalfrequiency * 1))));\r\n                                  } else if (orderintervalunit == \"month\") {\r\n                                    return new Date(dt.setMonth(dt.getMonth() + (n * orderintervalfrequiency)));\r\n                                  } else {\r\n                                    return new Date(dt.setDate(dt.getDate() + (n * (orderintervalfrequiency * 7))));\r\n                                  }\r\n                                }\r\n\r\n                                dt = new Date(from_date);\r\n                                from_date = add_weeks(dt, counter).toString()\r\n                                var newdate = from_date.split(\".\").reverse().join(\"-\");\r\n                                var delivery_metafield_date = newdate;\r\n                                var del_date = new Date(delivery_metafield_date);\r\n                                var order_weekday = del_date.toLocaleString(\"default\", { weekday: \"short\" })\r\n                                var order_month = del_date.toLocaleString('default', { month: 'long' });\r\n                                var order_day = del_date.getDate();\r\n                                var order_year = del_date.getFullYear();\r\n                                var fulldeliverydate = order_weekday + ',' + ' ' + order_month + ' ' + order_day + ',' + ' ' + order_year;\r\n                                var GivenDate = btcdate + \" 23:59\";\r\n                                var CurrentDate = new Date();\r\n                                GivenDate = new Date(GivenDate);\r\n                                if (GivenDate.getTime() > CurrentDate.getTime()) {\r\n                                  var recent_delivery_text = 'Your next delivery:<h1>' + fulldeliverydate + '</h1>' + recharge_out_of__delivery_text_data.replace('{date}', fulldeliverydate);\r\n                                  $('.custom-recent-order-slot span').html(recent_delivery_text);\r\n                                  updateTemporaryDeliveryData(true, nextDeliveryFormatedDate, nextPaymentFormatedDate);\r\n                                  $('.custom-recent-order-slot').show();\r\n                                  $('.custom-header-slot-loader').hide();\r\n                                  $('.loading-custom-recharge-content').remove();\r\n                                } else {\r\n                                  show_recharge_properties_delivery_date(show_latest_del_date);\r\n                                }\r\n                              } else {\r\n                                show_recharge_properties_delivery_date(from_date);\r\n                              }\r\n                            } else {\r\n                              show_recharge_properties_delivery_date(from_date);\r\n                            }\r\n                          }\r\n                          $('.loading-custom-recharge-content').remove();\r\n                        }\r\n                      });\r\n                    }\r\n                  });\r\n                  var deliveryPreferenceHtml = `<div class=\"recharge-reschedule-delivery-summary__date\"><div class=\"wrapper delivery-date-picker delivery-summary__date-picker\"><svg viewBox=\"0 0 17 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" width=\"17\" height=\"16\"><g stroke=\"currentColor\" stroke-width=\"1.2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M4.5 8a.5.5 0 1 0 0-1 .5.5 0 0 0 0 1ZM8.5 8a.5.5 0 1 0 0-1 .5.5 0 0 0 0 1ZM4.5 12a.5.5 0 1 0 0-1 .5.5 0 0 0 0 1ZM8.5 12a.5.5 0 1 0 0-1 .5.5 0 0 0 0 1ZM12.5 8a.5.5 0 1 0 0-1 .5.5 0 0 0 0 1ZM1.071 4H15.93\"></path><path d=\"M14.786.571H2.214c-.63 0-1.143.512-1.143 1.143v12.572c0 .63.512 1.142 1.143 1.142h12.572c.63 0 1.143-.511 1.143-1.142V1.714c0-.631-.512-1.143-1.143-1.143Z\"></path></g></svg><span class=\"\">Reschedule this delivery</span></div><div class=\"open-popup-overlay\"></div><div class=\"recharge-custom-wrapper\" style=\"display:none\"></div></div>`;\r\n                  var reschedulerwrapper = `<div class=\"open-rescheduler-wrapper\"><svg aria-hidden=\"true\" focusable=\"false\" role=\"presentation\" class=\"close-reschedel-opener\" viewBox=\"0 0 16.8 16.8\" style=\"\"><path fill=\"#444\" d=\"M16.8 1.5L15.4.1 8.4 7l-7-7L0 1.4l7 7-7 7 1.4 1.4 7-7 7 7 1.4-1.4-7-7z\" style=\"fill: #000;\"></path></svg><h2 class=\"text-heading\">${recharge_reschedule_popup_text_data}</h2><div class=\"caution-info\"><svg viewBox=\"0 0 18 18\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" width=\"18\" height=\"18\"><circle cx=\"9\" cy=\"9\" r=\"8\" stroke=\"currentColor\" stroke-width=\"1.2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"></circle><circle cx=\"9\" cy=\"5.5\" fill=\"currentColor\" r=\"1\"></circle><path d=\"M9 8.5v4\" stroke=\"currentColor\" stroke-width=\"1.2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"></path></svg><span>${recharge_schedule_changes_text_data}</span></div><div class=\"inner-wrapper-datepicker\"><div class=\"delay-selector\"><label for=\"1week\" class=\"radio-button-container\">Delay for 1 week<input type=\"radio\" id=\"1week\" name=\"fav_language\" value=\"1week\"><span class=\"checkmark\"></span></label></div><div class=\"delay-selector\"><label for=\"2week\" class=\"radio-button-container\">Delay for 2 week<input type=\"radio\" id=\"2week\" name=\"fav_language\" value=\"2week\"><span class=\"checkmark\"></span></label></div><div class=\"delay-selector prefer-select-date\"><label for=\"date\" class=\"radio-button-container\">Choose a specific date<input class=\"form__input delivery-summary__date-input\" type=\"radio\" name=\"fav_language\" id=\"date\" value=\"\" placeholder=\"Select Delivery Date date:\" readonly/><span class=\"checkmark\"></span></label><div id=\"st-datepicker\" style=\"display: none;\"></div><div class=\"itdisplay-total-delivery-date\"></div></div></div><div class=\"date-submit-action\"><button class=\"submit-selected-date disabled\"><span class=\"button-loader\" style=\"display:none\"></span>Save Changes</button><div class=\"close-rescheduler\">Cancel</div></div></div>`;\r\n\r\n                  var demonext = $(location).attr('href');\r\n                  if ($('.recharge-component-subscription-details .recharge-button.recharge-button-secondary').length > 0) {\r\n                    if (document.querySelector('.recharge-component-subscription-details .recharge-button.recharge-button-secondary:first-child').textContent == \"Reschedule\" || document.querySelector('.recharge-component-subscription-details .recharge-button.recharge-button-secondary:first-child').textContent == \"Reschedule delivery\") {\r\n                      document.querySelector('.recharge-component-subscription-details .recharge-button.recharge-button-secondary:first-child').outerHTML = deliveryPreferenceHtml\r\n                    }\r\n                  } else {\r\n                    var waitForElement = function (selector, callback) {\r\n                      if (jQuery(selector).length) {\r\n                        callback();\r\n                      } else {\r\n                        setTimeout(function () {\r\n                          waitForEl(selector, callback);\r\n                        }, 100);\r\n                      }\r\n                    };\r\n                    waitForEl('.recharge-section-next-order-actions [data-testid=\"recharge-internal-reschedule-button\"]', function () {\r\n                      $('.recharge-section-next-order-actions [data-testid=\"recharge-internal-reschedule-button\"]').parent().html(deliveryPreferenceHtml);\r\n                    })\r\n                  }\r\n\r\n                  //if (customer_recharge_id == 178241953 || customer_recharge_id == 136523787) {\r\n                    //console.log('this is a test customer');\r\n\r\n                    let takePaymentHTML = `<div class=\"take-payment-now-button\">Deliver ASAP</div><div class=\"new-open-popup-overlay\"></div><div class=\"recharge-custom-take-payment-wrapper\" style=\"display:none\"></div>`;\r\n\r\n                    if ($('[data-testid=\"recharge-internal-send-now-button\"]').length > 0) {\r\n                      $('[data-testid=\"recharge-internal-send-now-button\"]').replaceWith(takePaymentHTML);\r\n                    } else {\r\n                      var waitForElement = function (selector, callback) {\r\n                        if (jQuery(selector).length) {\r\n                          callback();\r\n                        } else {\r\n                          setTimeout(function () {\r\n                            waitForEl(selector, callback);\r\n                          }, 100);\r\n                        }\r\n                      };\r\n\r\n                      waitForEl('[data-testid=\"recharge-internal-send-now-button\"]', function () {\r\n                        $('[data-testid=\"recharge-internal-send-now-button\"]').replaceWith(takePaymentHTML);\r\n                      })\r\n                    }\r\n                    $(\".take-payment-now-button\").off(\"click\").on(\"click\", function () {\r\n                      var takePaymentInnerWrapper = '';\r\n                      var isDateMatched = false;\r\n                      var getDateFromHtml = $(\".custom-header-slot h1\").attr(\"next-date\");\r\n                      if(typeof getDateFromHtml != \"undefined\" && getDateFromHtml != null && getDateFromHtml != \"\")\r\n                      {\r\n                        if(typeof nextPaymentDateToCheck != \"undefined\" && nextPaymentDateToCheck != null && nextPaymentDateToCheck != \"\")\r\n                        {\r\n                          if(getDateFromHtml == nextPaymentDateToCheck)\r\n                          {\r\n                            isDateMatched = true;\r\n                          }\r\n                        }\r\n                      }\r\n                      if(isDateMatched)\r\n                      {\r\n                        takePaymentInnerWrapper  = `<div class=\"take-payment-now-inner-wrapper\"><svg aria-hidden=\"true\" class=\"close-take-payment-opener\" focusable=\"false\" role=\"presentation\" viewBox=\"0 0 16.8 16.8\"><path d=\"M16.8 1.5L15.4.1 8.4 7l-7-7L0 1.4l7 7-7 7 1.4 1.4 7-7 7 7 1.4-1.4-7-7z\" fill=\"#444\" style=\"fill:#000\"></path></svg><h2 class=\"text-heading\">Delivery ASAP</h2><div class=\"take-payment-now-content\">Your parcel is already down for the next available delivery date. Contact the team at team@stockedfood.com if you'd like it sooner!<p class=\"take-payment-success\" style=\"display:none;margin-top: 15px;text-align: center;font-size: 17px;\">Processing... The details will be updated within 5 minutes!</p></div></div>`;\r\n                      }\r\n                      else\r\n                      {\r\n                        takePaymentInnerWrapper  = `<div class=\"take-payment-now-inner-wrapper\"><svg aria-hidden=\"true\" class=\"close-take-payment-opener\" focusable=\"false\" role=\"presentation\" viewBox=\"0 0 16.8 16.8\"><path d=\"M16.8 1.5L15.4.1 8.4 7l-7-7L0 1.4l7 7-7 7 1.4 1.4 7-7 7 7 1.4-1.4-7-7z\" fill=\"#444\" style=\"fill:#000\"></path></svg><h2 class=\"text-heading\">Delivery ASAP</h2><div class=\"take-payment-now-content\">By clicking the button below your payment for this order will be taken immediately and your delivery will be fast tracked to the next available delivery date, Wednesday ${take_payment_formattedDate}. If you'd prefer another date, click \"Cancel\" below and then \"Reschedule this delivery\".<p class=\"take-payment-success\" style=\"display:none;margin-top: 15px;text-align: center;font-size: 17px;\">Processing... The details will be updated within 5 minutes!</p></div><div class=\"payment-submit-action\"><button class=\"submit-take-payment-date\" data-active-sub-id=\"${active_sub_id}\"\" data-customer-id=\"${customer_recharge_id}\">Deliver ASAP - Wednesday ${take_payment_formattedDate}</button><div class=\"close-take-payment\">Cancel</div></div></div>`;\r\n                      }\r\n                      \r\n                      $('.recharge-custom-take-payment-wrapper').html(takePaymentInnerWrapper);\r\n                      $('.new-open-popup-overlay').show();\r\n                      $('.recharge-custom-take-payment-wrapper').css('display', 'flex');\r\n                      $('body').addClass('open-take-payment-popup');\r\n\r\n                      $(\".close-take-payment,.close-take-payment-opener\").on(\"click\", function (e) {\r\n                        e.preventDefault();\r\n                        $('.recharge-custom-take-payment-wrapper').css('display', 'none');\r\n                        $('body').removeClass('open-take-payment-popup');\r\n                      });\r\n\r\n                      $(\".submit-take-payment-date\").on(\"click\", function (e) {\r\n                        e.preventDefault();\r\n                        let customerId = $(this).data('customer-id');\r\n                        let subscriptionId = $(this).data('active-sub-id');\r\n                        console.log({ customerId, subscriptionId });\r\n                        $.ajax({\r\n                          url: \"https://stockedfood.eqserver.net/webhook/storeRedisDetails/\",\r\n                          method: \"POST\",\r\n                          dataType: \"JSON\",\r\n                          data: JSON.stringify({\r\n                            customerId: customerId,\r\n                            subscriptionId: subscriptionId\r\n                          }), // Ensure JSON format\r\n                          headers: {\r\n                            \"Content-type\": \"application/json\"\r\n                          },\r\n                          success: function (result) {\r\n                            console.log(result);\r\n                            $('.payment-submit-action').hide();\r\n                            $('.take-payment-success').fadeIn();\r\n                            storeDetailWithTimestamp('takePaymentNow', 'Tried doing take payment now.');\r\n                            setTimeout(function(){\r\n                              $('.recharge-custom-take-payment-wrapper').css('display', 'none');\r\n                              $('body').removeClass('open-take-payment-popup');\r\n                              updateTemporaryDeliveryData(false, nextDeliveryFormatedDate, nextPaymentFormatedDate);\r\n                            }, 2000);\r\n                          },\r\n                          error: function (t) {\r\n                            console.log('error' + t);\r\n                          }\r\n                        });\r\n                      });\r\n                    });\r\n                  //}\r\n\r\n                  $(document).off('click').on(\"click\", \".delivery-summary__date-picker\", function () {\r\n                    $(this).parent().find('.recharge-custom-wrapper').html(reschedulerwrapper);\r\n                    $('.recharge-custom-wrapper').css('display', 'flex');\r\n                    $('body').addClass('open-dateselector-popup');\r\n                  })\r\n\r\n                  $(document).mouseup(function (e) {\r\n                    if ($(e.target).closest(\".recharge-custom-wrapper\").length === 0) {\r\n                      $(\".recharge-custom-wrapper\").hide();\r\n                      $('input[name=\"fav_language\"]').prop('checked', false);\r\n                      $('body').removeClass('open-dateselector-popup');\r\n                      $('.submit-selected-date').addClass('disabled');\r\n                      $('#st-datepicker').hide();\r\n                      $(\".open-rescheduler-wrapper\").each(function () {\r\n                        $(this).remove();\r\n                      });\r\n                      $('.total-highlighted-amount').hide();\r\n                    }\r\n                  });\r\n\r\n                  $(document).on(\"click\", \".close-rescheduler\", function () {\r\n                    $('.recharge-custom-wrapper').css('display', 'none');\r\n                    $('body').removeClass('open-dateselector-popup');\r\n                    $('input[name=\"fav_language\"]').prop('checked', false);\r\n                    $('#st-datepicker').hide();\r\n                    $(\".open-rescheduler-wrapper\").each(function () {\r\n                      $(this).remove();\r\n                    });\r\n                    $('.total-highlighted-amount').hide();\r\n                    $('.submit-selected-date').addClass('disabled');\r\n                  })\r\n\r\n                  $(document).on(\"click\", \".close-reschedel-opener\", function () {\r\n                    $('.recharge-custom-wrapper').css('display', 'none');\r\n                    $('body').removeClass('open-dateselector-popup');\r\n                    $('input[name=\"fav_language\"]').prop('checked', false);\r\n                    $('#st-datepicker').hide();\r\n                    $(\".open-rescheduler-wrapper\").each(function () {\r\n                      $(this).remove();\r\n                    });\r\n                    $('.total-highlighted-amount').hide();\r\n                    $('.submit-selected-date').addClass('disabled');\r\n                  })\r\n\r\n                  $(document).on(\"click\", \".inner-wrapper-datepicker .delay-selector input\", function () {\r\n                    if ($('#date').is(':checked')) {\r\n                      var new_date = new Date();\r\n                      let current_dayNo = new_date.getDay();\r\n                      let minDate = \"\"\r\n                      let day1 = \"\"\r\n                      var hour_dd = new_date.getHours();\r\n                      if (current_dayNo == 0) {\r\n                        minDate = 10;\r\n                      }\r\n                      else if (current_dayNo == 1) {\r\n                        minDate = 9;\r\n                      }\r\n                      else if (current_dayNo == 2) {\r\n                        minDate = 8;\r\n                      }\r\n                      else if (current_dayNo == 3) {\r\n                        minDate = 7;\r\n                      }\r\n                      else if (current_dayNo == 4) {\r\n                        minDate = 6;\r\n                      }\r\n                      else if (current_dayNo == 5) {\r\n                        minDate = 5;\r\n                      }\r\n                      else if (current_dayNo == 6) {\r\n                        minDate = 4;\r\n                      }\r\n\r\n                      $(\"#st-datepicker\").datepicker({\r\n                        beforeShowDay: function (date) {\r\n                          var day = date.getDay();\r\n                          var dateFound = newdeliveryarray.find(function (item) {\r\n                            var formattedDate = new Date(item);\r\n                            return date.toLocaleDateString() === formattedDate.toLocaleDateString();\r\n                          })\r\n                          if (dateFound) {\r\n                            var disabledDates = delivery_dates_disabled;\r\n                            var enabledTuesdays = delivery_dates_enabled;\r\n                            // Format the current date as \"MM-DD\"\r\n                            var holiday_currentDate = (\"0\" + (date.getMonth() + 1)).slice(-2) + \"-\" + (\"0\" + date.getDate()).slice(-2);\r\n\r\n                            if (disabledDates.includes(holiday_currentDate)) {\r\n                              return [false, '', 'Date is disabled'];\r\n                            }\r\n                            if (enabledTuesdays.includes(holiday_currentDate)) {\r\n                              return [true, '', 'Special date enabled'];\r\n                            }\r\n\r\n                            if (day != 0 && day != 1 && day != 2 && day != 6) {\r\n                              return [true, 'css-class-to-highlight', 'tooltip text'];\r\n                            } else {\r\n                              return [false, 'css-class-to-highlight', 'tooltip text'];\r\n                            }\r\n                          } else {\r\n                            var disabledDates = delivery_dates_disabled;\r\n                            var enabledTuesdays = delivery_dates_enabled;\r\n                            // Format the current date as \"MM-DD\"\r\n                            var holiday_currentDate = (\"0\" + (date.getMonth() + 1)).slice(-2) + \"-\" + (\"0\" + date.getDate()).slice(-2);\r\n\r\n                            if (disabledDates.includes(holiday_currentDate)) {\r\n                              return [false, '', 'Date is disabled'];\r\n                            }\r\n                            if (enabledTuesdays.includes(holiday_currentDate)) {\r\n                              return [true, '', 'Special date enabled'];\r\n                            }\r\n                            return [(day != 0 && day != 1 && day != 2 && day != 6), '', ''];\r\n                          }\r\n                        },\r\n                        dateFormat: 'yy-mm-dd',\r\n                        firstDay: 0,\r\n                        minDate: minDate,\r\n                        dayNamesMin: [\"S\", \"M\", \"T\", \"W\", \"T\", \"F\", \"S\"]\r\n                      });\r\n\r\n                      if (hasdeliverypropertiesdateadded) {\r\n                        if (typeof total_future_delivery !== 'undefined') {\r\n                          var recharge_total_fd = '<div class=\"total-highlighted-amount\"><span>' + total_future_delivery + '</span> ' + recharge_schedule_order_count_text_data + ' ';\r\n                          $('.itdisplay-total-delivery-date').html(recharge_total_fd);\r\n                        }\r\n                      }\r\n                      $('#st-datepicker').show();\r\n\r\n                      // new code for datepicker date change while system has past date code start here\r\n                      var deliverydateInput = $(\"#st-datepicker\");\r\n                      deliverydateInput.on(\"change\", function () {\r\n                        console.log($('#st-datepicker').val())\r\n                        var shopifyDate = window.shopify_store_time;\r\n                        var shopifyDateObj = new Date(shopifyDate);\r\n                        var currentDate = new Date();\r\n                        var currentDateString = currentDate.toISOString().split('T')[0];\r\n                        var currentDateObj = new Date(currentDateString);\r\n                        if (currentDateObj.getTime() < shopifyDateObj.getTime()) {\r\n                          var getdatecalue = $('#st-datepicker').val();\r\n                          var dfl_delivery_date_01 = new Date(getdatecalue);\r\n                          var shopifyDay = shopifyDateObj.getDay();\r\n                          if (dfl_delivery_date_01.getDay() == 5) {\r\n                            if (shopifyDay == 0) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 5));\r\n                            } else if (shopifyDay == 1) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 11));\r\n                            } else if (shopifyDay == 2) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 10));\r\n                            } else if (shopifyDay == 3) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 9));\r\n                            } else if (shopifyDay == 4) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 8));\r\n                            } else if (shopifyDay == 5) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 7));\r\n                            } else if (shopifyDay == 6) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 6));\r\n                            }\r\n                          } else if (dfl_delivery_date_01.getDay() == 4) {\r\n                            if (shopifyDay == 0) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 4));\r\n                            } else if (shopifyDay == 1) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 10));\r\n                            } else if (shopifyDay == 2) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 9));\r\n                            } else if (shopifyDay == 3) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 8));\r\n                            } else if (shopifyDay == 4) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 7));\r\n                            } else if (shopifyDay == 5) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 6));\r\n                            } else if (shopifyDay == 6) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 5));\r\n                            }\r\n                          } else if (dfl_delivery_date_01.getDay() == 3) {\r\n                            if (shopifyDay == 0) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 3));\r\n                            } else if (shopifyDay == 1) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 9));\r\n                            } else if (shopifyDay == 2) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 8));\r\n                            } else if (shopifyDay == 3) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 7));\r\n                            } else if (shopifyDay == 4) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 6));\r\n                            } else if (shopifyDay == 5) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 5));\r\n                            } else if (shopifyDay == 6) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 4));\r\n                            }\r\n                          } else {\r\n                            if (shopifyDay == 0) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 3));\r\n                            } else if (shopifyDay == 1) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 9));\r\n                            } else if (shopifyDay == 2) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 8));\r\n                            } else if (shopifyDay == 3) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 7));\r\n                            } else if (shopifyDay == 4) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 6));\r\n                            } else if (shopifyDay == 5) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 5));\r\n                            } else if (shopifyDay == 6) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 4));\r\n                            }\r\n                          }\r\n                        }\r\n                      });\r\n                      // new code for datepicker date change while system has past date code end here\r\n                    } else {\r\n                      $('#st-datepicker').hide();\r\n                      $('.total-highlighted-amount').hide();\r\n                    }\r\n                    $('.submit-selected-date').removeClass('disabled');\r\n                  });\r\n\r\n                  $(document).on(\"click\", \".submit-selected-date\", function () {\r\n                    $('.button-loader').show();\r\n                    let pickernewdate = \"\";\r\n                    if ($('#1week').is(':checked')) {\r\n                      var delay_1_payment_date = new Date(calculation_active_sub_next_charge_date);\r\n                      var payment_date = new Date(delay_1_payment_date.setDate(delay_1_payment_date.getDate() + 7));\r\n                      if (hasdeliverypropertiesdateadded) {\r\n                        var spr = pass_del_date.split('.');\r\n                        var sprD1 = spr[2] + '-' + spr[1] + '-' + spr[0];\r\n                        var delay_1_pass_del_date = new Date(sprD1);\r\n                        pickernewdate = new Date(delay_1_pass_del_date.setDate(delay_1_pass_del_date.getDate() + 7));\r\n                      } else {\r\n                        var makeitDate = new Date(calculation_active_sub_next_charge_date);\r\n                        makeitDate.setDate(makeitDate.getDate() + 7);\r\n                        var new_dayOfWeek = makeitDate.getDay();\r\n                        var daysToNextThursday = (4 - new_dayOfWeek + 7) % 7;\r\n                        makeitDate.setDate(makeitDate.getDate() + daysToNextThursday);\r\n                        pickernewdate = new Date(makeitDate);\r\n                      }\r\n                      pickernewdate = pickernewdate.toISOString().slice(0, 10);\r\n                    }\r\n                    if ($('#2week').is(':checked')) {\r\n                      var delay_2_payment_date = new Date(calculation_active_sub_next_charge_date);\r\n                      var payment_date = new Date(delay_2_payment_date.setDate(delay_2_payment_date.getDate() + 14));\r\n                      if (hasdeliverypropertiesdateadded) {\r\n                        var spr = pass_del_date.split('.');\r\n                        var sprD1 = spr[2] + '-' + spr[1] + '-' + spr[0];\r\n                        var delay_2_pass_del_date = new Date(sprD1);\r\n                        pickernewdate = new Date(delay_2_pass_del_date.setDate(delay_2_pass_del_date.getDate() + 14));\r\n                      } else {\r\n                        var makeitDate = new Date(calculation_active_sub_next_charge_date);\r\n                        makeitDate.setDate(makeitDate.getDate() + 14); // Change from +7 to +14\r\n                        var new_dayOfWeek = makeitDate.getDay();\r\n                        var daysToNextThursday = (4 - new_dayOfWeek + 7) % 7;\r\n                        makeitDate.setDate(makeitDate.getDate() + daysToNextThursday);\r\n                        pickernewdate = new Date(makeitDate);\r\n                      }\r\n                      pickernewdate = pickernewdate.toISOString().slice(0, 10);\r\n                    }\r\n                    if ($('#date').is(':checked')) {\r\n                      // new code for datepicker date change while system has past date code start here\r\n                      var dp_div = $('#st-datepicker').val()\r\n                      var shopifyDate = window.shopify_store_time;\r\n                      var shopifyDateObj = new Date(shopifyDate);\r\n                      var currentDate = new Date();\r\n                      var currentDateString = currentDate.toISOString().split('T')[0];\r\n                      var currentDateObj = new Date(currentDateString);\r\n                      if (currentDateObj.getTime() < shopifyDateObj.getTime()) {\r\n                        var getdatecalue = $('#st-datepicker').val();\r\n                        var dateparts_01 = getdatecalue.split('-');\r\n                        var convertedDateD1_01 = dateparts_01[2] + '-' + dateparts_01[1] + '-' + dateparts_01[0];\r\n                        const dfl_delivery_date_01 = new Date(getdatecalue);\r\n                        var daysUntilNextMonday = (7 - shopifyDateObj.getDay()) % 7;\r\n                        var startOfNextWeek = new Date(shopifyDateObj);\r\n                        startOfNextWeek.setDate(shopifyDateObj.getDate() + daysUntilNextMonday);\r\n                        if (dfl_delivery_date_01 <= startOfNextWeek) {\r\n                          var shopifyDay = shopifyDateObj.getDay();\r\n                          if (dfl_delivery_date_01.getDay() == 5) {\r\n                            if (shopifyDay == 0) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 5));\r\n                            } else if (shopifyDay == 1) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 11));\r\n                            } else if (shopifyDay == 2) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 10));\r\n                            } else if (shopifyDay == 3) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 9));\r\n                            } else if (shopifyDay == 4) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 8));\r\n                            } else if (shopifyDay == 5) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 7));\r\n                            } else if (shopifyDay == 6) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 6));\r\n                            }\r\n                          } else if (dfl_delivery_date_01.getDay() == 4) {\r\n                            if (shopifyDay == 0) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 4));\r\n                            } else if (shopifyDay == 1) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 10));\r\n                            } else if (shopifyDay == 2) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 9));\r\n                            } else if (shopifyDay == 3) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 8));\r\n                            } else if (shopifyDay == 4) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 7));\r\n                            } else if (shopifyDay == 5) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 6));\r\n                            } else if (shopifyDay == 6) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 5));\r\n                            }\r\n                          } else if (dfl_delivery_date_01.getDay() == 3) {\r\n                            if (shopifyDay == 0) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 3));\r\n                            } else if (shopifyDay == 1) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 9));\r\n                            } else if (shopifyDay == 2) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 8));\r\n                            } else if (shopifyDay == 3) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 7));\r\n                            } else if (shopifyDay == 4) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 6));\r\n                            } else if (shopifyDay == 5) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 5));\r\n                            } else if (shopifyDay == 6) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 4));\r\n                            }\r\n                          } else {\r\n                            if (shopifyDay == 0) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 3));\r\n                            } else if (shopifyDay == 1) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 9));\r\n                            } else if (shopifyDay == 2) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 8));\r\n                            } else if (shopifyDay == 3) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 7));\r\n                            } else if (shopifyDay == 4) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 6));\r\n                            } else if (shopifyDay == 5) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 5));\r\n                            } else if (shopifyDay == 6) {\r\n                              var reupdate_date = new Date(shopifyDateObj.setDate(shopifyDateObj.getDate() + 4));\r\n                            }\r\n                          }\r\n                          var day = String(reupdate_date.getDate()).padStart(2, '0');\r\n                          var month = String(reupdate_date.getMonth() + 1).padStart(2, '0'); // Months are zero-based\r\n                          var year = String(reupdate_date.getFullYear()); // Get last two digits of the year\r\n                          var formattedDate = year + '-' + month + '-' + day;\r\n                          $('#st-datepicker').val(formattedDate)\r\n                          if (!$('.open-date-error-message').length) {\r\n                            $('.recharge-container').after(`<div class=\"open-date-error-message\"><div class=\"error-grid\">Unfortunately we can't deliver on the date you have selected ${getdatecalue} because we're not time travellers. We will change your delivery date to the next available date ${formattedDate}.</div></div><div class=\"close-date-error-message\"></div>`);\r\n                          }\r\n                          isDelaytime = true;\r\n                        } else {\r\n                          var getdatecalue = $('#st-datepicker').val()\r\n                        }\r\n                      } else {\r\n                        var getdatecalue = $('#st-datepicker').val()\r\n                      }\r\n\r\n                      // new code for datepicker date change while system has past date code end here\r\n                      pickernewdate = $('#st-datepicker').val();\r\n                      var payment_date = new Date(pickernewdate);\r\n                    }\r\n                    payment_date.setDate(payment_date.getDate() - payment_date.getDay())\r\n                    var year = payment_date.toLocaleString(\"default\", { year: \"numeric\" });\r\n                    var month = payment_date.toLocaleString(\"default\", { month: \"2-digit\" });\r\n                    var day = payment_date.toLocaleString(\"default\", { day: \"2-digit\" });\r\n                    var next_formattedDate = year + \"-\" + month + \"-\" + day;\r\n                    $.ajax({\r\n                      url: \"https://stockedfood.eqserver.net/updateNextRechargeDate/\" + active_sub_id,\r\n                      method: \"POST\",\r\n                      dataType: \"JSON\",\r\n                      data: JSON.stringify({\r\n                        \"date\": next_formattedDate\r\n                      }),\r\n                      headers: {\r\n                        \"Content-type\": \"application/json\"\r\n                      },\r\n                      success: function (result) {\r\n                        $('.recharge-custom-wrapper').css('display', 'none');\r\n                        $('body').removeClass('open-dateselector-popup');\r\n                        $('input[name=\"fav_language\"]').prop('checked', false);\r\n                        $('#st-datepicker').hide();\r\n                        $(\".open-rescheduler-wrapper\").each(function () {\r\n                          $(this).remove();\r\n                        });\r\n                        $('.total-highlighted-amount').hide();\r\n                        $('.submit-selected-date').addClass('disabled');\r\n                        var datepartsupdated = pickernewdate.split('-');\r\n                        var datepartsupdated = datepartsupdated[2] + '.' + datepartsupdated[1] + '.' + datepartsupdated[0];\r\n                        var DatePropertiesfound = false;\r\n                        if (provided_properties_array.length > 0) {\r\n                          for (var x in provided_properties_array) {\r\n                            if (provided_properties_array[x]['name'] == \"_Delivery Date Preference\") {\r\n                              provided_properties_array[x]['value'] = datepartsupdated;\r\n                              DatePropertiesfound = true;\r\n                              break;\r\n                            }\r\n                          }\r\n                          if (!DatePropertiesfound) {\r\n                            provided_properties_array.push({\r\n                              name: \"_Delivery Date Preference\",\r\n                              value: datepartsupdated\r\n                            });\r\n                          }\r\n                        } else {\r\n                          provided_properties_array = [{\r\n                            \"name\": \"_Delivery Date Preference\",\r\n                            \"value\": datepartsupdated\r\n                          }]\r\n                        }\r\n\r\n                        $.ajax({\r\n                          url: \"https://stockedfood.eqserver.net/subscription/update/\" + active_sub_id,\r\n                          method: \"POST\",\r\n                          dataType: \"JSON\",\r\n                          data: JSON.stringify({\r\n                            \"properties\": provided_properties_array\r\n                          }),\r\n                          headers: {\r\n                            \"Content-type\": \"application/json\"\r\n                          },\r\n                          success: function (data) {\r\n                            setTimeout(function () {\r\n                              window.location.reload();\r\n                            }, 300)\r\n                          },\r\n                          error: function (t) {\r\n                            console.log('error',t);\r\n                          }\r\n                        });\r\n                      },\r\n                      error: function (t) {\r\n                        console.log('error',t);\r\n                      }\r\n                    })\r\n                  })\r\n\r\n\r\n                  $('.loading-custom-recharge-content').remove();\r\n                  (function (open) {\r\n                    XMLHttpRequest.prototype.open = function (method, url, async, user, pass) {\r\n                      this.addEventListener('load', function () {\r\n                        if (url.indexOf(\"/skip?\") !== -1 || url.indexOf(\"/unskip?\") !== -1) {\r\n                          console.log('skip api call');\r\n                          if (this.status === 200) {\r\n                            window.location.reload();\r\n                          }\r\n                        }\r\n                      }, false);\r\n                      open.call(this, method, url, async, user, pass);\r\n                    };\r\n                  })(XMLHttpRequest.prototype.open);\r\n\r\n                  if (hasdeliverypropertiesdateadded) {\r\n                  } else {\r\n                    $('.loading-custom-recharge-content').remove();\r\n                    $('.recharge-section-recent-order').show();\r\n                  }\r\n                },\r\n                error: function (t) {\r\n                  console.log('error',t);\r\n                  $('.loading-custom-recharge-content').remove();\r\n                  $('.recharge-section-recent-order').show();\r\n                }\r\n              })\r\n            },\r\n            error: function (t) {\r\n              console.log('error',t);\r\n              $('.loading-custom-recharge-content').remove();\r\n              $('.recharge-section-recent-order').show();\r\n            }\r\n          })\r\n        },\r\n        error: function (t) {\r\n          console.log('error',t);\r\n          $('.loading-custom-recharge-content').remove();\r\n          $('.recharge-section-recent-order').show();\r\n        }\r\n      });\r\n    }\r\n  }\r\n\r\n  function getParameterValue() {\r\n    var urlSearchParams = window.location.href;\r\n    return urlSearchParams;\r\n  }\r\n  var paramValue = getParameterValue();\r\n\r\n  function monitorParamChanges() {\r\n    main_recharge_working()\r\n    setInterval(function () {\r\n      var newValue = getParameterValue();\r\n      if (newValue !== paramValue) {\r\n        paramValue = newValue;\r\n        let elementFound = true;\r\n        main_recharge_working(elementFound);\r\n      }\r\n    }, 200);\r\n  }\r\n  monitorParamChanges();\r\n\r\n  function getNextWednesday() {\r\n    const today = new Date();\r\n    const day = today.getDay(); // 0 (Sunday) to 6 (Saturday)\r\n\r\n    // Calculate days to add based on today's day\r\n    const daysToAdd = day === 0 ? 3 : (7 - day) + 3;\r\n\r\n    const nextWednesday = new Date(today);\r\n    nextWednesday.setDate(today.getDate() + daysToAdd);\r\n\r\n    // Format the date as \"MMM DD, YYYY\"\r\n    const monthNames = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', \r\n                        'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];\r\n    return `${monthNames[nextWednesday.getMonth()]} ${nextWednesday.getDate()}, ${nextWednesday.getFullYear()}`;\r\n  }\r\n  /*\r\n    currentOrderDate : YYYY-MM-DD Format\r\n    daysToSkip : Number of days to skip\r\n  */\r\n  function countNextDate(currentOrderDate, daysToSkip) {\r\n    const today = new Date();\r\n    /* Because the order is being done today in the WebHook */\r\n    const orderWebHookDate = new Date();\r\n    const orderWebHookDay = orderWebHookDate.getDay();\r\n    let initialDate = new Date(currentOrderDate);\r\n\r\n    let additionalDaysToAdd = 0;\r\n    let earlierSunday = new Date();\r\n    /* If the order is placed on a day which is NOT Sunday */\r\n    // if (orderWebHookDay !== 0) {\r\n    //   /* Because the order is placed NOT on a Sunday */\r\n    //   /* Check if the currentOrderDate (Delivery Date) is NOT part of the same week and is in future. if not add 7 days */\r\n    //   do {\r\n    //     earlierSunday.setDate(earlierSunday.getDate() - 1);\r\n    //   } while (earlierSunday.getDay() !== 0);\r\n    //   if (initialDate.getDate() - earlierSunday.getDate() < 7) {\r\n    //     additionalDaysToAdd = 7;\r\n    //   }\r\n    //   daysToSkip = daysToSkip + additionalDaysToAdd;\r\n    // }\r\n\r\n    let returnDate =\r\n      initialDate <= today ? new Date(today) : new Date(initialDate);\r\n    returnDate.setDate(returnDate.getDate() + daysToSkip);\r\n\r\n    // Target day (4 for Thursday or matching dayOfWeek for Wed, Thu, Fri)\r\n    if (returnDate.getDay() === 0) {\r\n        // If it's Sunday, set it to next Wednesday\r\n        returnDate.setDate(returnDate.getDate() + 3); // Add 3 days to move to Wednesday\r\n    } else {\r\n        // Otherwise, find the previous Sunday\r\n        while (returnDate.getDay() !== 0) { // 0 represents Sunday\r\n            returnDate.setDate(returnDate.getDate() - 1);\r\n        }\r\n    }\r\n\r\n    // Format the date as YYYY-MM-DD\r\n    const updatedYear = returnDate.getFullYear();\r\n    const updatedMonth = String(returnDate.getMonth() + 1).padStart(2, \"0\");\r\n    const updatedDay = String(returnDate.getDate()).padStart(2, \"0\");\r\n    return `${updatedDay}.${updatedMonth}.${updatedYear}`;\r\n  }\r\n  var waitForEl = function (selector, callback) {\r\n    if (jQuery(selector).length) {\r\n      callback();\r\n    } else {\r\n      setTimeout(function () {\r\n        waitForEl(selector, callback);\r\n      }, 200);\r\n    }\r\n  };\r\n  let removeTimer = window.setInterval(function () {\r\n    if (window.location.href.indexOf(\"swapProduct\") != -1) {\r\n      waitForEl(\".recharge-component-product-item\", function () {\r\n        $(\".recharge-card .recharge-heading\").each(function (index) {\r\n          let title = $(this).text();\r\n          if (title == \"Nice Rice - Wholegrain Basmati\" || title == \"Nice Rice - Pure Basmati\") {\r\n            $(this).parents('.recharge-component-product-item').parent().remove();\r\n          }\r\n        });\r\n      })\r\n    }\r\n    waitForEl(\".recharge-component-carousel-item\", function () {\r\n      $(\".recharge-card .recharge-heading\").each(function (index) {\r\n        let title = $(this).text();\r\n        if (title == \"4 Packs Subscription\" || title == \"6 Packs Subscription\" || title == \"8 Packs Subscription\") {\r\n          $(this).parents('.recharge-component-carousel-item').parent().remove();\r\n        }\r\n      });\r\n    })\r\n    clearInterval(removeTimer);\r\n  }, 3000);\r\n\r\n  setInterval(function () {\r\n    if (window.location.href.indexOf(\"swapProduct\") != -1) {\r\n      waitForEl(\".recharge-component-product-item\", function () {\r\n        $(\".recharge-card .recharge-heading\").each(function (index) {\r\n          let title = $(this).text();\r\n          if (title == \"Nice Rice - Wholegrain Basmati\" || title == \"Nice Rice - Pure Basmati\") {\r\n            $(this).parents('.recharge-component-product-item').parent().remove();\r\n          }\r\n        });\r\n      })\r\n    }\r\n    if (window.location.href.indexOf(\"browse=all\") != -1) {\r\n      waitForEl(\".recharge-component-product-item\", function () {\r\n        $(\".recharge-card .recharge-heading\").each(function (index) {\r\n          let title = $(this).text();\r\n          if (title == \"4 Packs Subscription\" || title == \"6 Packs Subscription\" || title == \"8 Packs Subscription\") {\r\n            $(this).parents('.recharge-component-product-item').parent().remove();\r\n          }\r\n        });\r\n      })\r\n    }\r\n    waitForEl(\".recharge-component-carousel-item\", function () {\r\n      $(\".recharge-card .recharge-heading\").each(function (index) {\r\n        let title = $(this).text();\r\n        if (title == \"4 Packs Subscription\" || title == \"6 Packs Subscription\" || title == \"8 Packs Subscription\") {\r\n          $(this).parents('.recharge-component-carousel-item').parent().remove();\r\n        }\r\n      });\r\n    })\r\n  }, 200);"],
  "mappings": "AAAA,EAAE,QAAQ,EAAE,MAAM,UAAW,CACzB,QAAQ,IAAI,yFAAyF,CACzG,CAAC,EAED,MAAM,4BAA8B,EAC5B,oCAAsC,ySAEtC,mCAAqC,kTAE3C,SAAS,4BAA4B,iBAAkB,yBAA2B,GAAIA,yBAA0B,GAAI,CAClH,GAAG,kBACD,GAAI,kBAAkB,iBAAiB,2BAA2B,EAChE,GAAG,OAAO,yBAA4B,KAAe,0BAA4B,MAAQ,0BAA4B,IACpH,OAAOA,yBAA2B,KAAeA,0BAA2B,MAAQA,0BAA2B,GAChH,CACE,IAAI,wCAA0C,sCAAsC,yBAAyB,8QACzG,uCAAyC,qMAAqMA,yBAAwB,mRAC1Q,EAAE,2BAA2B,EAAE,KAAK,uCAAuC,EAC3E,EAAE,qBAAqB,EAAE,KAAK,uCAAuC,EACrE,EAAE,qDAAqD,EAAE,KAAK,sCAAsC,CACtG,MAGE,EAAE,2BAA2B,EAAE,KAAK,mCAAmC,EACvE,EAAE,qBAAqB,EAAE,KAAK,mCAAmC,EACjE,EAAE,qDAAqD,EAAE,KAAK,kCAAkC,UAMjG,OAAO,yBAA4B,KAAe,0BAA4B,MAAQ,0BAA4B,IAClH,OAAOA,yBAA2B,KAAeA,0BAA2B,MAAQA,0BAA2B,GAClH,CACE,IAAI,wCAA0C,sCAAsC,yBAAyB,8QACzG,uCAAyC,qMAAqMA,yBAAwB,mRAC1Q,EAAE,2BAA2B,EAAE,KAAK,uCAAuC,EAC3E,EAAE,qBAAqB,EAAE,KAAK,uCAAuC,EACrE,EAAE,qDAAqD,EAAE,KAAK,sCAAsC,CACtG,MAGE,EAAE,2BAA2B,EAAE,KAAK,mCAAmC,EACvE,EAAE,qB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EAAE,QAAQ,kCAAkC,EAAE,OAAO,EAAE,OAAO,CAExE,CAAC,CACH,CAAC,EAEC,OAAO,SAAS,KAAK,QAAQ,YAAY,GAAK,IAChD,UAAU,mCAAoC,UAAY,CACxD,EAAE,kCAAkC,EAAE,KAAK,SAAU,MAAO,CAC1D,IAAI,MAAQ,EAAE,IAAI,EAAE,KAAK,GACrB,OAAS,wBAA0B,OAAS,wBAA0B,OAAS,yBACjF,EAAE,IAAI,EAAE,QAAQ,kCAAkC,EAAE,OAAO,EAAE,OAAO,CAExE,CAAC,CACH,CAAC,EAEH,UAAU,oCAAqC,UAAY,CACzD,EAAE,kCAAkC,EAAE,KAAK,SAAU,MAAO,CAC1D,IAAI,MAAQ,EAAE,IAAI,EAAE,KAAK,GACrB,OAAS,wBAA0B,OAAS,wBAA0B,OAAS,yBACjF,EAAE,IAAI,EAAE,QAAQ,mCAAmC,EAAE,OAAO,EAAE,OAAO,CAEzE,CAAC,CACH,CAAC,CACH,EAAG,GAAG",
  "names": ["nextPaymentFormatedDate", "newdate", "delivery_metafield_date", "del_date", "makeitDate_01", "new_dayOfWeek_01", "order_weekday", "order_month", "order_day", "order_year", "fulldeliverydate", "add_weeks", "dt", "e", "result", "x"]
}
