shish 2 ani în urmă
părinte
comite
8ba5ae6e48
1 a modificat fișierele cu 6 adăugiri și 2 ștergeri
  1. 6 2
      ghs/src/views/order/add.vue

+ 6 - 2
ghs/src/views/order/add.vue

@@ -333,8 +333,12 @@ export default {
         that.form.needPrint = 1
         that.form.needPrint = 1
       }
       }
       if(e && e.key=='Delete'){
       if(e && e.key=='Delete'){
-        that.selectList.splice(that.selectIndex, 1);
-        that.$refs.singleTable.setCurrentRow(that.selectList[0]);
+        let current = that.selectList[that.selectIndex]
+        that.$confirm('确定删除 '+current.name+'?', '提示', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' }).then(() => {
+          current.bigCount = 0
+          that.replaceItemFn(current,1,'sub')
+          that.$refs.singleTable.setCurrentRow(that.selectList[0])
+        })
       }
       }
       if(e && e.key=='PageDown'){
       if(e && e.key=='PageDown'){
         that.removeFromSave()
         that.removeFromSave()