diff --git a/mall4v/src/components/prods-select/index.vue b/mall4v/src/components/prods-select/index.vue index c99fad0..644c914 100644 --- a/mall4v/src/components/prods-select/index.vue +++ b/mall4v/src/components/prods-select/index.vue @@ -51,8 +51,7 @@ layout="total, sizes, prev, pager, next, jumper"> - 取消 + 取消 确定 @@ -164,6 +163,15 @@ export default { }, // 确定事件 submitProds () { + if (!this.dataListSelections.length) { + this.$message({ + message: '请选择商品', + type: 'error', + duration: 1000, + onClose: () => {} + }) + return + } let prods = [] this.dataListSelections.forEach(item => { let prodIndex = prods.findIndex((prod) => prod.prodId === item.prodId)