diff --git a/pages/mall/information-item/index.wxml b/pages/mall/information-item/index.wxml index 3dbf0f1..267b753 100644 --- a/pages/mall/information-item/index.wxml +++ b/pages/mall/information-item/index.wxml @@ -1,20 +1,32 @@ - + {{item.categoryName}} {{item.shortName}} {{item.latestQuoteTime}} - - + + {{formate.formatePrice(item.quotedPrice, 0)}} - 当前价 + 当前价 - - {{formate.formatePrice(item.floatingQuotedPrice, 0) || '- -'}} - 较上次 + + {{stringUtil.roundPrice(item.floatingQuotedPrice)}} + 较上次 - \ No newline at end of file + + + + var roundPrice = function(val){ + if(val > 0){ + return '+' + (val * 1000) + } else if(val < 0){ + return (val * 1000) + } + return '- -' + } + module.exports.roundPrice = roundPrice; + \ No newline at end of file