Commit 90b3e101 by 张立顺

fix bug 多规格车型不出来问题

1 parent 9a809bed
...@@ -621,7 +621,8 @@ export default { ...@@ -621,7 +621,8 @@ export default {
tableInfo: [], tableInfo: [],
upgradeGoodsInfo: { upgradeGoodsInfo: {
suitCarType: 1 suitCarType: 1
} },
orgData: {}
} }
}, },
computed: { computed: {
...@@ -759,8 +760,17 @@ export default { ...@@ -759,8 +760,17 @@ export default {
console.log(item) console.log(item)
return item.skuId == selectId return item.skuId == selectId
}) })
// specificationData
console.log(skusItem, 'skusItem') console.log(skusItem, 'skusItem')
console.log(this.goodsInfo, 'this.goodsInfo')
if (this.orgData) {
const spcName = skusItem.skusTypes.map(item => item.propertyName).join(';~;')
this.upgradeGoodsInfo = this.orgData.upgradeGoodsList.find(item => item.specificationData == spcName)
console.log(this.upgradeGoodsInfo, ' this.upgradeGoodsInfo')
}
// this.upgradeGoodsInfo = selectSpc.suitCarType
this.handleItemInfo.purchasePrice = skusItem.purchasePrice this.handleItemInfo.purchasePrice = skusItem.purchasePrice
//goodsInfo upgradeGoodsList suitCarType
} else { } else {
this.handleItemInfo.purchasePrice = '' this.handleItemInfo.purchasePrice = ''
} }
...@@ -819,6 +829,7 @@ export default { ...@@ -819,6 +829,7 @@ export default {
this.$apis.purchaseShopping.getByIdWithSpecification({ id: this.goodsId }).then(res => { this.$apis.purchaseShopping.getByIdWithSpecification({ id: this.goodsId }).then(res => {
// goodsSpecificationNameList 商品 // goodsSpecificationNameList 商品
res = res.data res = res.data
this.orgData = this.$common.utils.deepClone(res)
console.log(res, 'res') console.log(res, 'res')
if (res?.specificationType == 2) { if (res?.specificationType == 2) {
...@@ -924,7 +935,6 @@ export default { ...@@ -924,7 +935,6 @@ export default {
params = { params = {
goodsNumber: this.handleItemInfo.goodsNumber, goodsNumber: this.handleItemInfo.goodsNumber,
upgradeGoodsId: item.upgradeGoodsId, upgradeGoodsId: item.upgradeGoodsId,
suitCarTypeList: this.goodsInfo.suitCarTypeList, suitCarTypeList: this.goodsInfo.suitCarTypeList,
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!