Pārlūkot izejas kodu

缴费状态修改

1
mo 2 gadi atpakaļ
vecāks
revīzija
5506a984f3

+ 1 - 0
src/layout/components/AppMain.vue

@@ -394,6 +394,7 @@ export default {
   background-color: #e5e5e5;
   background-color: #e5e5e5;
 }
 }
 .innerDrawer {
 .innerDrawer {
+  overflow-y: auto;
   .submitTitle {
   .submitTitle {
     margin: 10px 0;
     margin: 10px 0;
     font-size: 12px;
     font-size: 12px;

+ 47 - 33
src/views/resetTeaming/components/payInfoDetail.vue

@@ -588,8 +588,7 @@ export default {
               this.form.leixing = "1";
               this.form.leixing = "1";
               this.form.musicGroupOrganizationCourseSettingId =
               this.form.musicGroupOrganizationCourseSettingId =
                 res.data?.calender?.musicGroupOrganizationCourseSettingId;
                 res.data?.calender?.musicGroupOrganizationCourseSettingId;
-                this.isSetCourseSettingsId = true;
-
+              this.isSetCourseSettingsId = true;
             } else {
             } else {
               this.form.leixing = "2";
               this.form.leixing = "2";
             }
             }
@@ -651,7 +650,7 @@ export default {
                 this.teamCourse = true;
                 this.teamCourse = true;
 
 
                 this.$set(this.form, "eclass", res.data?.course);
                 this.$set(this.form, "eclass", res.data?.course);
-                console.log([...res.data?.course],'res.data?.course')
+                console.log([...res.data?.course], "res.data?.course");
                 this.initDetail = true;
                 this.initDetail = true;
                 this.$set(
                 this.$set(
                   this.form,
                   this.form,
@@ -682,21 +681,22 @@ export default {
                   }
                   }
                 }
                 }
               });
               });
-            }else{
+            } else {
               this.$set(
               this.$set(
-                  this.form,
-                  "calenderFeeType",
-                  res.data?.calender?.calenderFeeType
-                );
-                this.$set(
-                  this.form,
-                  "musicGroupCalenderRefundPeriods",
-                  res.data?.calenderRefundPeriods
-                );
+                this.form,
+                "calenderFeeType",
+                res.data?.calender?.calenderFeeType
+              );
+              this.$set(
+                this.form,
+                "musicGroupCalenderRefundPeriods",
+                res.data?.calenderRefundPeriods
+              );
               let calenderFeeJson = res.data?.calender?.calenderFeeJson;
               let calenderFeeJson = res.data?.calender?.calenderFeeJson;
-                if (calenderFeeJson) {
-                  calenderFeeJson = JSON.parse(calenderFeeJson);
-                  this.$set(this.form, "calenderFeeJson", calenderFeeJson);}
+              if (calenderFeeJson) {
+                calenderFeeJson = JSON.parse(calenderFeeJson);
+                this.$set(this.form, "calenderFeeJson", calenderFeeJson);
+              }
             }
             }
             if (res.data?.activity?.length > 0) {
             if (res.data?.activity?.length > 0) {
               this.teamActive = true;
               this.teamActive = true;
@@ -944,15 +944,15 @@ export default {
         }
         }
       );
       );
     },
     },
-    checkType(){
-      this.$refs.form.validate()
+    checkType() {
+      this.$refs.form.validate();
     },
     },
     submitForm() {
     submitForm() {
       this.$refs.form.validate(async (isok, obj) => {
       this.$refs.form.validate(async (isok, obj) => {
         if (isok) {
         if (isok) {
           // 学校缴费没有预览
           // 学校缴费没有预览
           if (this.$route.query.payUserType == "SCHOOL") {
           if (this.$route.query.payUserType == "SCHOOL") {
-            this.$confirm("是否创建缴费?", "提示", {
+            this.$confirm(this.$route.query.calenderId?"是否修改缴费":"是否创建缴费?", "提示", {
               confirmButtonText: "确定",
               confirmButtonText: "确定",
               cancelButtonText: "取消",
               cancelButtonText: "取消",
               type: "warning",
               type: "warning",
@@ -1044,7 +1044,7 @@ export default {
         let dom = this.$refs[i];
         let dom = this.$refs[i];
         // 这里是针对遍历的情况(多个输入框),取值为数组
         // 这里是针对遍历的情况(多个输入框),取值为数组
         if (Object.prototype.toString.call(dom) !== "[object Object]") {
         if (Object.prototype.toString.call(dom) !== "[object Object]") {
-          if(dom){
+          if (dom) {
             dom = dom[0];
             dom = dom[0];
           }
           }
         }
         }
@@ -1206,14 +1206,12 @@ export default {
     },
     },
     setAllTotal(val) {
     setAllTotal(val) {
       this.form.calenderFeeJson.allTotal = val;
       this.form.calenderFeeJson.allTotal = val;
-      if(this.form.calenderFeeJson.discountTotal){
+      if (this.form.calenderFeeJson.discountTotal) {
         this.form.currentTotalAmount =
         this.form.currentTotalAmount =
-        this.form.calenderFeeJson.allTotal -
-        this.form.calenderFeeJson.discountTotal;
-      }else{
-        this.form.currentTotalAmount =
-        this.form.calenderFeeJson.allTotal
-
+          this.form.calenderFeeJson.allTotal -
+          this.form.calenderFeeJson.discountTotal;
+      } else {
+        this.form.currentTotalAmount = this.form.calenderFeeJson.allTotal;
       }
       }
 
 
       this.$set(this.form, "currentTotalAmount", this.form.currentTotalAmount);
       this.$set(this.form, "currentTotalAmount", this.form.currentTotalAmount);
@@ -1246,9 +1244,9 @@ export default {
       }
       }
     },
     },
     Eclass: {
     Eclass: {
-      handler(newValue,oldValue) {
-        let oldString = JSON.stringify({...oldValue})
-        let newString = JSON.stringify({...newValue})
+      handler(newValue, oldValue) {
+        let oldString = JSON.stringify({ ...oldValue });
+        let newString = JSON.stringify({ ...newValue });
         if (this.initDetail || oldString == newString) {
         if (this.initDetail || oldString == newString) {
           this.initDetail = false;
           this.initDetail = false;
           return;
           return;
@@ -1268,6 +1266,22 @@ export default {
       },
       },
       deep: true,
       deep: true,
     },
     },
+    "form.calenderFeeType"(val, oldValue) {
+      if (val == "TEACHER" && !oldValue) {
+        let arr = [];
+        this.form.eclass.forEach((item) => {
+          arr.push({
+            courseType: item.courseType,
+            teacherNumber: 0,
+            courseNumber: 0,
+            courseCurrentPrice: 0,
+          });
+        });
+
+        this.$set(this.form, "teacherFeeList", arr);
+      }
+    },
+
     "form.currentTotalAmount"(val) {
     "form.currentTotalAmount"(val) {
       // console.log(val,'form.currentTotalAmount');
       // console.log(val,'form.currentTotalAmount');
       // this.$forceUpdate()
       // this.$forceUpdate()
@@ -1285,7 +1299,7 @@ export default {
               ...course,
               ...course,
             };
             };
           });
           });
-          console.log('获取musicGroupOrganizationCourseSettingId重置eclass')
+          console.log("获取musicGroupOrganizationCourseSettingId重置eclass");
           this.$set(this.form, "eclass", res.data);
           this.$set(this.form, "eclass", res.data);
           // this.syncAllMoney();
           // this.syncAllMoney();
         } catch (error) {}
         } catch (error) {}
@@ -1319,9 +1333,9 @@ export default {
     musicGroup() {
     musicGroup() {
       return this.baseInfo?.musicGroup;
       return this.baseInfo?.musicGroup;
     },
     },
-    Eclass(){
+    Eclass() {
       return JSON.parse(JSON.stringify(this.form.eclass));
       return JSON.parse(JSON.stringify(this.form.eclass));
-    }
+    },
   },
   },
 };
 };
 </script>
 </script>