Просмотр исходного кода

提交订单价格不对问题

yangc 7 лет назад
Родитель
Сommit
4eee53f720
2 измененных файлов с 3 добавлено и 2 удалено
  1. 1 0
      pages/mobile/center/user/cart.vue
  2. 2 2
      pages/mobile/center/user/pay/_orderId.vue

+ 1 - 0
pages/mobile/center/user/cart.vue

@@ -384,6 +384,7 @@
             this.setRemindText('选中的购物车信息已经失效,将为您刷新界面之后重新操作')
             setTimeout(() => {
               this.page = 1
+              this.cartList = []
               this.reloadList()
             }, 1500)
           } else {

+ 2 - 2
pages/mobile/center/user/pay/_orderId.vue

@@ -139,7 +139,7 @@
             </div>
           </div>
           <div class="fr">
-            <p class="ol-price text-ellipse"><span>{{cGoods.currencyName | currencyFilter}}</span>{{cGoods.price}}</p>
+            <p class="ol-price text-ellipse"><span>{{cGoods.currencyName | currencyFilter}}</span>{{cGoods.taxUnitprice}}</p>
             <p class="count text-ellipse">x&nbsp;{{cGoods.number}}</p>
           </div>
         </li>
@@ -437,7 +437,7 @@
       getTotalPrice (storeItem) {
         let price = 0
         storeItem.goods.forEach(item => {
-          price += item.price * item.number
+          price += item.price
         })
         return Number(price.toFixed(6))
       },