wolyshaw 4 年之前
父節點
當前提交
75f3f1c27e

文件差異過大導致無法顯示
+ 0 - 0
dist/index.html


文件差異過大導致無法顯示
+ 0 - 0
dist/static/css/chunk-559911d8.4bb7560f.css


文件差異過大導致無法顯示
+ 0 - 0
dist/static/js/app.6e4227c7.js


文件差異過大導致無法顯示
+ 0 - 0
dist/static/js/chunk-559911d8.e739f9b9.js


文件差異過大導致無法顯示
+ 0 - 0
dist/static/js/chunk-70df9dd1.1c8a5b6d.js


+ 20 - 14
src/views/teamBuild/modals/change-voice.vue

@@ -261,22 +261,28 @@ export default {
         .then(setRes)
       }
     },
-    subjectChange(id) {
+    async subjectChange(id) {
       this.$set(this.form, 'musicalGoods', '')
-      getSubjectGoodsAndInfo({
-        musicGroupId: this.musicGroupId,
-        subjectId: id,
-      })
-      .then(res => {
-        this.musicGroupSubjectPlanFee = res.data.musicGroupSubjectPlan.fee
-        const items = formatAllGoods(res.data, this.item.kitGroupPurchaseType)
-        for (const key in items) {
-          if (items.hasOwnProperty(key)) {
-            const item = items[key]
-            this[key] = item
-          }
+      let data = null
+      if (id) {
+        await getSubjectGoodsAndInfo({
+          musicGroupId: this.musicGroupId,
+          subjectId: id,
+        })
+        .then(res => {
+          data = res.data
+          this.musicGroupSubjectPlanFee = res.data.musicGroupSubjectPlan.fee
+        })
+      } else {
+        this.musicGroupSubjectPlanFee = 0
+      }
+      const items = formatAllGoods(data, this.item.kitGroupPurchaseType)
+      for (const key in items) {
+        if (items.hasOwnProperty(key)) {
+          const item = items[key]
+          this[key] = item
         }
-      })
+      }
     },
     musicalGoodsChange(val) {
       const item = this.musicalGoodsById[val]

部分文件因文件數量過多而無法顯示