Commit 21a80cb8 by 姜雷

修复订单中金额显示

parent 761bb09a
......@@ -64,6 +64,8 @@ class OrderItem extends Component {
const {
data: { orderState, createAt, serviceName, payableMoney },
} = this.props;
let moneyStr = payableMoney.toFixed(2);
return (
<View className='OrderItem' onClick={this.detailHandle}>
<View className='OrderItem-text'>
......@@ -83,7 +85,7 @@ class OrderItem extends Component {
</View>
<View
className={`OrderItem-price ${orderState === '1' ? 'topay' : ''}`}>
{payableMoney.toFixed(2)}
{moneyStr}
</View>
</View>
);
......
......@@ -8,6 +8,7 @@ const RechargeItem = (props: { data: RechargeOrder }) => {
const {
data: { createAt, rechargeRemark, actualAmount, orderNum },
} = props;
let moneyStr = actualAmount.toFixed(2);
return (
<View className='RechargeItem'>
......@@ -26,7 +27,7 @@ const RechargeItem = (props: { data: RechargeOrder }) => {
</View>
<View
className={`RechargeItem-price ${actualAmount >= 0 ? 'topay' : ''}`}>
{actualAmount.toFixed(2)}
{moneyStr}
</View>
</View>
);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment