${function() {
const variantData = data.variant || {"id":"5b4f47cc-6d5e-4c0e-89ec-0f62fb490338","product_id":"84c4b19c-4352-4f9f-9692-2a1b3357fd45","title":"BLACK-UK 6","weight_unit":"kg","inventory_quantity":1000,"sku":"MD1410572-_S","barcode":"","position":1,"option1":"BLACK","option2":"UK 6","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/a2efd9af81b1dd561226ee17c6569e7e.jpeg","path":"a2efd9af81b1dd561226ee17c6569e7e.jpeg","width":800,"height":800,"alt":"","aspect_ratio":1},"wholesale_price":[{"price":34.99,"min_quantity":1}],"weight":"0","compare_at_price":"59.99","price":"34.99","retail_price":"59.99","available":true,"url":"\/products\/hooded-jacket-faux-fur-ladies-vest-cardiganc90e6c5a-2fbf-4f6d-91a7-74d74ab0d1c4?variant=5b4f47cc-6d5e-4c0e-89ec-0f62fb490338","available_quantity":999999999,"options":[{"name":"color","value":"BLACK"},{"name":"size","value":"UK 6"}],"off_ratio":42,"flashsale_info":[],"sales":0};
const saveType = "amount";
const saveText = "Save {{saved_amount}}";
const productLabelDiscountOn = true;
return `
-
${saveText.replace('\{\{saved_amount\}\}',
saveType == 'percentage'
? variantData.off_ratio + '%'
: ` `
)}
`;
}()}
Color
: BLACK
${function(){
const optName = "color";
const optionValue = data.originData.selectData ? data.originData.selectData[optName].value : data.originData.value;
const optionValueText = optionValue ? (': ' + optionValue) : '';
return `
${optionValueText}
`
}()}
${function(){
const tipText = "Please select a {{ name }}".replace(/\{\{\s+name\s+\}\}/g, data);
return `${tipText}
`
}()}
Size
: UK 6
${function(){
const optName = "size";
const optionValue = data.originData.selectData ? data.originData.selectData[optName].value : data.originData.value;
const optionValueText = optionValue ? (': ' + optionValue) : '';
return `
${optionValueText}
`
}()}
${function(){
const tipText = "Please select a {{ name }}".replace(/\{\{\s+name\s+\}\}/g, data);
return `${tipText}
`
}()}
Add to cart
$34.99
${function(){
const wholesale_enabled = false;
const qty = data.quantity || 1;
const currentSelectVariant = data.variant;
const defaultVariant = (data.product && data.product.variants && data.product.variants[0]);
const productVariant = {"id":"5b4f47cc-6d5e-4c0e-89ec-0f62fb490338","product_id":"84c4b19c-4352-4f9f-9692-2a1b3357fd45","title":"BLACK-UK 6","weight_unit":"kg","inventory_quantity":1000,"sku":"MD1410572-_S","barcode":"","position":1,"option1":"BLACK","option2":"UK 6","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/a2efd9af81b1dd561226ee17c6569e7e.jpeg","path":"a2efd9af81b1dd561226ee17c6569e7e.jpeg","width":800,"height":800,"alt":"","aspect_ratio":1},"wholesale_price":[{"price":34.99,"min_quantity":1}],"weight":"0","compare_at_price":"59.99","price":"34.99","retail_price":"59.99","available":true,"url":"\/products\/hooded-jacket-faux-fur-ladies-vest-cardiganc90e6c5a-2fbf-4f6d-91a7-74d74ab0d1c4?variant=5b4f47cc-6d5e-4c0e-89ec-0f62fb490338","available_quantity":999999999,"options":[{"name":"color","value":"BLACK"},{"name":"size","value":"UK 6"}],"off_ratio":42,"flashsale_info":[],"sales":0};
const variantData = currentSelectVariant || defaultVariant || productVariant;
const wholesale_price = variantData.wholesale_price || [];
if(wholesale_enabled && wholesale_price.length > 0) {
let wholesaleIndex = wholesale_price.findIndex(item => {
return item.min_quantity > qty;
});
if(wholesaleIndex < 0){
wholesaleIndex = wholesale_price.length - 1;
}else if(wholesaleIndex > 0){
wholesaleIndex = wholesaleIndex - 1;
}
const wholesalePrice = wholesale_price[wholesaleIndex] || '';
return `
`
}else {
const price = variantData && variantData.price;
return price != undefined ? `
` : ' ';
}
}()}
Buy now
Product was out of stock.
Product is unavailable.