{{nums.formatReduceCost(item)}} 兑换券 {{nums.formatDiscount(item)}} {{nums.formatLeastCost(item)}} {{item.title}} {{item.validTimesStr}} 立即使用 {{item.stateStr}} {{item.num}}张 使用规则 适用门店: 全国所有门店 适用部分门店 点击查看>> 随领取门店可用 适用商品: 特价商品除外 适用部分商品 点击查看>> 适用场景: 门店 使用规则: {{item.description}} module.exports.formatReduceCost = function (item) { if (item.formatReduceCost) { return item.formatReduceCost; } else if (item.reduceCost) { return parseFloat(parseInt(item.reduceCost * 100) / 10000) } return 0 } module.exports.formatLeastCost = function (item) { if (!item.formatLeastCost) { item.formatLeastCost = parseFloat(parseInt((item.leastCost || 0) * 100) / 10000) } if (item.formatLeastCost == 0) { return "无限制" } return "满" + item.formatLeastCost + "元" } module.exports.formatDiscount = function(item) { if (item.formatDiscount) { return item.formatDiscount } else if (item.discount) { return parseFloat(parseInt((item.discount || 0) * 10) / 100) } return 0 } module.exports.priceClass = function(item) { if (item.type.value == "C") { if (item.reduceCost >= 100) { return "_small" } return 100 } if (item.type.value == "D" ) { if (item.discount >= 10) { return "_small" } return "" } return "" }