Commit 629f4927 by zhangxw

提示层级低历史遗留bug修复

1 parent daf430d3
......@@ -928,7 +928,11 @@ export default {
return pre
}, '')
if (flag) {
return this.$message.error('请选择规格')
return this.$message({
message:'请选择规格',
type: 'error',
customClass: 'msgHierarchy'
})
}
orgdata.skus.find(item => {
console.log(item, item.skuId, selectId)
......@@ -952,19 +956,31 @@ export default {
suitCarTypeList: this.goodsInfo.suitCarTypeList,
}
if (!params.upgradeGoodsId) {
this.$message.error('商品不存在')
this.$message({
message:'商品不存在',
type: 'error',
customClass: 'msgHierarchy'
})
return
}
}
// 如果是专用商品 但没有选适配车型
if (this.upgradeGoodsInfo.suitCarType == 2 && !this.goodsInfo.suitCarTypeList?.length) {
return this.$message.error('请完善商品适用车型')
return this.$message({
message:'请完善商品适用车型',
type: 'error',
customClass: 'msgHierarchy'
})
}
// 判断是否有值
params.upgradeGoodsId &&
this.$apis.purchaseShopping.shoppingCarAdd(params).then(res => {
console.log(res, 'res')
this.$message.success('加入购物车成功')
this.$message({
message:'加入购物车成功',
type: 'success',
customClass: 'msgHierarchy'
})
this.$EventBus.$emit('updateCarShopping')
this.dialogShow = false
})
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!