Browse Source

修改问题

lex-xin 3 years ago
parent
commit
1cf9eacc04

+ 30 - 0
src/constant/index.js

@@ -16,4 +16,34 @@ export const courseType = {
   MUSIC: '乐团课',
   HIGH_ONLINE: '线上基础技能课',
   MUSIC_NETWORK: '乐团网管课'
+}
+
+export const musicGroupType = {
+  DRAFT: '编辑中',
+  AUDIT: '审核中',
+  PRE_APPLY:'预报名中',
+  PRE_BUILD_FEE:'创建缴费中',
+  FEE_AUDIT:'费用审核中',
+  APPLY: "报名中",
+  PAY: "缴费中",
+  PREPARE: "筹备中",
+  PROGRESS: "进行中",
+  CANCELED: '取消',
+  PAUSE: '暂停',
+  AUDIT_FAILED: '审核失败',
+  CLOSE:'关闭'
+}
+
+export const coupontypeDetail = {
+  OTHER:'其他',
+  MUSICAL:'乐器',
+  ACCESSORIES:'辅件',
+  MAINTENANCE:'乐保服务',
+  TEACHING:'教材',
+  PRACTICE:'网管课',
+  SINGLE:'声部课',
+  MIX:'合奏课',
+  VIP:'VIP',
+  FULLCOUPON:'全类券',
+  MEMBER:'团练宝'
 }

+ 1 - 0
src/utils/validate.js

@@ -1,3 +1,4 @@
+
 // 身份证号验证
 export function checkIDCard(idCardNo) {
     let result = true

+ 2 - 1
src/views/afterClassEvaluate/detail.vue

@@ -73,6 +73,7 @@
 import { getCourseInfoHead, getReviewInfo, studyStandardList, checkeIsAssignHomework, courseReviewAdd, getCurrentCourseDetail } from './api'
 import Item from "./modal/item";
 import MEmpty from '@/components/MEmpty';
+import dayjs from 'dayjs'
 export default {
   name: "afterClassEvaluateDetail",
   components: { Item, MEmpty },
@@ -210,7 +211,7 @@ export default {
           id: this.courseId,
           isNewJoin: 1, // 新的入口
           memberNum: this.memberStatus,
-          classGroupName: this.classGroupName,
+          classGroupName: this.dataInfo.courseName,
           ...this.$route.query
         },
       });

+ 0 - 3
src/views/afterClassEvaluate/index.vue

@@ -92,9 +92,6 @@ export default {
         }
         params.page = result.pageInfo.pageNo;
         const rows = result.pageInfo.rows
-        rows.forEach(item => {
-          item.classEndTime = dayjs(item.classEndTime).format('HH:mm:ss')
-        })
         this.list = this.list.concat(rows);
         if (params.page >= result.pageInfo.totalPage) {
           this.finished = true;

+ 92 - 17
src/views/afterClassEvaluate/modal/item.vue

@@ -3,26 +3,28 @@
     <van-cell title-class="timer" class="comment">
       <template #title>
         <van-icon :name="icon_timer" size="16" style="padding-right: .06rem;margin-top: 0.02rem;" />
-        {{dataInfo.classStartTime}}-{{ dataInfo.classEndTime }}
+        {{dataInfo.classStartTime | dayFormat('YYYY-MM-DD HH:mm')}}-{{ dataInfo.classEndTime | dayFormat('HH:mm') }}
       </template>
       <template #default>
-        <span v-show="isComment" style="color: #01C1B5; font-size: .15rem">
+        <!-- <span v-show="isComment" style="color: #01C1B5; font-size: .15rem">
           {{ dataInfo.courseScheduleReviewId ?  '已评价' : '待评价' }}
-        </span>
+        </span> -->
       </template>
     </van-cell>
     <van-cell label-class="address">
       <template #title>
         <div class="course-info">
-          <div class="course-img">
-            <!-- courseType -->
+          <span class="teachMode">{{ dataInfo.teachMode == 'ONLINE' ? '线上' : null }}{{ dataInfo.teachMode == 'OFFLINE' ? '线下' : null }}</span>
+          <span :class="['courseType', dataInfo.courseType]">{{ dataInfo.courseType | coursesType }}</span>
+          <span style="line-height: .18rem;vertical-align: bottom;color: #1A1A1A;font-size: .16rem;font-weight: 500;">{{ dataInfo.courseName }}</span>
+          <!-- <div class="course-img">
             <img v-if="dataInfo.courseType === 'VIP'" src="../images/icon_vip.png" alt="">
             <img v-if="dataInfo.courseType === 'PRACTICE'" src="../images/icon_p.png" alt="">
             <img v-if="dataInfo.courseType !== 'VIP' && dataInfo.courseType !== 'PRACTICE'" src="../images/icon_music.png" alt="">
           </div>
           <div class="course-name">
             {{ dataInfo.courseName }}<span class="teachMode" v-show="dataInfo.teachMode">{{ dataInfo.teachMode === 'ONLINE' ? '线上' : '线下' }}</span>
-          </div>
+          </div> -->
         </div>
       </template>
       <template #label>
@@ -102,18 +104,18 @@ export default {
   }
 
   .course-info {
-    display: flex;
-    align-items: center;
+    // display: flex;
+    // align-items: center;
     padding: 2px 0 16px;
     .course-img {
-      width: .48rem;
-      height: .4rem;
-      margin-right: .08rem;
-      img {
-        border-radius: 50%;
-        width: .4rem;
-        height: .4rem;
-      }
+      // width: .48rem;
+      // height: .4rem;
+      // margin-right: .08rem;
+      // img {
+      //   border-radius: 50%;
+      //   width: .4rem;
+      //   height: .4rem;
+      // }
     }
     .course-name {
       color: #1A1A1A;
@@ -132,7 +134,7 @@ export default {
     // height: 16px;
     line-height: 16px;
     padding: 0 5px;
-    margin-left: .05rem;
+    // margin-left: .05rem;
   }
 
   .comment {
@@ -141,4 +143,77 @@ export default {
     }
   }
 }
+
+@mColor: #01C1B5;
+@color1: #FF8642;
+@color2: #8C98E5;
+@color3: #6FB2FF;
+@color4: #7DC0CF;
+@color5: #cfcaca;
+@color6: #FF9288;
+@color7: #AA92CF;
+@color8: #2CD3E3;
+@color9: #0684E8;
+@color10: #97C672;
+@color11: #72C67A;
+@color12: #51CF83;
+@color13: #FFA25F;
+@color14: #85BEBE;
+@color15: #7584E8;
+
+.courseType {
+    line-height: 18px;
+    // height: 18px;
+    font-size: 12px;
+    color: #fff;
+    display: inline-block;
+    border-radius: 0px 5px 0px 5px;
+    padding: 0 3px;
+    margin: 0 .05rem;
+}
+.NORMAL, .SINGLE {
+    background: @color4;
+}
+.MIX {
+    background: @color6;
+}
+.HIGH {
+    background: @color7;
+}
+.VIP {
+    background: @color1;
+}
+.DEMO {
+    background: @color3;
+}
+.COMPREHENSIVE {
+    background: @color8;
+}
+.ENLIGHTENMENT {
+    background: @color9;
+}
+.TRAINING {
+    background: @color10;
+}
+.TRAINING_SINGLE {
+    background: @color11;
+}
+.TRAINING_MIX {
+    background: @color12;
+}
+.CLASSROOM {
+    background: @color13;
+}
+.PRACTICE, .MUSIC_NETWORK {
+    background: @color2;
+}
+.COMM {
+    background: @color14;
+}
+.MUSIC {
+    background: @mColor;
+}
+.HIGH_ONLINE {
+    background: @color15;
+}
 </style>

+ 2 - 2
src/views/audition/ArrangeWork.vue

@@ -219,8 +219,8 @@ export default {
       });
       this.dataList = tempData
       // 默认选中第1条数据
-      this.tabActive = deepClone(params.subjectIdList[0])
-      this.tabOriginActive = deepClone(params.subjectIdList[0])
+      this.tabActive = (params.subjectIdList[0])
+      this.tabOriginActive = (params.subjectIdList[0])
       this.dataSubjectList = deepClone(params.subjectList)
       this.params = params
     })

+ 40 - 18
src/views/visitManager/visitDetail.vue

@@ -53,7 +53,7 @@
 
 <script>
 import Item from "../afterClassEvaluate/modal/item.vue";
-import { getReviewInfo } from '../afterClassEvaluate/api';
+import { getReviewInfo, getCurrentCourseDetail } from '../afterClassEvaluate/api';
 export default {
   name: "visitDetail",
   components: { Item },
@@ -73,25 +73,47 @@ export default {
     }
   },
   async mounted() {
-    let params = {}
-    if(this.isReview) {
-      const res = await getReviewInfo({ id: this.userInfo.reviewId });
-      const result = res.data
-      console.log(result, 'result')
-      let info = result.teacherClassHeadInfo;
-      params = {
-        classStartTime: info.classDate + ' ' + info.startClassTime + ':00',
-        classEndTime: info.endClassTime + ':00',
-        courseType: info.courseScheduleType,
-        courseName: info.classGroupName,
-        teachMode: info.teachMode,
-        schoolName: null,
-        courseScheduleId: result.courseScheduleReview.courseScheduleId
+    try {
+      const detail = await getCurrentCourseDetail({ courseID: this.userInfo.objectId });
+      const resultDetail = detail.data
+      let tempMemo = resultDetail.coursePlan
+      this.dataInfo = {
+        classStartTime: resultDetail.startClassTime,
+        classEndTime: resultDetail.endClassTime,
+        courseType: resultDetail.courseType,
+        courseName: resultDetail.courseScheduleName,
+        teachMode: resultDetail.teachMode,
+        schoolName: resultDetail.address,
+        courseScheduleId: resultDetail.courseScheduleId
       }
-      this.memo = result.courseScheduleReview.memo || '该课程未设置教学内容'
+      if(this.isReview) {
+        const res = await getReviewInfo({ id: this.userInfo.reviewId });
+        const result = res.data
+        tempMemo = result.courseScheduleReview.memo || '该课程未设置教学内容'
+      }
+      this.memo = tempMemo
+    } catch {
+      //
     }
-    this.dataInfo = params
-    console.log(this.dataInfo)
+    // let params = {}
+    // if(this.isReview) {
+    //   const res = await getReviewInfo({ id: this.userInfo.reviewId });
+    //   const result = res.data
+    //   console.log(result, 'result')
+    //   let info = result.teacherClassHeadInfo;
+    //   params = {
+    //     classStartTime: info.classDate + ' ' + info.startClassTime + ':00',
+    //     classEndTime: info.endClassTime + ':00',
+    //     courseType: info.courseScheduleType,
+    //     courseName: info.classGroupName,
+    //     teachMode: info.teachMode,
+    //     schoolName: null,
+    //     courseScheduleId: result.courseScheduleReview.courseScheduleId
+    //   }
+    //   this.memo = result.courseScheduleReview.memo || '该课程未设置教学内容'
+    // }
+    // this.dataInfo = params
+    // console.log(this.dataInfo)
   },
   methods: {
     submitReview() {

+ 3 - 3
src/views/visitManager/visitList.vue

@@ -53,11 +53,11 @@ export default {
         if (browser().android || browser().iPhone) {
             this.headerStatus = false;
         }
-        document.title = '训练统计'
+        document.title = '回访记录'
     },
     methods: {
-      tabChange() {
-        
+      tabChange(val) {
+        sessionStorage.setItem('visited', val)
       }
     },
 };