|
@@ -4,7 +4,11 @@
|
|
|
var timeString = timeTemp.toLocaleDateString() + timeTemp.toLocaleTimeString();
|
|
|
return timeString.replace('/','-').replace('/','-').replace('上午',' ').replace('下午',' ');
|
|
|
}
|
|
|
+ function parseDouble(number) {
|
|
|
+ return parseFloat(number).toFixed(2);
|
|
|
+ }
|
|
|
module.exports.formatDate = formatDate;
|
|
|
+ module.exports.parseDouble = parseDouble;
|
|
|
</wxs>
|
|
|
<view class='walletDetails'>
|
|
|
<view class="walletDetails-center">
|
|
@@ -22,11 +26,11 @@
|
|
|
<view class="walletDetails-right">
|
|
|
<view class="avatar-value-pos" wx:if="{{ item.type === 'INCOME' }}">
|
|
|
<text class="avatar-symbol">+</text>
|
|
|
- <text>{{ item.price / 100 }}</text>
|
|
|
+ <text>{{ wxs.parseDouble(item.price / 100) }}</text>
|
|
|
</view>
|
|
|
<view class="avatar-value-neg" wx:else>
|
|
|
<text class="avatar-symbol">-</text>
|
|
|
- <text>{{ item.price / 100 }}</text>
|
|
|
+ <text>{{ wxs.parseDouble(item.price / 100) }}</text>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|