mo 5 anni fa
parent
commit
589c9e5bd0

+ 16 - 10
src/views/categroyManager/generalSettings/vipParameterManager.vue

@@ -264,16 +264,22 @@ export default {
       // 判断是添加还是修改
       if (this.vipStatusFrom.isAdd) {
         // 添加
-        addVipGroupCategory({
-          name: this.vipStatusFrom.name,
-          singleClassMinutes: this.dynamicTags.join(','),
-          studentNum: this.vipStatusFrom.num
-        }).then(res => {
-          if (res.code == 200) {
-            this.getVipGroupCategoryList();
-            this.vipStatus = false;
-          }
-        })
+        if (this.vipStatusFrom.name && this.vipStatusFrom.num && this.dynamicTags.length > 0) {
+          addVipGroupCategory({
+            name: this.vipStatusFrom.name,
+            singleClassMinutes: this.dynamicTags.join(','),
+            studentNum: this.vipStatusFrom.num
+          }).then(res => {
+            if (res.code == 200) {
+              this.getVipGroupCategoryList();
+              this.vipStatus = false;
+            }
+          })
+        } else {
+          this.$message.error('请填写参数')
+          return
+        }
+
       } else {
         // 修改
         resetVipGroupCategory({

+ 5 - 1
src/views/categroyManager/vipChargeSeting.vue

@@ -11,7 +11,6 @@
           <el-select class='multiple'
                      style="width:180px!important"
                      v-model="searchForm.organId"
-                     clearable
                      filterable
                      placeholder="请选择分部">
             <el-option v-for="(item,index) in organList"
@@ -83,6 +82,11 @@ export default {
     getEmployeeOrgan().then(res => {
       if (res.code == 200) {
         this.organList = res.data;
+        this.searchForm.organId = this.organList[0].id;
+        if (this.organList[0].id) {
+          this.getList();
+        }
+
       }
     })
     // this.getList();