|
|
@@ -21,8 +21,8 @@
|
|
|
<view class="product-area">
|
|
|
<view class="first-area">
|
|
|
<text class="name">{{res.name}}</text>
|
|
|
- <text class="cg-cost">¥{{cgPriceList[res.id]?parseFloat(cgPriceList[res.id]):0}}</text>
|
|
|
- <text class="cost-price">¥{{res.cost?parseFloat(res.cost):0}}</text>
|
|
|
+ <text class="cg-cost">¥{{itemPriceList[res.id].cgPrice?parseFloat(itemPriceList[res.id].cgPrice):0}}</text>
|
|
|
+ <text class="cost-price">¥{{itemPriceList[res.id].cost?parseFloat(itemPriceList[res.id].cost):0}}</text>
|
|
|
<input type="digit" v-model="res.autoPrice" placeholder="花店价" @focus="priceFocus(i,res)" @input="modifyPrice(i,res)" />
|
|
|
<input type="digit" v-model="res.autoSkPrice" placeholder="散客价" @focus="skPriceFocus(i,res)" @input="modifySkPrice(res)" />
|
|
|
</view>
|
|
|
@@ -49,7 +49,7 @@ export default {
|
|
|
cgItemList:[],
|
|
|
flowersList:[],
|
|
|
productList:[],
|
|
|
- cgPriceList:[],
|
|
|
+ itemPriceList:[],
|
|
|
status:0
|
|
|
};
|
|
|
},
|
|
|
@@ -90,7 +90,7 @@ export default {
|
|
|
|
|
|
list.forEach((ele)=>{
|
|
|
productIdArr += ele.productId+','
|
|
|
- that.cgPriceList[ele.productId] = ele.bigPrice
|
|
|
+ that.itemPriceList[ele.productId] = {cgPrice:ele.bigPrice,cost:ele.cost}
|
|
|
})
|
|
|
|
|
|
getAllProductDataApi({ids : productIdArr.substring(0, productIdArr.lastIndexOf(',')),}).then((res)=>{
|