KuKirin G3 Electric Scooter Official Accessories(All)
${function() {
const variantData = data.variant || {"id":"7a7494fd-a8e2-49cb-af27-6731ffd538a6","product_id":"6938213c-9a4b-4a08-81b4-bf0f89414f4a","title":"Accelerator\/Throttle-New Version","weight_unit":"kg","inventory_quantity":-24,"sku":"KUGOO KIRIN G3 \u52a0\u901f\u5668-\u65b0\u6b3e","barcode":"","position":1,"option1":"Accelerator\/Throttle-New Version","option2":"","option3":"","note":"","image":{"src":"\/\/img.fantaskycdn.com\/96bc78902bcb220163519f16bf4f7038.jpg","path":"96bc78902bcb220163519f16bf4f7038.jpg","width":1080,"height":1920,"alt":"","aspect_ratio":0.5625},"wholesale_price":[{"price":27,"min_quantity":1}],"weight":"0","compare_at_price":"0","price":"27","retail_price":"0","available":true,"url":"\/products\/kugoo-kirin-g3-electric-scooter-official-accessories-phsz?variant=7a7494fd-a8e2-49cb-af27-6731ffd538a6","available_quantity":999999999,"options":[{"name":"Parts & Accessories","value":"Accelerator\/Throttle-New Version"}],"off_ratio":0,"flashsale_info":[],"sales":6};
const saveType = "amount";
const productLabelDiscountOn = true;
const map = {
B: ` `,
C: ` `,
A: `
${saveType == 'percentage'
? `-${variantData.off_ratio}%`
: `- `
}
`
}
const price_group_arr = ["B","C","A"];
const price_str_arr = price_group_arr.map(type => map[type]);
return `
-
${price_str_arr.join('')}
`;
}()}
Parts & Accessories:
Accelerator/Throttle-New Version
${function(){
const optName = "Parts & Accessories";
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
£27.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":"7a7494fd-a8e2-49cb-af27-6731ffd538a6","product_id":"6938213c-9a4b-4a08-81b4-bf0f89414f4a","title":"Accelerator\/Throttle-New Version","weight_unit":"kg","inventory_quantity":-24,"sku":"KUGOO KIRIN G3 \u52a0\u901f\u5668-\u65b0\u6b3e","barcode":"","position":1,"option1":"Accelerator\/Throttle-New Version","option2":"","option3":"","note":"","image":{"src":"\/\/img.fantaskycdn.com\/96bc78902bcb220163519f16bf4f7038.jpg","path":"96bc78902bcb220163519f16bf4f7038.jpg","width":1080,"height":1920,"alt":"","aspect_ratio":0.5625},"wholesale_price":[{"price":27,"min_quantity":1}],"weight":"0","compare_at_price":"0","price":"27","retail_price":"0","available":true,"url":"\/products\/kugoo-kirin-g3-electric-scooter-official-accessories-phsz?variant=7a7494fd-a8e2-49cb-af27-6731ffd538a6","available_quantity":999999999,"options":[{"name":"Parts & Accessories","value":"Accelerator\/Throttle-New Version"}],"off_ratio":0,"flashsale_info":[],"sales":6};
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 does not exist
${function() {
const minDays = parseInt('3');
const maxDays = parseInt('7');
const customText = "Estimated Delivery\uff1a{min_date} - {max_date}";
const minDate = new Date(Date.now() + (minDays * 86400000));
const maxDate = new Date(Date.now() + (maxDays * 86400000));
const formatDate = (minDate.getFullYear() == maxDate.getFullYear() && minDate.getFullYear() == new Date().getFullYear())
? new Intl.DateTimeFormat('en', { month: 'short', day: '2-digit' })
: new Intl.DateTimeFormat('en', { month: 'short', day: '2-digit', year: 'numeric' });
const tipText = customText.replace(/\{min_date\}/g, '' + formatDate.format(minDate) + ' ')
.replace(/\{max_date\}/g, '' + formatDate.format(maxDate) + ' ');
return `
${tipText}
`;
}()}