Browse Source

10/26 乐团基本信息 以及声部改造

11
mo 4 năm trước cách đây
mục cha
commit
bfafe54558

+ 9 - 0
src/api/buildTeam.js

@@ -1339,4 +1339,13 @@ export function getCourseScheduleDetail (data) {
     method: 'get',
     params: data
   })
+}
+
+// 获取商品和商品折扣
+export function getSubjectGoods (data) {
+  return request({
+    url: api + '/musicGroupSubjectPlan/getSubjectGoods',
+    method: 'get',
+    params: data
+  })
 }

+ 9 - 7
src/views/teamBuild/components/teamBaseInfo.vue

@@ -236,6 +236,7 @@
                       prop="head">
           <el-select v-model.trim="topFrom.head"
                      filterable
+                     :disabled="basdisabled"
                      clearable>
             <el-option v-for="(item, index) in orgianList"
                        :key="index"
@@ -647,8 +648,9 @@ export default {
   },
   beforeDestroy () { },
   methods: {
+    //|| this.teamStatus === 'teamAudit' 
     isNotEditing: function () {
-      return !(this.teamStatus === 'teamDraft' || this.teamStatus === 'teamAudit' || this.teamStatus === 'newTeam' || this.teamStatus === 'teamList')
+      return !(this.teamStatus === 'teamDraft' || this.teamStatus === 'newTeam' || this.teamStatus === 'teamList')
     },
     changeFeeType (val) {
       // console.log(val == "ONLINE");
@@ -739,12 +741,12 @@ export default {
       // 分为3种  this.teamStatus
       //          1.resetTeam 乐团修改
       //          2. newTeam  新建乐团
-      //          3.teamList 跨团修改
+      //          3.teamList  跨团修改
       //          4.teamDraft 乐团草稿
       this.teamStatus = this.$route.query.type;
       // 传过来的乐团信息
       this.activeTeam = this.getTeamList;
-      if (this.teamStatus == "look") {
+      if (this.teamStatus == "look" || this.teamStatus == "teamAudit") {
         this.basdisabled = true;
       } else {
         this.basdisabled = false;
@@ -986,10 +988,10 @@ export default {
       check.forEach((item) => {
         checkFlag = checkFlag || item;
       });
-      if (!checkFlag) {
-        this.$message.error("请至少选择一种乐团课程类型");
-        return;
-      }
+      // if (!checkFlag) {
+      //   this.$message.error("请至少选择一种乐团课程类型");
+      //   return;
+      // }
       this.$refs["topinfo"].validate((valid, object) => {
         if (!valid) {
           this.$message.error("请填写建团必要参数");

+ 0 - 1
src/views/teamBuild/components/teamResetSound.vue

@@ -252,7 +252,6 @@ export default {
 
                 }
               }
-              console.log('删除');
               this.activeSoundList.splice(i, 1);
               // 遍历循环所有的group 删除所选id
               for (let key in this.soundLists) {

+ 19 - 21
src/views/teamBuild/components/teamSoundMoney.vue

@@ -28,6 +28,7 @@
                         @mousewheel.native.prevent
                         type="number"
                         style="width:80px"
+                        :disabled='teamStatus == "teamAudit"'
                         size="mini"
                         v-model.trim="scope.row.jihua"
                         placeholder="请输入"></el-input>
@@ -63,6 +64,7 @@
                           v-model.trim="scope.row.typeVisible"
                           v-if="scope.row.type == 1">
                 <el-button type="text"
+                           v-if='teamStatus != "teamAudit"'
                            slot="reference">修改</el-button>
                 <!-- zhonglei -->
                 <el-select v-model.trim="scope.row.zhonglei"
@@ -98,6 +100,7 @@
               >选择</div>-->
               <div v-if="scope.row.fangshi.length >0">{{scope.row.fangshi | fangshiFilter(scope.row)}}</div>
               <i class="el-icon-edit"
+                 v-if='teamStatus != "teamAudit"'
                  @click="setGiveMode(scope.row)"></i>
             </div>
           </template>
@@ -161,6 +164,7 @@
                       :key="index">{{item.name?item.name+':':''}}{{item.goods|goodsFilter(scope.row.markChioseList)}}{{' 价格 '+item.price }}</span>
               </span>
               <i class="el-icon-edit"
+                 v-if='teamStatus != "teamAudit"'
                  slot="reference"
                  @click="chioseMark(scope.row)"></i>
             </div>
@@ -665,7 +669,7 @@
             <div class="item">提供方式</div>
             <div class="item">提供方式对应金额</div>
             <div class="item">乐器费用减免</div>
-            <div class="item">乐团课程费用减免</div>
+
           </div>
 
           <div class="lineWrap">
@@ -681,22 +685,23 @@
                         v-model.trim="item.mode.price"
                         disabled></el-input>
             </div>
+            <!--  :disabled="item.id==-1" -->
             <div class="item">
               <el-input style="width:80%"
                         type="number"
                         @mousewheel.native.prevent
                         v-model.trim="item.mode.GROUP"
-                        :disabled="item.id==-1"
+                        :disabled="true"
                         @input="groupInput(item)"></el-input>
             </div>
-            <div class="item">
+            <!-- <div class="item">
               <el-input style="width:80%"
                         type="number"
                         @mousewheel.native.prevent
                         v-model.trim="item.mode.courseGroup"
                         :disabled="item.id==-1"
                         @input="groupCourseInput(item)"></el-input>
-            </div>
+            </div> -->
           </div>
 
           <div class="lineWrap">
@@ -723,11 +728,7 @@
                         @input="deposiInput(item)"
                         v-model.trim="item.mode.LEASE"></el-input>
             </div>
-            <div class="item">
-              <el-input style="width:80%"
-                        disabled
-                        type="number"></el-input>
-            </div>
+
           </div>
 
           <div class="lineWrap">
@@ -746,11 +747,7 @@
                         @mousewheel.native.prevent
                         disabled></el-input>
             </div>
-            <div class="item">
-              <el-input style="width:80%"
-                        disabled
-                        type="number"></el-input>
-            </div>
+
           </div>
         </div>
       </div>
@@ -775,7 +772,8 @@ import {
   findMusicGroupSubjectInfo,
   updateSubjectInfo,
   auditSuccess,
-  auditFailed
+  auditFailed,
+  getSubjectGoods
 } from "@/api/buildTeam";
 import dayjs from 'dayjs'
 export default {
@@ -828,11 +826,13 @@ export default {
     this.init();
   },
   mounted () {
-
+    console.log('mounted')
   },
   activated () {
     // 判断是否带缓存参
+    console.log('activated')
     this.init();
+
   },
   methods: {
     onCourseChange (item) {
@@ -849,6 +849,7 @@ export default {
       if (this.$route.query.rules) {
         this.Frules = this.$route.query.rules;
       }
+      // 获取
       getSoundTree({ tenantId: 1 }).then(res => {
         if (res.code == 200) {
           this.soundList = res.data.rows;
@@ -1134,8 +1135,6 @@ export default {
       // console.log(e)
     },
     changeSoundList (e, sound, arr) {
-
-      console.log(e, arr, this.activeSoundList)
       if (e) {
         this.checkinlist({ 'id': sound.id, 'sound': sound.name, 'jihua': 0, 'yuji': 0, 'zhonglei': [], 'fangshi': [], 'fangshiprice': 1500, 'jiaopu': '', 'type': 1, 'typeVisible': false, 'provideVisible': false, 'markVisible': false, 'goodsList': [], 'markList': [], 'markChioseList': [] })
       } else {
@@ -1222,7 +1221,7 @@ export default {
 
       let id = row.id;
       // 'subjectId': id, ' type'='INSTRUMENT'
-      getGoods({ subjectId: id, type: "INSTRUMENT" }).then(res => {
+      getSubjectGoods({ subjectId: id, type: "INSTRUMENT", chargeTypeId: this.topfor.type }).then(res => {
         if (res.code == 200) {
           row.goodsList = res.data;
         }
@@ -1682,7 +1681,7 @@ export default {
                 mode: {
                   yuji: tyuji,
                   FREE: 0,
-                  GROUP: 0,
+                  GROUP: row.goodsList[i].musicGroupDiscountPrice,
                   LEASE: 0,
                   courseFree: 0,
                   courseLease: null,
@@ -1783,7 +1782,6 @@ export default {
       })
       let groupList = []
       let leaseList = []
-      console.log(row)
       row.fangshi.forEach(item => {
         if (item.id == -1) {
           flag = false;