가격
${function() {
const selectedVariant = data.variants.find(v => v.available) || data.variants[0];
return !!selectedVariant ? `
최저
` : `
-
`;
}()}
${function() {
const selectedVariant = data.variants.find(v => v.available) || data.variants[0];
const statusLan = (
(selectedVariant && !selectedVariant.available) ||
(!selectedVariant && !data.available)) ?
"\ub9e4\uc9c4" :
"\uc7a5\ubc14\uad6c\ub2c8";
const status = (
(selectedVariant && !selectedVariant.available) ||
(!selectedVariant && !data.available)) ? 'soldout' : 'available';
return `
제품을 사용할 수 없습니다.
제품이 품절되었습니다.
`;
}()}
${function() {
const MAX_INVENTORY = 999999;
const product0 = Object.prototype.toString.call(data) == '[object Array]' ? data[0] : data;
const inventoryQty = product0.inventory_quantity;
const inventoryPolicy = product0.inventory_policy;
const inventoryTracking = product0.inventory_tracking;
const lowStock = 5;
let actualInventory = inventoryQty;
if ((inventoryTracking && inventoryPolicy == 'continue') || !inventoryTracking) {
actualInventory = MAX_INVENTORY;
}
return `
Avaliability:
품절
재고, 배송 준비
낮은 주식
`;
}()}