dedsudiyu лет назад: 2
Родитель
Сommit
dffcf3c7e7
1 измененных файлов с 6 добавлено и 0 удалено
  1. 6 0
      src/views/safetyCheck/startInspection/index.vue

+ 6 - 0
src/views/safetyCheck/startInspection/index.vue

@@ -327,6 +327,12 @@
       upDataButton(type){
         this.$refs["addForm"].validate(valid => {
           if (valid) {
+            let startTime = Date.parse(new Date(this.addForm.dateRange[0]));
+            let currentTime = Date.parse(new Date);
+            if(currentTime<startTime){
+              this.msgError('当前时间不在计划周期内')
+              return
+            }
             if(this.planType == 1){
               //新计划
               let obj = JSON.parse(JSON.stringify(this.addForm));