From b1a2f47275decbfc29aa989ad111e2607aa4205d Mon Sep 17 00:00:00 2001
From: zouyu <2723363702@qq.com>
Date: 星期二, 21 七月 2026 10:32:11 +0800
Subject: [PATCH] 删除排班点击确认触发表单必填校验

---
 src/views/performance/class/index.vue |   30 +++++++++++++++++-------------
 1 files changed, 17 insertions(+), 13 deletions(-)

diff --git a/src/views/performance/class/index.vue b/src/views/performance/class/index.vue
index b549c43..aab0f1f 100644
--- a/src/views/performance/class/index.vue
+++ b/src/views/performance/class/index.vue
@@ -796,20 +796,24 @@
   methods: {
     //纭鍒犻櫎鎺掔彮
     confirmDelScheduling() {
-      const data = {
-        userIdList: this.delSchedulingForm.userIdList,
-        startTime: this.delSchedulingForm.dateRange[0],
-        endTime: this.delSchedulingForm.dateRange[1],
-      }
-      delShift(data).then(res => {
-        if(res.code === 200) {
-          this.$message.success("鍒犻櫎鎴愬姛");
-          this.closeSchedulingDelDialog()
-          this.refreshTable()
+      this.$refs.delSchedulingFormRef.validate(valid => {
+        if (valid) {
+          const data = {
+            userIdList: this.delSchedulingForm.userIdList,
+            startTime: this.delSchedulingForm.dateRange[0],
+            endTime: this.delSchedulingForm.dateRange[1],
+          }
+          delShift(data).then(res => {
+            if(res.code === 200) {
+              this.$message.success("鍒犻櫎鎴愬姛");
+              this.closeSchedulingDelDialog()
+              this.refreshTable()
+            }
+          }).catch(err => {
+            console.error(err);
+            this.closeSchedulingDelDialog()
+          })
         }
-      }).catch(err => {
-        console.error(err);
-        this.closeSchedulingDelDialog()
       })
     },
     closeSchedulingDelDialog(){

--
Gitblit v1.9.3