caoliqin преди 1 месец
родител
ревизия
3bd26f866f
променени са 1 файла, в които са добавени 7 реда и са изтрити 1 реда
  1. 7 1
      src/views/course/userCoursePeriod/index.vue

+ 7 - 1
src/views/course/userCoursePeriod/index.vue

@@ -724,8 +724,14 @@ export default {
     },
     /** 删除按钮操作 */
     handleDelete(row) {
+      //添加删除判断,只能删除未开始的营期
+      console.log(row.periodStatus)
+      if(row.periodStatus !== 1){
+        this.$message.error('营期处于进行中或者结束,不能删除');
+        return;
+      }
       const periodIds = row.periodId || this.ids;
-      this.$confirm('是否确认删除会员营期编号为"' + periodIds + '"的数据项?', "警告", {
+      this.$confirm('是否确认删除该营期?', "警告", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
           type: "warning"