Server IP : 192.64.112.168 / Your IP : 3.133.153.224 Web Server : Apache System : Linux nc-ph-2300-85.bluforrest.com 4.18.0-513.9.1.el8_9.x86_64 #1 SMP Sat Dec 2 05:23:44 EST 2023 x86_64 User : expressoneac ( 1128) PHP Version : 8.0.30 Disable Function : exec,passthru,shell_exec,system MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/expressoneac/www/wp-content/themes/woodmart/js/scripts/wc/ |
Upload File : |
!function(w){woodmartThemeModule.wishlistGroup=function(){if(void 0!==woodmart_settings.wishlist_expanded&&"yes"===woodmart_settings.wishlist_expanded){var e=woodmart_settings.wishlist_fragment_name,s="woodmart_wishlist_hash";woodmart_settings.is_multisite&&(s+="_"+woodmart_settings.current_blog_id);try{a()}catch(t){o()}woodmartThemeModule.$body.on("keyup",".wd-wishlist-group-name",function(t){"Enter"===t.key&&w(".btn.wd-wishlist-save-btn").trigger("click")}),woodmartThemeModule.$body.on("keyup",".wd-wishlist-input-rename",function(t){"Enter"===t.key&&w(".btn.wd-wishlist-rename-save").trigger("click")}),woodmartThemeModule.$body.on("click",".wd-wishlist-remove-group",function(t){t.preventDefault();var t=w(this),o=t.parents(".wd-wishlist-group").data("group-id"),e=t.parents(".wd-wishlist-group").find(".wd-loader-overlay");confirm(woodmart_settings.wishlist_remove_notice)&&(e.addClass("wd-loading"),w.ajax({url:woodmart_settings.ajaxurl,data:{action:"woodmart_remove_group_from_wishlist",group_id:o,key:woodmart_settings.wishlist_page_nonce},dataType:"json",method:"GET",success:function(t){t.wishlist_content?woodmartThemeModule.$document.trigger("wdUpdateWishlistContent",t,"something"):console.log("something wrong loading wishlist data ",t),t.fragments&&l(t.fragments,t.hash)},error:function(){console.log("We cant remove from wishlist. Something wrong with AJAX response. Probably some PHP conflict.")},complete:function(){e.removeClass("wd-loading")}}))}),woodmartThemeModule.$body.on("click",".wd-wishlist-edit-title",function(t){t.preventDefault();var t=w(this).parents(".wd-wishlist-group-head").find(".wd-wishlist-group-title"),o=t.find(".wd-wishlist-input-rename"),e=o.val();t.addClass("wd-edit"),o.val("").val(e).trigger("focus"),woodmartThemeModule.$body.on("mouseup",function(t){var o,e=w(this),s=w(".wd-wishlist-group-title.wd-edit");s.length?(o=s.parents(".wd-wishlist-group-head")).is(t.target)||0!==o.has(t.target).length||(s.removeClass("wd-edit"),e.off(t)):e.off(t)})}),woodmartThemeModule.$body.on("click",".wd-wishlist-rename-cancel",function(t){t.preventDefault(),w(this).parents(".wd-wishlist-group-title").removeClass("wd-edit")}),woodmartThemeModule.$body.on("click",".wd-wishlist-rename-save",function(t){t.preventDefault();var o=w(this),e=o.parents(".wd-wishlist-group-title"),t=o.parents(".wd-wishlist-group"),s=o.siblings(".wd-wishlist-input-rename"),i=s.val(),t=t.data("group-id");i?s.data("title")===i?e.removeClass("wd-edit"):(o.addClass("loading"),w.ajax({url:woodmart_settings.ajaxurl,data:{action:"woodmart_rename_wishlist_group",title:i,group_id:t,key:woodmart_settings.wishlist_page_nonce},dataType:"json",method:"GET",success:function(t){t?(e.find(">.title").text(i),s.data("title",i)):console.log("something wrong loading wishlist data ",t),t.fragments&&l(t.fragments,t.hash)},error:function(){console.log("We cant add to wishlist. Something wrong with AJAX response. Probably some PHP conflict.")},complete:function(){e.removeClass("wd-edit"),o.removeClass("loading")}})):alert(woodmart_settings.wishlist_rename_group_notice)}),woodmartThemeModule.$body.on("click",".wd-wishlist-create-group-btn",function(t){t.preventDefault(),n("",""," wd-create-group-on-page")}),woodmartThemeModule.$body.on("click",".wd-wishlist-move-action > a",function(t){t.preventDefault();var t=w(this),o=t.parents(".wd-wishlist-group").find(".product.wd-current-product"),e=[];o.length&&(t.addClass("wd-loading"),o.each(function(){e.push(w(this).data("id"))}),n(e,""," wd-move-action"))}),woodmartThemeModule.$body.on("click",".wd-wishlist-group-list li",function(t){var o=w(this);"add_new"===o.data("group-id")?(t.preventDefault(),(t=o.parents(".wd-popup-wishlist")).addClass("wd-create-group"),t.find(".wd-wishlist-group-name").trigger("focus")):(o.siblings().removeClass("wd-current").find("input").prop("checked",!1),o.addClass("wd-current"),o.find("input").prop("checked",!0))}),woodmartThemeModule.$body.on("click",".wd-wishlist-save-btn",function(t){t.preventDefault();var e,s,o,i=w(this),n=i.parents(".wd-popup-wishlist"),t=i.siblings(".wd-wishlist-group-list"),a=w(".wd-wishlist-move-action > a.wd-loading"),d=t.data("product-id"),r="";if(n.hasClass("wd-create-group"))r=n.find(".wd-wishlist-group-name").val();else{if(n.parents(".wd-create-group-on-page").length)return r=n.find(".wd-wishlist-group-name").val(),[o,e,s=!1]=[r,i,a.length],void(o&&(e.addClass("loading"),w.ajax({url:woodmart_settings.ajaxurl,data:{action:"woodmart_save_wishlist_group",group:o,key:woodmart_settings.wishlist_page_nonce},dataType:"json",method:"GET",success:function(t){var o;t?(t.wishlist_content&&woodmartThemeModule.$document.trigger("wdUpdateWishlistContent",t),t.fragments&&l(t.fragments,t.hash),(s||e.parents(".wd-create-group-on-page").length)&&w.magnificPopup.close(),(o=w(".wd-wishlist-content").find(".wd-wishlist-group")).length&&(o=o.last().offset().top-woodmart_settings.ajax_scroll_offset,w("html, body").stop().animate({scrollTop:o},500))):console.log("something wrong loading wishlist data ",t)},error:function(){console.log("We cant add to wishlist. Something wrong with AJAX response. Probably some PHP conflict.")},complete:function(){e.removeClass("loading"),e.siblings(".wd-wishlist-create-group").find(".wd-wishlist-group-name").val("")}})));r=t.find("li.wd-current").data("group-id")}r&&(i.addClass("loading"),a.length?(o=a.parents(".wd-wishlist-group").data("group-id"),w.ajax({url:woodmart_settings.ajaxurl,data:{action:"woodmart_move_products_from_wishlist",products_id:d,group_id:r,group_id_old:o,key:woodmart_settings.wishlist_page_nonce},dataType:"json",method:"GET",success:function(t){t.wishlist_content?woodmartThemeModule.$document.trigger("wdUpdateWishlistContent",t):console.log("something wrong loading wishlist data ",t),t.fragments&&l(t.fragments,t.hash)},error:function(){console.log("We cant remove from wishlist. Something wrong with AJAX response. Probably some PHP conflict.")},complete:function(){i.removeClass("wd-loading"),w.magnificPopup.close(),a.removeClass("wd-loading")}})):woodmartThemeModule.$document.trigger("wdAddProductToWishlist",[d,r,t.data("nonce"),function(){(n=w(".wd-popup-wishlist")).addClass("wd-added"),n.removeClass("wd-create-group"),i.removeClass("loading")}]))}),woodmartThemeModule.$body.on("click",".wd-wishlist-back-btn",function(t){t.preventDefault(),w(this).parents(".wd-popup-wishlist").removeClass("wd-create-group")}),woodmartThemeModule.$body.on("click",".wd-wishlist-back-to-shop",function(t){t.preventDefault(),void 0!==w.fn.magnificPopup&&w.magnificPopup.close()}),woodmartThemeModule.$document.on("wdShowWishlistGroupPopup",function(t,o,e){n(o,e)}),woodmartThemeModule.$document.on("wdUpdateWishlistFragments",function(t,o,e){l(o,e)}),woodmartThemeModule.$document.on("wdWishlistSaveFragments",function(t,o,e){i(o,e)})}function l(t,o=""){setTimeout(function(){w.each(t,function(o,t){woodmartThemeModule.removeDuplicatedStylesFromHTML(t,function(t){w(o).replaceWith(t)})})},600),i(t,o)}function i(t,o){localStorage.setItem(e,JSON.stringify(t)),sessionStorage.setItem(e,JSON.stringify(t)),localStorage.setItem(woodmart_settings.wishlist_hash_name,o),sessionStorage.setItem(woodmart_settings.wishlist_hash_name,o),Cookies.set(s,o,{expires:7,path:woodmart_settings.cookie_path,secure:woodmart_settings.cookie_secure_param})}function n(e,s,i=""){var t,n;void 0!==w.fn.magnificPopup&&(t=w(".wd-popup-wishlist").find("ul"),n=w(".wd-wishlist-move-action > a.wd-loading"),void 0!==woodmart_settings.wishlist_show_popup&&"more_one"===woodmart_settings.wishlist_show_popup&&t.data("group-count")<2&&!n.length&&!i?woodmartThemeModule.$document.trigger("wdAddProductToWishlist",[e,"",s,""]):w.magnificPopup.open({removalDelay:500,tClose:woodmart_settings.close,tLoading:woodmart_settings.loading,callbacks:{beforeOpen:function(){this.st.mainClass="mfp-move-horizontal"+i},open:function(){var t=w(this.content[0]),o=t.find(".wd-wishlist-save-btn");t.find("ul").attr("data-product-id",e).attr("data-nonce",s),t.find("ul").find("li").first().trigger("click")," wd-create-group-on-page"===i&&(o.html(o.data("create-text")),setTimeout(function(){t.find(".wd-wishlist-group-name").trigger("focus")},500))," wd-move-action"===i&&o.html(o.data("move-text"))},close:function(){s&&w("a[data-product-id="+e+"]").removeClass("loading");var t,o=w(this.content[0]);" wd-create-group-on-page"===i&&o.find(".wd-wishlist-save-btn").hasClass("loading")&&(t=w(".wd-wishlist-content").find(".wd-wishlist-group").last(),setTimeout(function(){w("html, body").animate({scrollTop:t.offset().top-100},500)},50)),o.removeClass("wd-create-group"),o.removeClass("wd-added"),o.find(".wd-wishlist-save-btn").removeClass("loading"),o.find(".wd-wishlist-group-name").val(""),o.find(".wd-wishlist-group-list li.wd-current").removeClass("wd-current").find("input").prop("checked",!1),n.removeClass("loading"),setTimeout(function(){a()},600)}},items:{src:".wd-popup-wishlist"}}))}function a(){var t;woodmartThemeModule.supports_html5_storage&&(t=JSON.parse(sessionStorage.getItem(e)),sessionStorage.getItem(woodmart_settings.wishlist_hash_name)!==Cookies.get(s)&&(t=""),sessionStorage.getItem(e)!==localStorage.getItem(e)&&(t=""),t="undefined"==typeof actions||"1"!==actions.is_lang_switched&&"1"!==actions.force_reset?t:"")?w.each(t,function(o,t){woodmartThemeModule.removeDuplicatedStylesFromHTML(t,function(t){w(o).replaceWith(t)})}):o()}function o(){w.ajax({url:woodmart_settings.ajaxurl,data:{action:"woodmart_get_wishlist_fragments",key:woodmart_settings.wishlist_fragments_nonce},dataType:"json",method:"GET",success:function(t){t.fragments?l(t.fragments,t.hash):console.log("something wrong loading compare data ",t)},error:function(){console.log("We cant remove product compare. Something wrong with AJAX response. Probably some PHP conflict.")}})}},w(document).ready(function(){woodmartThemeModule.wishlistGroup()})}(jQuery);