diff --git a/src/views/table/components/addTable.vue b/src/views/table/components/addTable.vue index adf97ab..7ed3aba 100644 --- a/src/views/table/components/addTable.vue +++ b/src/views/table/components/addTable.vue @@ -32,13 +32,13 @@ > - +
- +
@@ -140,6 +140,7 @@ export default { form: { id: "", areaId: "", + sign:'', start:1, end:10, capacity: 0, @@ -157,6 +158,13 @@ export default { trigger: "blur", }, ], + sign: [ + { + required: true, + message: "请输入台桌标识", + trigger: "blur", + }, + ], }, areaList: [], }; diff --git a/src/views/table/components/table-diancan.vue b/src/views/table/components/table-diancan.vue index 32a2c07..84d5750 100644 --- a/src/views/table/components/table-diancan.vue +++ b/src/views/table/components/table-diancan.vue @@ -1374,15 +1374,15 @@ export default { }, }, watch: { - perpole(newval) { - if (newval&&this.table.tableId) { - $choseCount({ - masterId: this.masterId, - tableId: this.table.tableId, - num: newval, - }).then(res=>{ - this.order.seatFee=res - }) + perpole(newval,oldval) { + if (!oldval&&newval&&this.table.tableId) { + // $choseCount({ + // masterId: this.masterId, + // tableId: this.table.tableId, + // num: newval, + // }).then(res=>{ + // this.order.seatFee=res + // }) } }, table(oldval, newval) { @@ -1535,6 +1535,16 @@ export default { // this.refToggle("refDiscount", true); }, methods: { + //更改就餐人数 + changePerpole(){ + $choseCount({ + masterId: this.masterId, + tableId: this.table.tableId, + num: this.perpole, + }).then(res=>{ + this.order.seatFee=res + }) + }, //台桌变化时重新获取取餐号、购物车数据,如果是正在结账状态,创建订单到待支付页面 async onTableChange() { const res = await this.getMasterId(); @@ -1597,6 +1607,8 @@ export default { }, chooseDinersNumberConfirm(e) { this.perpole = e; + this.changePerpole() + }, //扫码支付弹窗确认 scanPayConfirm(code) { @@ -2726,6 +2738,7 @@ export default { // if(this.key!=='isPayOrder'){ // this.getCart(); // } + this.changePerpole() this.getCart(); this.getGoods(); this.getCategory();