!function(a){a.fn.PavOffCavasmenu=function(n){a.extend({},{opt1:null,text_warning_select:"Please select One to remove?",text_confirm_remove:"Are you sure to remove footer row?",JSON:null},n);return this.each(function(){var n=a("#mainnav .btn-navbar");a("body").append('<section id="off-canvas-nav"><nav class="pavo-mainnav" ></nav></sections>');var e=a("#off-canvas-nav .pavo-mainnav");e.append('<div id="off-canvas-button"><span class="icon-remove-sign"></span></div>');var t=a(n.data("target")).find(".megamenu").clone();e.append(t),a("html").addClass("off-canvas"),a("#off-canvas-button").click(function(){n.click()}),n.toggle(function(){a("body").addClass("off-canvas-active").removeClass("off-canvas-inactive")},function(){a("body").removeClass("off-canvas-active").addClass("off-canvas-inactive")})}),this}}(jQuery),$(window).ready(function(){$("#search_mobile .button-search").bind("click",function(){url=$("base").attr("href")+"index.php?route=product/search";var a=$("#search_mobile input[name='search1']").attr("value");a&&(url+="&search="+encodeURIComponent(a)),location=url}),$("#search_mobile input[name='search1']").bind("keydown",function(a){if(13==a.keyCode){url=$("base").attr("href")+"index.php?route=product/search";var n=$("#search_mobile input[name='search1']").attr("value");n&&(url+="&search="+encodeURIComponent(n)),location=url}}),$("#box-pesquisar .button-searchmenu").bind("click",function(){url=$("base").attr("href")+"index.php?route=product/search";var a=$("#box-pesquisar input[name='searchmenu']").attr("value");a&&(url+="&search="+encodeURIComponent(a)),location=url}),$("#box-pesquisar input[name='searchmenu']").bind("keydown",function(a){if(13==a.keyCode){url=$("base").attr("href")+"index.php?route=product/search";var n=$("#box-pesquisar input[name='searchmenu']").attr("value");n&&(url+="&search="+encodeURIComponent(n)),location=url}}),$(document.body).on("click",'#mainnav [data-toggle="dropdown"], #off-canvas-nav [data-toggle="dropdown"]',function(){!$(this).parent().hasClass("open")&&this.href&&"#"!=this.href&&(window.location.href=this.href)}),$("#mainnav").PavOffCavasmenu(),$(".quantity-adder .add-action").click(function(){$(this).hasClass("add-up")?$("[name=quantity]",".quantity-adder").val(parseInt($("[name=quantity]",".quantity-adder").val())+1):parseInt($("[name=quantity]",".quantity-adder").val())>1&&$("input",".quantity-adder").val(parseInt($("[name=quantity]",".quantity-adder").val())-1)})});