This file contains 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 jQuery = require('jquery'); | |
(function ($) { | |
/** | |
* @function | |
* @property {object} jQuery plugin which runs handler function once specified element is inserted into the DOM | |
* @param {function} handler A function to execute at the time when the element is inserted | |
* @param {bool} shouldRunHandlerOnce Optional: if true, handler is unbound after its first invocation | |
* @example $(selector).waitUntilExists(function); |
This file contains 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
# Add the following to your app.js file. | |
Vue.filter('extract', function (values, option_value, option_label) { | |
var response = []; | |
values.forEach(function (value) { | |
response.push({ | |
text: value[option_label], |
This file contains 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 template contains 'cart' %} | |
<script type="text/javascript"> | |
$(document).ready(function() { | |
$("[name='checkout']").on("click", function() { | |
var date = $(".zapietCollectionDate").val(); | |
var locationId = $(".clickCollectLocation").val(); | |
if(locationId != 'none') { | |
if(date == '') { |
This file contains 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
1). Add the following code towards the bottom of your theme.liquid file. Ensure it's above the code shown in step 2. | |
<script> | |
function checkDateTime() { | |
$("[name='checkout']").on("click", function() { | |
var date = $(".zapietCollectionDate").val(); | |
var locationId = $(".clickCollectLocation").val(); |
This file contains 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 template contains 'cart' %} | |
<script type="text/javascript"> | |
$(document).ready(function() { | |
$("[name='checkout']").on("click", function() { | |
var date = $(".zapietCollectionDate").val(); | |
if(date == '') { | |
alert('Please select a date and time.'); | |
return false; | |
} |
This file contains 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
<p>Thank you for placing your order with {{ shop_name }}!</p> | |
<p>This email is to confirm your recent order.</p> | |
<p>Date {{ date | date: "%m/%d/%Y" }}</p> | |
{% if requires_shipping and shipping_address %} | |
<p><b>{% if attributes.Store-Pickup-Order == "Yes" %}Pickup location{% else %}Shipping address{% endif %}</b><br /> | |
{% if attributes.Store-Pickup-Order == "Yes" %}{{ shipping_address.company }}{% else %}{{ shipping_address.name }}{% endif %}<br /> | |
{{ shipping_address.street }}<br /> | |
{{ shipping_address.city }}<br /> | |
{{ shipping_address.province }} | |
{{ shipping_address.zip }}<br /> |
This file contains 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
<p>Hello {{ shop_name }},</p> | |
<p></p> | |
<p>{% if customer.name %}{{ customer.name }}{% else %}Someone{% endif %} placed a new order with your store, {{ date | date: "%b %d %I:%M%p" }}:</p> | |
<p></p> | |
<ul> {% for line in line_items %} <li> <img src="{{ line | img_url: 'thumb' }}" /> {{ line.quantity }}x {{ line.title }} for {{ line.price | money }} each </li> {% endfor %} </ul> | |
<a href="https://{{ shop.permanent_domain }}/admin/orders/{{ id }}">View order {{order_name}} </a> | |
{% if fulfillment_aborted %} | |
<p>The above order was not automatically fulfilled because it was flagged as suspicious.</p>{% endif %} | |
<p></p><br> | |
{% if has_high_risks? %}<p><b>Security check:</b></p> |
This file contains 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
{ | |
"Canada": { | |
"label": "Province", | |
"zip_label": "Postal code", | |
"zip_placeholder": "Postal code", | |
"zip_required": true, | |
"province_label": "Province", | |
"provinces": [ | |
"Alberta", | |
"British Columbia", |
This file contains 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
<p>Thank you for placing your order with {{ shop_name }}!</p> | |
<p>This email is to confirm your recent order.</p> | |
<p>Date {{ date | date: "%m/%d/%Y" }}</p> | |
{% if requires_shipping and shipping_address %} | |
<p><b>{% if attributes.Checkout-Method == "pickup" %}Pickup location{% elsif attributes.Checkout-Method == "delivery" %}Delivery address{% else %}Shipping address{% endif %}</b><br /> | |
{% if attributes.Checkout-Method == "pickup" %} | |
{{ shipping_address.company }}<br /> | |
{% else %} | |
{{ shipping_address.name }}<br /> | |
{% endif %} |
This file contains 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
<p>Hello {{ shop_name }},</p> | |
<p></p> | |
<p>{% if customer.name %}{{ customer.name }}{% else %}Someone{% endif %} placed a new order with you today, {{ date | date: "%b %d %I:%M%p" }}:</p> | |
<p></p> | |
<ul style="list-style-type:none">{% for line in line_items %}<li> <img src="{{ line | img_url: 'thumb' }}" /> {{ line.quantity }}x {{line.title }} (sku: {{ line.sku }})<br>{% for p in line.properties %}{% if p.first == "builder_id" or p.first == "builder_info" or p.first == "master_builder" or p.last == "" %}{% else %}{{ p.first }}: {% if p.last contains '/uploads/' %}<a class="lightbox" href="{{ p.last }}">{{ p.last | split: '/' | last }}</a><br>{% else %}{{ p.last }}<br>{% endif %}{% endif %}{% endfor %}</li>{% endfor %}</ul> | |
<a href="{{ shop.url }}/admin/orders/{{ id }}">View order {{order_name}} </a> | |
{% if fulfillment_aborted %} | |
<p>The above order was not automatically fulfilled because it was flagged as suspicious.</p>{% endif %} | |
<p></p><br> |
OlderNewer