This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {% if order.email != "EMAIL" %} | |
| /// Content of the page. | |
| {% endif %} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {% if customer %} | |
| Código que quieres mostrar a tus clientes logeados. | |
| {% endif %} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {% if customer %} | |
| Precio: {{product.price | price}} | |
| {% else %} | |
| <a href="/customer/login">Regístrate para poder comprar</a> | |
| {% endif %} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function hideShow(){ | |
| if($("#order_shipping_address_region").val() == "12"){ | |
| $("#shipping_options input[value='143029']").parent().siblings().hide(); | |
| $("#shipping_options input[value='143029']").parent().show(); | |
| $("#shipping_options input[value='143029']").click(); | |
| }else{ | |
| $("#shipping_options input[value='143029']").parent().siblings().show(); | |
| $("#shipping_options input[value='143029']").parent().hide(); | |
| $("#shipping_options input[value='144303']").click(); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var remove_payment = function(data) { | |
| var order_product_id = payment_cost_order_product_id(data); | |
| Jumpseller.updateCart(order_product_id, 0); // no payment cost on the order. | |
| } | |
| function payment_cost_order_product_id(cart_json) { | |
| var id = null; | |
| $.each(cart_json.products, function(i, order_product) { | |
| if (order_product.product_id == productId) { // product for adding payment cost. You need to create a virtual product with the additional price. The ID is the number in the URL of the product in the admin panel. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function autocomplete(value,input){ | |
| var interval = setInterval(function(){ | |
| console.log("#"+input) | |
| if($("#"+input).text()){ | |
| $("#"+input).val(value); | |
| clearInterval(interval); | |
| } | |
| }, 500) | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script type="application/ld+json"> | |
| { | |
| "@context": "http://schema.org/" | |
| {% case template %} | |
| {% when 'product' %}, | |
| "@type": "Product", | |
| "name": "{{product.name | escape}}", | |
| "url": "{{store.url}}{{product.url}}", | |
| "itemCondition": "http://schema.org/NewCondition", | |
| {% if product.sku != blank %}"sku": "{{product.sku}}",{% endif %} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script> | |
| // Define the shipping method for the local region (metropolitana) and for all others. | |
| let metropolitana = 267131 | |
| let others = "22276-service" | |
| // Function verifies if customer selected the local region (Metropolitana). | |
| function metropolitanaIsSelected() { | |
| return $.inArray($.trim($("#order_shipping_address_region option:selected").text()), ["Metropolitana"]) > -1; | |
| }; | |
| // Function to hide/show the correct local method. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* Fields that can be marked as optional in Settings > Checkout */ | |
| function justHide(field) { | |
| $("#billing_address_" + field).hide(); | |
| } | |
| $(document).ready(function() { | |
| // Postal Code | |
| justHide("postal"); |