${function() {
const variantData = data.variant || {"id":"9b611d13-60ed-4861-9358-cde1f6336bcf","product_id":"78c5e8b1-1cbe-429c-afac-4d3bd089530c","title":"Blue-USB","weight_unit":"kg","inventory_quantity":1000,"sku":"CJJT132425401AZ","barcode":"","position":1,"option1":"Blue","option2":"USB","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/b9fc26c1df39b3744bac23c15b6562a4.jpeg","path":"b9fc26c1df39b3744bac23c15b6562a4.jpeg","width":529,"height":569,"alt":"","aspect_ratio":0.929701230228471},"wholesale_price":[{"price":34,"min_quantity":1}],"weight":"0","compare_at_price":"60","price":"34","retail_price":"60","available":true,"url":"\/products\/portable-blender-electric-fruit-juicer-usb-rechargeable-smoothie-blender-mini-fruit-juice-maker-handheld-kitchen-mixer-vegetable-blendersc56f715b-244a-45c4-b3f4-490eb1d96428?variant=9b611d13-60ed-4861-9358-cde1f6336bcf","available_quantity":999999999,"options":[{"name":"Color","value":"Blue"},{"name":"Electrical outlet","value":"USB"}],"off_ratio":43,"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
: Blue
${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}
`
}()}
Electrical Outlet
: USB
${function(){
const optName = "Electrical outlet";
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.00
${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":"9b611d13-60ed-4861-9358-cde1f6336bcf","product_id":"78c5e8b1-1cbe-429c-afac-4d3bd089530c","title":"Blue-USB","weight_unit":"kg","inventory_quantity":1000,"sku":"CJJT132425401AZ","barcode":"","position":1,"option1":"Blue","option2":"USB","option3":"","note":"","image":{"src":"\/\/img.staticdj.com\/b9fc26c1df39b3744bac23c15b6562a4.jpeg","path":"b9fc26c1df39b3744bac23c15b6562a4.jpeg","width":529,"height":569,"alt":"","aspect_ratio":0.929701230228471},"wholesale_price":[{"price":34,"min_quantity":1}],"weight":"0","compare_at_price":"60","price":"34","retail_price":"60","available":true,"url":"\/products\/portable-blender-electric-fruit-juicer-usb-rechargeable-smoothie-blender-mini-fruit-juice-maker-handheld-kitchen-mixer-vegetable-blendersc56f715b-244a-45c4-b3f4-490eb1d96428?variant=9b611d13-60ed-4861-9358-cde1f6336bcf","available_quantity":999999999,"options":[{"name":"Color","value":"Blue"},{"name":"Electrical outlet","value":"USB"}],"off_ratio":43,"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.