${function() {
const variantData = data.variant || {"id":"152886ed-d4e2-4100-a4da-da1792e2a94a","product_id":"afda0f53-eb7e-4345-a8c3-f49be80e415d","title":"","weight_unit":"kg","inventory_quantity":0,"sku":"","barcode":"","position":1,"option1":"","option2":"","option3":"","note":"","image":null,"wholesale_price":[{"price":0,"min_quantity":1}],"weight":"0","compare_at_price":"0","price":"0","retail_price":"0","available":true,"url":"\/products\/\u043a\u0440\u0443\u043f\u043d\u043e\u0442\u043e\u043d\u043d\u0430\u0436\u043d\u044b\u0439-\u0434\u0432\u043e\u0439\u043d\u043e\u0439-\u043d\u043e\u0436\u043d\u0438\u0446\u043a\u0438\u0439-\u043f\u043e\u0434\u044a\u0435\u043c\u043d\u0438\u043a-gaochang?variant=152886ed-d4e2-4100-a4da-da1792e2a94a","available_quantity":999999999,"options":[],"off_ratio":0,"flashsale_info":[],"sales":0};
const saveType = "percentage";
const saveText = "\u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c {{saved_amount}}";
const productLabelDiscountOn = true;
return `
-
${saveText.replace('\{\{saved_amount\}\}',
saveType == 'percentage'
? variantData.off_ratio + '%'
: ` `
)}
`;
}()}
Добавить в корзину
$0.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":"152886ed-d4e2-4100-a4da-da1792e2a94a","product_id":"afda0f53-eb7e-4345-a8c3-f49be80e415d","title":"","weight_unit":"kg","inventory_quantity":0,"sku":"","barcode":"","position":1,"option1":"","option2":"","option3":"","note":"","image":null,"wholesale_price":[{"price":0,"min_quantity":1}],"weight":"0","compare_at_price":"0","price":"0","retail_price":"0","available":true,"url":"\/products\/\u043a\u0440\u0443\u043f\u043d\u043e\u0442\u043e\u043d\u043d\u0430\u0436\u043d\u044b\u0439-\u0434\u0432\u043e\u0439\u043d\u043e\u0439-\u043d\u043e\u0436\u043d\u0438\u0446\u043a\u0438\u0439-\u043f\u043e\u0434\u044a\u0435\u043c\u043d\u0438\u043a-gaochang?variant=152886ed-d4e2-4100-a4da-da1792e2a94a","available_quantity":999999999,"options":[],"off_ratio":0,"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 {
return `
`
}
}()}
Купи сейчас
Товара не было в наличии.
Продукт недоступен.
${function(){
const variantData = data.variant || {"id":"152886ed-d4e2-4100-a4da-da1792e2a94a","product_id":"afda0f53-eb7e-4345-a8c3-f49be80e415d","title":"","weight_unit":"kg","inventory_quantity":0,"sku":"","barcode":"","position":1,"option1":"","option2":"","option3":"","note":"","image":null,"wholesale_price":[{"price":0,"min_quantity":1}],"weight":"0","compare_at_price":"0","price":"0","retail_price":"0","available":true,"url":"\/products\/\u043a\u0440\u0443\u043f\u043d\u043e\u0442\u043e\u043d\u043d\u0430\u0436\u043d\u044b\u0439-\u0434\u0432\u043e\u0439\u043d\u043e\u0439-\u043d\u043e\u0436\u043d\u0438\u0446\u043a\u0438\u0439-\u043f\u043e\u0434\u044a\u0435\u043c\u043d\u0438\u043a-gaochang?variant=152886ed-d4e2-4100-a4da-da1792e2a94a","available_quantity":999999999,"options":[],"off_ratio":0,"flashsale_info":[],"sales":0};
return `
Sku : ${variantData && variantData.sku}
Масса : ${variantData && variantData.weight}${variantData && variantData.weight_unit}
Штрих-код : ${variantData && variantData.barcode}
`
}()}