ソースを参照

12/30 老师管理 vip课程

mo 4 年 前
コミット
ea4147fe55

+ 2 - 0
src/router/notKeepAliveList.js

@@ -75,4 +75,6 @@ export default [
   '/business/signupList', // 报名缴费
   '/business/teamDetails', //进行中 查看
   '/business/teamLookBase', // 筹备中 乐团信息
+  '/business/vipReset', // vip修改
+  '/business/vipDetail', // vip查看
 ]

+ 18 - 4
src/views/accompanyManager/accompanyBuys.vue

@@ -3,13 +3,14 @@
   <div class="m-core">
     <save-form :inline="true"
              class="searchForm"
+             save-key='accompanyBuys'
              @submit="search"
              @reset="onReSet"
-             :save-key="saveKey"
              :model.sync="searchForm">
       <!-- 状态 指导老师 活动方案-->
       <el-form-item>
         <el-input v-model.trim="searchForm.search"
+        clearable
                   placeholder="学员编号 学员名称"></el-input>
       </el-form-item>
       <el-form-item>
@@ -57,13 +58,26 @@
                 :data="tableData">
         <el-table-column align="center"
                          prop="studentId"
-                         label="学员编号"></el-table-column>
+                         label="学员编号">
+                           <template slot-scope="scope">
+              <copy-text>{{ scope.row.studentId }}</copy-text>
+            </template>
+                         </el-table-column>
         <el-table-column align="center"
                          prop="studentName"
-                         label="学员名称"></el-table-column>
+                         label="学员名称">
+                                        <template slot-scope="scope">
+              <copy-text>{{ scope.row.studentName }}</copy-text>
+            </template>
+                         </el-table-column>
         <el-table-column align="center"
                          prop="organName"
-                         label="所属分部"></el-table-column>
+                         label="所属分部">
+
+                                        <template slot-scope="scope">
+              <copy-text>{{ scope.row.organName }}</copy-text>
+            </template>
+                         </el-table-column>
         <!-- educationalTeacherId -->
         <el-table-column align="center"
                          prop="phone"

+ 297 - 238
src/views/accompanyManager/accompanyList.vue

@@ -4,141 +4,182 @@
       <div class="squrt"></div>网管课列表
     </h2>-->
     <div class="topWrap">
-      <div class="newBand"
-           v-permission="'export/practiceGroup'"
-           @click="onStudentExport"
-           style="width: 120px;">网管课续费提醒</div>
-      <div class="newBand"
-           v-permission="'export/practiceGroupList'"
-           @click="onPracticeExport"
-           style="width: 120px;">网管课导出</div>
+      <div
+        class="newBand"
+        v-permission="'export/practiceGroup'"
+        @click="onStudentExport"
+        style="width: 120px"
+      >
+        网管课续费提醒
+      </div>
+      <div
+        class="newBand"
+        v-permission="'export/practiceGroupList'"
+        @click="onPracticeExport"
+        style="width: 120px"
+      >
+        网管课导出
+      </div>
     </div>
     <div class="m-core">
-      <save-form :inline="true"
-               class="searchForm"
-               @submit="search"
-               @reset="onReSet"
-               :model.sync="searchForm">
+      <save-form
+        :inline="true"
+        class="searchForm"
+        save-key="accompanyList"
+        @submit="search"
+        @reset="onReSet"
+        :model.sync="searchForm"
+      >
         <!-- 状态 指导老师 活动方案-->
         <el-form-item>
-          <el-input v-model.trim="searchForm.search"
-                    clearable
-                    placeholder="课程组名称"></el-input>
+          <el-input
+            v-model.trim="searchForm.search"
+            clearable
+            placeholder="课程组名称"
+          ></el-input>
         </el-form-item>
         <el-form-item>
-          <el-select class="multiple"
-                     v-model.trim="searchForm.organIdList"
-                     filterable
-                     clearable
-                     placeholder="请选择分部">
-            <el-option v-for="(item,index) in selects.branchs"
-                       :key="index"
-                       :label="item.name"
-                       :value="item.id"></el-option>
+          <el-select
+            class="multiple"
+            v-model.trim="searchForm.organIdList"
+            filterable
+            clearable
+            placeholder="请选择分部"
+          >
+            <el-option
+              v-for="(item, index) in selects.branchs"
+              :key="index"
+              :label="item.name"
+              :value="item.id"
+            ></el-option>
           </el-select>
         </el-form-item>
         <el-form-item>
-          <el-select v-model.trim="searchForm.practiceGroupType"
-                     clearable
-                     filterable
-                     placeholder="课程组类型">
-            <el-option v-for="(item,index) in practiceGroupType"
-                       :key="index"
-                       :value="item.value"
-                       :label="item.label"></el-option>
+          <el-select
+            v-model.trim="searchForm.practiceGroupType"
+            clearable
+            filterable
+            placeholder="课程组类型"
+          >
+            <el-option
+              v-for="(item, index) in practiceGroupType"
+              :key="index"
+              :value="item.value"
+              :label="item.label"
+            ></el-option>
           </el-select>
         </el-form-item>
         <el-form-item prop="status">
-          <el-select class="multiple"
-                     v-model.trim="searchForm.hasEducationalTeacherId"
-                     filterable
-                     clearable
-                     placeholder="是否有乐团主管">
-            <el-option label="是"
-                       value="true"></el-option>
-            <el-option label="否"
-                       value="false"></el-option>
+          <el-select
+            class="multiple"
+            v-model.trim="searchForm.hasEducationalTeacherId"
+            filterable
+            clearable
+            placeholder="是否有乐团主管"
+          >
+            <el-option label="是" value="true"></el-option>
+            <el-option label="否" value="false"></el-option>
           </el-select>
         </el-form-item>
 
         <el-form-item>
-          <remote-search :commit='"setTeachers"' v-model='searchForm.teacherId' />
+          <remote-search
+            :commit="'setTeachers'"
+            v-model="searchForm.teacherId"
+          />
         </el-form-item>
         <el-form-item>
-          <el-select v-model.trim="searchForm.groupStatus"
-                     clearable
-                     filterable
-                     placeholder="课程组状态">
-            <el-option v-for="(item,index) in commGroupStatus"
-                       :key="index"
-                       :value="item.value"
-                       :label="item.label"></el-option>
+          <el-select
+            v-model.trim="searchForm.groupStatus"
+            clearable
+            filterable
+            placeholder="课程组状态"
+          >
+            <el-option
+              v-for="(item, index) in commGroupStatus"
+              :key="index"
+              :value="item.value"
+              :label="item.label"
+            ></el-option>
           </el-select>
         </el-form-item>
         <el-form-item>
-          <el-select v-model.trim="searchForm.firstOrRenew"
-                     clearable
-                     filterable
-                     placeholder="是否续费">
-            <el-option label="首充"
-                       value="1"></el-option>
-            <el-option label="续费"
-                       value="0"></el-option>
-            <el-option label="免费"
-                       value="2"></el-option>
+          <el-select
+            v-model.trim="searchForm.firstOrRenew"
+            clearable
+            filterable
+            placeholder="是否续费"
+          >
+            <el-option label="首充" value="1"></el-option>
+            <el-option label="续费" value="0"></el-option>
+            <el-option label="免费" value="2"></el-option>
           </el-select>
         </el-form-item>
         <el-form-item>
-          <el-button native-type="submit"
-                     type="danger">搜索</el-button>
-          <el-button native-type="reset"
-                     type="primary">重置</el-button>
+          <el-button native-type="submit" type="danger">搜索</el-button>
+          <el-button native-type="reset" type="primary">重置</el-button>
         </el-form-item>
       </save-form>
       <!-- tab -->
       <div class="tableWrap">
-        <el-table style="width: 100%"
-                  :header-cell-style="{background:'#EDEEF0',color:'#444'}"
-                  :data="tableData">
-          <el-table-column align="center"
-                           prop="id"
-                           label="课程组编号"
-                           width="100">
-                            <template slot-scope="scope">
-                              <copy-text>{{scope.row.id}}</copy-text>
-                            </template>
-                           </el-table-column>
-          <el-table-column align="center"
-                           prop="name"
-                           label="课程组名称"
-                           width="100">
-                           <template slot-scope="scope">
-                              <copy-text>{{scope.row.name}}</copy-text>
-                            </template>
-                          </el-table-column>
-          <el-table-column align="center"
-                           prop="type"
-                           label="课程组类型"
-                           width="100">
+        <el-table
+          style="width: 100%"
+          :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
+          :data="tableData"
+        >
+          <el-table-column
+            align="center"
+            prop="id"
+            label="课程组编号"
+            width="100"
+          >
+            <template slot-scope="scope">
+              <copy-text>{{ scope.row.id }}</copy-text>
+            </template>
+          </el-table-column>
+          <el-table-column
+            align="center"
+            prop="name"
+            label="课程组名称"
+            width="100"
+          >
+            <template slot-scope="scope">
+              <copy-text>{{ scope.row.name }}</copy-text>
+            </template>
+          </el-table-column>
+          <el-table-column
+            align="center"
+            prop="type"
+            label="课程组类型"
+            width="100"
+          >
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.type | comType}}</p>
+                <p>{{ scope.row.type | comType }}</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="organName"
-                           label="所属分部"></el-table-column>
+          <el-table-column align="center" prop="organName" label="所属分部">
+            <template slot-scope="scope">
+              <copy-text>{{ scope.row.organName }}</copy-text>
+            </template>
+          </el-table-column>
           <!-- educationalTeacherId -->
-          <el-table-column align="center"
-                           prop="educationalTeacherName"
-                           label="乐团主管"></el-table-column>
-          <el-table-column align="center"
-                           prop="teacherName"
-                           label="指导老师"></el-table-column>
-          <el-table-column align="center"
-                           prop="studentNum"
-                           label="班级人数"></el-table-column>
+          <el-table-column
+            align="center"
+            prop="educationalTeacherName"
+            label="乐团主管"
+          ></el-table-column>
+          <el-table-column align="center" prop="teacherName" label="指导老师">
+            <template slot-scope="scope">
+              <copy-text>{{ scope.row.teacherName }}</copy-text>
+            </template>
+          </el-table-column>
+          <el-table-column
+            align="center"
+            prop="studentNum"
+            label="班级人数"
+          ></el-table-column>
           <!-- <el-table-column align="center" label="课程单价">
             <template slot-scope="scope">
               <div>
@@ -147,132 +188,151 @@
               </div>
             </template>
           </el-table-column>-->
-          <el-table-column align="center"
-                           label="当前课次">
+          <el-table-column align="center" label="当前课次">
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.currentClassTimes + '/' + scope.row.totalClassTimes}}</p>
+                <p>
+                  {{
+                    scope.row.currentClassTimes +
+                    "/" +
+                    scope.row.totalClassTimes
+                  }}
+                </p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="coursesStartDate"
-                           label="开课时间"
-                           width="120">
+          <el-table-column
+            align="center"
+            prop="coursesStartDate"
+            label="开课时间"
+            width="120"
+          >
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.coursesStartDate | formatTimer}}</p>
+                <p>{{ scope.row.coursesStartDate | formatTimer }}</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="coursesExpireDate"
-                           label="结束时间"
-                           width="120">
+          <el-table-column
+            align="center"
+            prop="coursesExpireDate"
+            label="结束时间"
+            width="120"
+          >
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.coursesExpireDate | formatTimer}}</p>
+                <p>{{ scope.row.coursesExpireDate | formatTimer }}</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="groupStatus"
-                           label="课程组状态"
-                           width="100">
+          <el-table-column
+            align="center"
+            prop="groupStatus"
+            label="课程组状态"
+            width="100"
+          >
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.groupStatus | comCourseGroup}}</p>
+                <p>{{ scope.row.groupStatus | comCourseGroup }}</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           label="是否续费"
-                           fixed="right">
+          <el-table-column align="center" label="是否续费" fixed="right">
             <template slot-scope="scope">
               <div>
                 <p v-if="scope.row.buyMonths == 0">免费</p>
-                <p v-if="scope.row.buyMonths > 0">{{scope.row.beRenewGroupId>0?'续费':'首充'}}</p>
+                <p v-if="scope.row.buyMonths > 0">
+                  {{ scope.row.beRenewGroupId > 0 ? "续费" : "首充" }}
+                </p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column width="150"
-                           prop="memo"
-                           label="备注"
-                           fixed="right">
-                            <template slot-scope="scope">
-                              <overflow-text :text="scope.row.memo" width="150px"></overflow-text>
-                            </template>
-                           </el-table-column>
+          <el-table-column width="150" prop="memo" label="备注" fixed="right">
+            <template slot-scope="scope">
+              <overflow-text
+                :text="scope.row.memo"
+                width="150px"
+              ></overflow-text>
+            </template>
+          </el-table-column>
 
-          <el-table-column align="center"
-                           width="200"
-                           fixed="right"
-                           label="操作">
+          <el-table-column
+            align="center"
+            width="200"
+            fixed="right"
+            label="操作"
+          >
             <template slot-scope="scope">
               <div>
                 <!-- v-permission="'courseSchedule/classStartDateAdjust'"  v-if="!scope.row.isSettlement" -->
-                <el-button type="text"
-                           @click="lookCrouse(scope.row)">查看</el-button>
-                <el-button type="text"
-                           v-if="scope.row.groupStatus == 'NORMAL' && permission('practiceGroupManage/cancelGroup')"
-                           @click="closeCrouse(scope.row)">关闭</el-button>
-                <el-button type="text"
-                           v-if="permission('practiceGroupManage/updateMemo')"
-                           @click="resetMemo(scope.row)">修改备注</el-button>
+                <el-button type="text" @click="lookCrouse(scope.row)"
+                  >查看</el-button
+                >
+                <el-button
+                  type="text"
+                  v-if="
+                    scope.row.groupStatus == 'NORMAL' &&
+                    permission('practiceGroupManage/cancelGroup')
+                  "
+                  @click="closeCrouse(scope.row)"
+                  >关闭</el-button
+                >
+                <el-button
+                  type="text"
+                  v-if="permission('practiceGroupManage/updateMemo')"
+                  @click="resetMemo(scope.row)"
+                  >修改备注</el-button
+                >
               </div>
             </template>
           </el-table-column>
         </el-table>
-        <pagination sync :total.sync="rules.total"
-                    :page.sync="rules.page"
-                    :limit.sync="rules.limit"
-                    :page-sizes="rules.page_size"
-                    @pagination="getList" />
+        <pagination
+          sync
+          :total.sync="rules.total"
+          :page.sync="rules.page"
+          :limit.sync="rules.limit"
+          :page-sizes="rules.page_size"
+          @pagination="getList"
+        />
       </div>
     </div>
-    <el-dialog title="关闭课程组"
-               width="400px"
-               :visible.sync="closeVisible">
-      <el-form :model="closeForm"
-               ref="closeForm"
-               label-position="right"
-               label-width="80px;"
-               :inline="true">
-        <el-form-item label="是否退费"
-                      prop="isBasck">
-          <el-radio v-model="closeForm.isBack"
-                    :label="true">是</el-radio>
-          <el-radio v-model="closeForm.isBack"
-                    :label="false">否</el-radio>
+    <el-dialog title="关闭课程组" width="400px" :visible.sync="closeVisible">
+      <el-form
+        :model="closeForm"
+        ref="closeForm"
+        label-position="right"
+        label-width="80px;"
+        :inline="true"
+      >
+        <el-form-item label="是否退费" prop="isBasck">
+          <el-radio v-model="closeForm.isBack" :label="true">是</el-radio>
+          <el-radio v-model="closeForm.isBack" :label="false">否</el-radio>
         </el-form-item>
-        <el-form-item label="退费金额"
-                      v-if="closeForm.isBack"
-                      prop="money">
-          <el-input type="number"
-                    @mousewheel.native.prevent
-                    v-model.trim="closeForm.money"></el-input>
+        <el-form-item label="退费金额" v-if="closeForm.isBack" prop="money">
+          <el-input
+            type="number"
+            @mousewheel.native.prevent
+            v-model.trim="closeForm.money"
+          ></el-input>
         </el-form-item>
       </el-form>
-      <div slot="footer"
-           class="dialog-footer">
+      <div slot="footer" class="dialog-footer">
         <el-button @click="closeVisible = false">取 消</el-button>
-        <el-button type="primary"
-                   @click="submieCloseCrouse">确 定</el-button>
+        <el-button type="primary" @click="submieCloseCrouse">确 定</el-button>
       </div>
     </el-dialog>
-    <el-dialog title="备注"
-               width="400px"
-               :visible.sync="memoVisible">
-      <el-input type="textarea"
-                v-model.trim="memoForm.memo"
-                :rows="7"
-                :maxlength="255"
-                show-word-limit></el-input>
-      <div slot="footer"
-           class="dialog-footer">
+    <el-dialog title="备注" width="400px" :visible.sync="memoVisible">
+      <el-input
+        type="textarea"
+        v-model.trim="memoForm.memo"
+        :rows="7"
+        :maxlength="255"
+        show-word-limit
+      ></el-input>
+      <div slot="footer" class="dialog-footer">
         <el-button @click="memoVisible = false">取 消</el-button>
-        <el-button type="primary"
-                   @click="subMemo">确 定</el-button>
+        <el-button type="primary" @click="subMemo">确 定</el-button>
       </div>
     </el-dialog>
   </div>
@@ -280,20 +340,20 @@
 <script>
 import pagination from "@/components/Pagination/index";
 import { permission } from "@/utils/directivePage";
-import cleanDeep from 'clean-deep'
+import cleanDeep from "clean-deep";
 import { commGroupStatus, practiceGroupType } from "@/utils/searchArray";
 import {
   getEmployeeOrgan,
   practiceGroupManage,
   cancelGroup,
-  practiceUpdateMemo
+  practiceUpdateMemo,
 } from "@/api/buildTeam";
 import axios from "axios";
 import { getToken } from "@/utils/auth";
 import load from "@/utils/loading";
 export default {
   components: { pagination },
-  data () {
+  data() {
     return {
       searchForm: {
         search: null,
@@ -302,15 +362,15 @@ export default {
         organIdList: null,
         firstOrRenew: null,
         practiceGroupType: null,
-        groupStatus: null
+        groupStatus: null,
       },
       closeForm: {
         isBack: false,
-        money: null
+        money: null,
       },
       memoForm: {
         memo: "",
-        groupId: ""
+        groupId: "",
       },
       memoVisible: false,
       closeVisible: false,
@@ -326,11 +386,11 @@ export default {
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50] // 选择限制显示条数
-      }
+        page_size: [10, 20, 40, 50], // 选择限制显示条数
+      },
     };
   },
-  mounted () {
+  mounted() {
     if (this.$route.query.searchForm) {
       this.$route.query.searchForm instanceof Object
         ? (this.searchForm = this.$route.query.searchForm)
@@ -343,24 +403,23 @@ export default {
     }
     this.init();
   },
-  activated () {
+  activated() {
     this.init();
   },
   methods: {
-
-    init () {
-      this.$store.dispatch('setBranchs')
+    init() {
+      this.$store.dispatch("setBranchs");
 
       this.getList();
     },
-    permission (str, parent) {
+    permission(str, parent) {
       return permission(str, parent);
     },
-    search () {
+    search() {
       this.rules.page = 1;
       this.getList();
     },
-    onReSet () {
+    onReSet() {
       this.searchForm = {
         search: null,
         status: null,
@@ -368,11 +427,11 @@ export default {
         organIdList: null,
         firstOrRenew: null,
         practiceGroupType: null,
-        groupStatus: null
+        groupStatus: null,
       };
       this.search();
     },
-    onStudentExport () {
+    onStudentExport() {
       // 导出VIP课
       // let searchForm = this.searchForm;
       let data = {
@@ -386,29 +445,29 @@ export default {
       const options = {
         method: "get",
         headers: {
-          Authorization: getToken()
+          Authorization: getToken(),
         },
         params: data,
         url,
-        responseType: "blob"
+        responseType: "blob",
       };
       this.$confirm("网管课续费提醒导出?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning"
+        type: "warning",
       })
         .then(() => {
           load.startLoading();
           axios(options)
-            .then(res => {
+            .then((res) => {
               let blob = new Blob([res.data], {
                 // type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=utf-8'
-                type: "application/vnd.ms-excel;charset=utf-8"
+                type: "application/vnd.ms-excel;charset=utf-8",
                 //word文档为application/msword,pdf文档为application/pdf,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=utf-8
               });
 
               let text = new Response(blob).text();
-              text.then(res => {
+              text.then((res) => {
                 // 判断是否报错
                 if (res.indexOf("code") != -1) {
                   let json = JSON.parse(res);
@@ -425,14 +484,14 @@ export default {
               });
               load.endLoading();
             })
-            .catch(error => {
+            .catch((error) => {
               this.$message.error("导出数据失败,请联系管理员");
               load.endLoading();
             });
         })
-        .catch(() => { });
+        .catch(() => {});
     },
-    onPracticeExport () {
+    onPracticeExport() {
       // 导出VIP课
       let searchForm = this.searchForm;
       let obj = {
@@ -442,35 +501,35 @@ export default {
         hasEducationalTeacherId: searchForm.hasEducationalTeacherId || null,
         type: searchForm.firstOrRenew || null,
         practiceGroupType: searchForm.practiceGroupType || null,
-        groupStatus: searchForm.groupStatus || null
+        groupStatus: searchForm.groupStatus || null,
       };
       let url = "/api-web/export/practiceGroupList";
       const options = {
         method: "get",
         headers: {
-          Authorization: getToken()
+          Authorization: getToken(),
         },
         params: cleanDeep(obj),
         url,
-        responseType: "blob"
+        responseType: "blob",
       };
       this.$confirm("网管课导出?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning"
+        type: "warning",
       })
         .then(() => {
           load.startLoading();
           axios(options)
-            .then(res => {
+            .then((res) => {
               let blob = new Blob([res.data], {
                 // type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=utf-8'
-                type: "application/vnd.ms-excel;charset=utf-8"
+                type: "application/vnd.ms-excel;charset=utf-8",
                 //word文档为application/msword,pdf文档为application/pdf,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=utf-8
               });
 
               let text = new Response(blob).text();
-              text.then(res => {
+              text.then((res) => {
                 // 判断是否报错
                 if (res.indexOf("code") != -1) {
                   let json = JSON.parse(res);
@@ -487,14 +546,14 @@ export default {
               });
               load.endLoading();
             })
-            .catch(error => {
+            .catch((error) => {
               this.$message.error("导出数据失败,请联系管理员");
               load.endLoading();
             });
         })
-        .catch(() => { });
+        .catch(() => {});
     },
-    getList () {
+    getList() {
       let obj = {
         search: this.searchForm.search || null,
         teacherId: this.searchForm.teacherId || null,
@@ -505,31 +564,31 @@ export default {
           this.searchForm.hasEducationalTeacherId || null,
         type: this.searchForm.firstOrRenew || null,
         practiceGroupType: this.searchForm.practiceGroupType || null,
-        groupStatus: this.searchForm.groupStatus || null
+        groupStatus: this.searchForm.groupStatus || null,
       };
-      practiceGroupManage(obj).then(res => {
+      practiceGroupManage(obj).then((res) => {
         if (res.code == 200) {
           this.tableData = res.data.rows;
           this.rules.total = res.data.total;
         }
       });
     },
-    lookCrouse (row) {
+    lookCrouse(row) {
       let rules = JSON.stringify(this.rules);
       let searchForm = JSON.stringify(this.searchForm);
       this.$router.push({
         path: "/business/accompanys",
-        query: { id: row.id, type: row.type }
+        query: { id: row.id, type: row.type },
       });
     },
-    closeCrouse (row) {
+    closeCrouse(row) {
       this.activeRow = row;
       this.closeVisible = true;
     },
-    courseVisibleClose () {
+    courseVisibleClose() {
       // 关闭弹窗前
     },
-    submieCloseCrouse () {
+    submieCloseCrouse() {
       // 提交关闭课程组
       if (this.closeForm.isBack) {
         if (!this.closeForm.money) {
@@ -543,8 +602,8 @@ export default {
       cancelGroup({
         groupId: this.activeRow.id,
         groupType: "PRACTICE",
-        refundAmount: this.closeForm.money
-      }).then(res => {
+        refundAmount: this.closeForm.money,
+      }).then((res) => {
         if (res.code == 200) {
           this.$message.success("关闭成功");
           this.getList();
@@ -552,34 +611,34 @@ export default {
         }
       });
     },
-    resetMemo (row) {
+    resetMemo(row) {
       this.$set(this.memoForm, "memo", row.memo);
       this.$set(this.memoForm, "groupId", row.id);
       this.memoVisible = true;
     },
-    subMemo () {
-      practiceUpdateMemo(this.memoForm).then(res => {
+    subMemo() {
+      practiceUpdateMemo(this.memoForm).then((res) => {
         if (res.code == 200) {
           this.$message.success("修改成功");
           this.memoVisible = false;
           this.getList();
         }
       });
-    }
+    },
   },
   watch: {
-    closeVisible (val) {
+    closeVisible(val) {
       if (!val) {
         this.activeRow = null;
         (this.closeForm = {
           isBack: false,
-          money: null
+          money: null,
         }),
           this.$refs.closeForm.resetFields();
         this.closeVisible = false;
       }
-    }
-  }
+    },
+  },
 };
 </script>
 <style lang='scss' scoped>

+ 21 - 25
src/views/accompanyManager/index.vue

@@ -2,50 +2,46 @@
 <template>
   <div class="m-container">
     <h2>
-      <div class="squrt"></div>网管课管理
+      <div class="squrt"></div>
+      网管课管理
     </h2>
     <div class="m-core">
-      <el-tabs v-model.trim="activeIndex"
-               type="card"
-               @tab-click="handleClick">
-        <el-tab-pane label="网管课管理"
-                     name="1">
-          <accompanyList v-if="activeIndex ==='1'" />
+      <tab-router
+        v-model.trim="activeIndex"
+        type="card"
+        @tab-click="handleClick"
+      >
+        <el-tab-pane label="网管课管理" lazy name="1">
+          <accompanyList v-if="activeIndex === '1'" />
         </el-tab-pane>
-        <el-tab-pane label="网管课购买"
-                     name="2">
-          <accompanyBuys v-if="activeIndex ==='2'" />
+        <el-tab-pane label="网管课购买" lazy name="2">
+          <accompanyBuys v-if="activeIndex === '2'" />
         </el-tab-pane>
-      </el-tabs>
+      </tab-router>
     </div>
   </div>
 </template>
 
 <script>
 import accompanyList from "@/views/accompanyManager/accompanyList";
-import accompanyBuys from '@/views/accompanyManager/accompanyBuys'
+import accompanyBuys from "@/views/accompanyManager/accompanyBuys";
 export default {
   components: { accompanyList, accompanyBuys },
-  data () {
-    const { query } = this.$route
+  data() {
     return {
-      activeIndex: query.opt || '1',
+      activeIndex: "1",
     };
   },
   //生命周期 - 创建完成(可以访问当前this实例)
-  created () {
-
-  },
+  created() {},
   //生命周期 - 挂载完成(可以访问DOM元素)
-  mounted () {
-
-  },
+  mounted() {},
   methods: {
-    handleClick (evt) {
-      this.changeHash(evt.name)
-    }
+    handleClick(evt) {
+      // this.changeHash(evt.name);
+    },
   },
-}
+};
 </script>
 <style lang='scss' scoped>
 </style>

+ 131 - 131
src/views/teacherManager/teacherDetail/components/courseInfo.vue

@@ -1,116 +1,114 @@
 <template>
-  <div class='courseInfo'>
-    <el-form :model="searchList"
-             :inline='true'>
+  <div class="courseInfo">
+    <save-form :model="searchList" :inline="true" @submit="search" save-key='teacherDetail-courseInfo'>
       <el-form-item label="乐团状态">
-        <el-select v-model.trim="searchList.status"
-                   clearable>
-          <el-option v-for="(item,index) in musicGroupStatus"
-                     :key="item.value"
-                     :label="item.text"
-                     :value="item.value">
+        <el-select v-model.trim="searchList.status" clearable>
+          <el-option
+            v-for="item in musicGroupStatus"
+            :key="item.value"
+            :label="item.text"
+            :value="item.value"
+          >
           </el-option>
         </el-select>
       </el-form-item>
       <el-form-item>
-        <el-button type="danger"
-                   @click='search'>搜索</el-button>
+        <el-button type="danger" native-type="submit">搜索</el-button>
       </el-form-item>
       <el-form-item>
-        <div class="newBand"
-             @click="resetCourses"
-             v-permission="'courseSchedule/classGroupTeacherAdjust'">课程移交</div>
+        <div
+          class="newBand"
+          @click="resetCourses"
+          v-permission="'courseSchedule/classGroupTeacherAdjust'"
+        >
+          课程移交
+        </div>
       </el-form-item>
-    </el-form>
+    </save-form>
     <div class="tableWrap">
-      <el-table :data='tableList'
-                @selection-change="handleSelectionChange"
-                :header-cell-style="{background:'#EDEEF0',color:'#444'}">
-        <el-table-column type="selection"
-                         :selectable='selectable'
-                         width="55">
+      <el-table
+        :data="tableList"
+        @selection-change="handleSelectionChange"
+        :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
+      >
+        <el-table-column type="selection" :selectable="selectable" width="55">
         </el-table-column>
-        <el-table-column label="乐团编号"
-                         align="center"
-                         prop="musicGroupId">
+        <el-table-column label="乐团编号" align="center" prop="musicGroupId">
         </el-table-column>
-        <el-table-column label="乐团名称"
-                         align="center"
-                         prop="musicGroupName">
+        <el-table-column label="乐团名称" align="center" prop="musicGroupName">
         </el-table-column>
-        <el-table-column label="老师类型"
-                         align="center"
-                         prop="jobType">
+        <el-table-column label="老师类型" align="center" prop="jobType">
           <template slot-scope="scope">
             {{ scope.row.jobNature | jobNature }}
           </template>
         </el-table-column>
-        <el-table-column label="乐团职位"
-                         align="center">
+        <el-table-column label="乐团职位" align="center">
           <template slot-scope="scope">
             {{ scope.row.teacherRole | workType }}
           </template>
         </el-table-column>
-        <el-table-column label="执教班级"
-                         align="center">
+        <el-table-column label="执教班级" align="center">
           <template slot-scope="scope">
             {{ scope.row.classGroupNames | joinArray }}
           </template>
         </el-table-column>
-        <el-table-column label="乐团状态"
-                         align="center">
+        <el-table-column label="乐团状态" align="center">
           <template slot-scope="scope">
             {{ scope.row.status | musicGroupType }}
           </template>
         </el-table-column>
-        <el-table-column label="出勤次数"
-                         align="center"
-                         prop="attendanceNum">
+        <el-table-column label="出勤次数" align="center" prop="attendanceNum">
         </el-table-column>
-        <el-table-column label="是否可调整"
-                         align="center">
+        <el-table-column label="是否可调整" align="center">
           <template slot-scope="scope">
             <!-- 1.没有剩余课时,2.乐团筹备中 -->
             <div>
-              <p v-if="scope.row.status == 'PROGRESS'"> {{ scope.row.hasRestClass>0?'是':'否' }}</p>
+              <p v-if="scope.row.status == 'PROGRESS'">
+                {{ scope.row.hasRestClass > 0 ? "是" : "否" }}
+              </p>
               <p v-else>否</p>
             </div>
-
           </template>
         </el-table-column>
-        <el-table-column label="操作"
-                         align="center">
+        <el-table-column label="操作" align="center">
           <template slot-scope="scope">
             <div>
-              <el-button type="text"
-                         v-if="scope.row.hasRestClass>0&&scope.row.status == 'PROGRESS'"
-                         v-permission="'courseSchedule/classGroupTeacherAdjust'"
-                         @click="resetCourse(scope.row)">操作</el-button>
+              <el-button
+                type="text"
+                v-if="
+                  scope.row.hasRestClass > 0 && scope.row.status == 'PROGRESS'
+                "
+                v-permission="'courseSchedule/classGroupTeacherAdjust'"
+                @click="resetCourse(scope.row)"
+                >操作</el-button
+              >
             </div>
           </template>
         </el-table-column>
       </el-table>
-      <pagination :total="pageInfo.total"
-                  :page.sync="pageInfo.page"
-                  :limit.sync="pageInfo.limit"
-                  :page-sizes="pageInfo.page_size"
-                  @pagination="getList" />
+      <pagination
+      sync
+        :total.sync="pageInfo.total"
+        :page.sync="pageInfo.page"
+        :limit.sync="pageInfo.limit"
+        :page-sizes="pageInfo.page_size"
+        @pagination="getList"
+      />
     </div>
-    <el-dialog title='课程移交'
-               :visible.sync="maskVisible"
-               width="400px">
-      <el-form :model="maskForm"
-               ref="maskForm">
-        <el-form-item label="选择老师"
-                      prop="targetTeacherId"
-                      :rules="[{ required: true, message: '请选择老师',trigger: 'blur'}]">
-          <el-select v-model="maskForm.targetTeacherId"
-                     clearable
-                     filterable>
-            <el-option v-for="(item,index) in teacherList"
-                       :label="item.realName"
-                       :value="item.id"
-                       :key="index"></el-option>
+    <el-dialog title="课程移交" :visible.sync="maskVisible" width="400px">
+      <el-form :model="maskForm" ref="maskForm">
+        <el-form-item
+          label="选择老师"
+          prop="targetTeacherId"
+          :rules="[{ required: true, message: '请选择老师', trigger: 'blur' }]"
+        >
+          <el-select v-model="maskForm.targetTeacherId" clearable filterable>
+            <el-option
+              v-for="(item, index) in teacherList"
+              :label="item.realName"
+              :value="item.id"
+              :key="index"
+            ></el-option>
           </el-select>
         </el-form-item>
         <!-- <el-form-item label="备注"
@@ -121,33 +119,34 @@
                     v-model="maskForm.memo"></el-input>
         </el-form-item> -->
       </el-form>
-      <div slot="footer"
-           class="dialog-footer">
+      <div slot="footer" class="dialog-footer">
         <el-button @click="maskVisible = false">取 消</el-button>
-        <el-button type="primary"
-                   @click="submitReset">确定</el-button>
+        <el-button type="primary" @click="submitReset">确定</el-button>
       </div>
     </el-dialog>
   </div>
 </template>
 <script>
-import { getTeacherMusicClass, classGroupTeacherAdjust } from '@/api/teacherManager'
+import {
+  getTeacherMusicClass,
+  classGroupTeacherAdjust,
+} from "@/api/teacherManager";
 import { getTeacher } from "@/api/buildTeam";
-import { musicGroupStatus } from '@/utils/searchArray'
-import pagination from '@/components/Pagination/index'
-import store from '@/store'
+import { musicGroupStatus } from "@/utils/searchArray";
+import pagination from "@/components/Pagination/index";
+import store from "@/store";
 export default {
-  name: 'courseInfo',
+  name: "courseInfo",
   components: {
-    pagination
+    pagination,
   },
-  data () {
+  data() {
     return {
       tableList: [],
       teacherId: this.$route.query.teacherId,
       organId: null,
       searchList: {
-        status: ''
+        status: "",
       },
       musicGroupStatus,
       teacherList: [],
@@ -156,108 +155,109 @@ export default {
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 1, // 总条数
-        page_size: [10, 20, 40, 50] // 选择限制显示条数
+        page_size: [10, 20, 40, 50], // 选择限制显示条数
       },
       activeRow: null,
       maskVisible: false,
       maskForm: {
         targetTeacherId: null,
-        memo: null
+        memo: null,
       },
       isMultiple: false,
-      chioseList: []
-    }
+      chioseList: [],
+    };
   },
-  activated () {
-    this.teacherId = this.$route.query.teacherId
-    this.getList()
-    this.musicGroupStatus = musicGroupStatus
+  activated() {
+    this.teacherId = this.$route.query.teacherId;
+    this.getList();
+    this.musicGroupStatus = musicGroupStatus;
   },
-  mounted () {
-    this.teacherId = this.$route.query.teacherId
-    this.getList()
+  mounted() {
+    this.teacherId = this.$route.query.teacherId;
+    this.getList();
     this.musicGroupStatus = musicGroupStatus;
     // 获取指导老师
-    getTeacher({}).then(res => {
+    getTeacher({}).then((res) => {
       if (res.code == 200) {
         this.teacherList = res.data;
       }
     });
   },
   methods: {
-    selectable (row, index) {
-      return row.hasRestClass > 0 && row.status == 'PROGRESS'
+    selectable(row, index) {
+      return row.hasRestClass > 0 && row.status == "PROGRESS";
     },
-    handleSelectionChange (val) {
-      this.chioseList = val
+    handleSelectionChange(val) {
+      this.chioseList = val;
     },
-    search () {
+    search() {
       this.pageInfo.page = 1;
       this.getList();
     },
-    getList () {
+    getList() {
       getTeacherMusicClass({
         rows: this.pageInfo.limit,
         page: this.pageInfo.page,
         search: this.teacherId,
-        status: this.searchList.status || null
-      }).then(res => {
+        status: this.searchList.status || null,
+      }).then((res) => {
         if (res.code == 200) {
-          this.tableList = res.data.rows
-          this.pageInfo.total = res.data.total
+          this.tableList = res.data.rows;
+          this.pageInfo.total = res.data.total;
         }
-      })
+      });
     },
-    resetCourse (row) {
+    resetCourse(row) {
       this.activeRow = row;
-      this.isMultiple = false
-      this.maskVisible = true
+      this.isMultiple = false;
+      this.maskVisible = true;
     },
-    resetCourses () {
+    resetCourses() {
       if (this.chioseList.length <= 0) {
-        this.$message.error('请至少选择一个乐团')
-        return
+        this.$message.error("请至少选择一个乐团");
+        return;
       }
-      this.isMultiple = true
-      this.maskVisible = true
+      this.isMultiple = true;
+      this.maskVisible = true;
     },
-    submitReset () {
-      this.$refs['maskForm'].validate(valid => {
+    submitReset() {
+      this.$refs["maskForm"].validate((valid) => {
         if (valid) {
           let obj = {};
           if (this.isMultiple) {
             // 批量调整
-            obj.classGroupIds = this.chioseList.map(res => {
-              return res.classGroupIds
-            }).join(',')
+            obj.classGroupIds = this.chioseList
+              .map((res) => {
+                return res.classGroupIds;
+              })
+              .join(",");
           } else {
             // 单词调整
-            obj.classGroupIds = this.activeRow.classGroupIds
+            obj.classGroupIds = this.activeRow.classGroupIds;
           }
           obj.targetTeacherId = this.maskForm.targetTeacherId;
           obj.teacherId = this.teacherId;
           // obj.memo = this.maskForm.memo;
-          classGroupTeacherAdjust(obj).then(res => {
+          classGroupTeacherAdjust(obj).then((res) => {
             if (res.code == 200) {
               this.maskVisible = false;
-              this.$message.success('修改成功')
-              this.getList()
+              this.$message.success("修改成功");
+              this.getList();
             }
-          })
+          });
         }
-      })
-
-    }
+      });
+    },
   },
   watch: {
-    maskVisible (val) {
+    maskVisible(val) {
       if (!val) {
         this.maskForm.targetTeacherId = null;
-        this.maskForm.memo = null
+        this.maskForm.memo = null;
       }
-    }
-  }
-}
+    },
+  },
+};
 </script>
 <style lang="scss" scope>
 .courseInfo {
@@ -268,4 +268,4 @@ export default {
     margin-top: 20px;
   }
 }
-</style>
+</style>

+ 7 - 5
src/views/teacherManager/teacherDetail/components/courseInfo1.vue

@@ -1,9 +1,11 @@
 <template>
   <div class='courseInfo'>
-    <el-form :inline="true"
+    <save-form :inline="true"
+    @submit='search'
              :model="searchList">
       <el-form-item>
-        <el-input placeholder="vip编号或vip名称"
+        <el-input placeholder="vip编号、名称"
+        clearable
                   @keyup.enter.native='search'
                   v-model.trim="searchList.search"></el-input>
       </el-form-item>
@@ -18,9 +20,9 @@
       </el-form-item>
       <el-form-item>
         <el-button type="danger"
-                   @click="search">搜索</el-button>
+                   native-type="search">搜索</el-button>
       </el-form-item>
-    </el-form>
+    </save-form>
     <div class="tableWrap tableMargin">
       <el-table :data='teamList'
                 :header-cell-style="{background:'#EDEEF0',color:'#444'}">
@@ -167,4 +169,4 @@ export default {
     margin-top: 20px;
   }
 }
-</style>
+</style>

+ 14 - 2
src/views/teacherManager/teacherDetail/index.vue

@@ -6,70 +6,82 @@
     </h2>
     <div class="m-core">
       <!-- navMenu -->
-      <el-tabs v-model.trim="activeName"
+      <tab-router v-model.trim="activeName"
                type="card"
                @tab-click="handleClick">
         <el-tab-pane label="基本信息"
+        lazy
                      v-if="permissionList.teacherInfo"
                      name="0">
           <teacherInfo v-if="activeName == 0" />
         </el-tab-pane>
         <el-tab-pane label="乐团课"
+        lazy
                      v-if="permissionList.musicGroup"
                      name="1">
           <courseInfo v-if="activeName == 1" />
         </el-tab-pane>
         <el-tab-pane label="VIP课"
+        lazy
                      v-if="permissionList.VipCourse"
                      name="2">
           <courseInfo1 v-if="activeName == 2" />
         </el-tab-pane>
         <el-tab-pane label="网管课"
+        lazy
                      v-if="permissionList.teacherNetwork"
                      name="8">
           <teacherNetwork v-if="activeName == 8" />
         </el-tab-pane>
         <el-tab-pane label="对外课"
+        lazy
                      v-if="permissionList.outCourseList"
                      name="3">
           <outCourseList v-if="activeName == 3" />
         </el-tab-pane>
         <el-tab-pane label="课表详情"
+        lazy
                      v-if="permissionList.teacherRecord"
                      name="4">
           <teacherRecord v-if="activeName == 4" />
         </el-tab-pane>
         <el-tab-pane label="请假记录"
+        lazy
                      v-if="permissionList.leaveRecord"
                      name="5">
           <leaveRecord v-if="activeName == 5" />
         </el-tab-pane>
         <el-tab-pane label="上课结算列表"
+        lazy
                      v-if="permissionList.settlement"
                      name="6">
           <settlement v-if="activeName == 6" />
         </el-tab-pane>
         <el-tab-pane label="时间记录"
+        lazy
                      v-if="permissionList.timerList"
                      name="7">
           <timerList v-if="activeName == 7" />
         </el-tab-pane>
         <el-tab-pane label="学员"
+        lazy
                      v-if="permissionList.serveStudentList"
                      name="9">
           <serveStudentList v-if="activeName == 9" />
         </el-tab-pane>
         <el-tab-pane label="月历课表"
+        lazy
                      v-if="permissionList.calendarList"
                      name="10">
           <calendarList v-if="activeName == 10" />
         </el-tab-pane>
         <el-tab-pane label="周历课表"
+        lazy
                      v-if="permissionList.weeklyCalendar"
                      name="11">
           <weeklyCalendar v-if="activeName == 11" />
         </el-tab-pane>
-      </el-tabs>
+      </tab-router>
     </div>
   </div>
 </template>

+ 25 - 17
src/views/teamDetail/components/courseList.vue

@@ -1,10 +1,11 @@
 <template>
   <div class="cl-container">
     <!-- 搜索类型 -->
-    <el-form :inline="true"
+    <save-form :inline="true"
              class="searchForm"
-             v-model.trim="searchForm">
-      <el-form-item>
+             ref='searchForm'
+             :model="searchForm" @submit="search" @reset="onReSet">
+      <el-form-item prop="courseStatus">
         <el-select v-model.trim="searchForm.courseStatus"
                    clearable
                    filterable
@@ -15,7 +16,7 @@
                      :value="item.value"></el-option>
         </el-select>
       </el-form-item>
-      <el-form-item>
+      <el-form-item prop="classStatus">
         <el-select v-model.trim="searchForm.classStatus"
                    clearable
                    filterable
@@ -28,7 +29,7 @@
                      value="OVER"></el-option>
         </el-select>
       </el-form-item>
-      <el-form-item>
+      <el-form-item prop="class">
         <!-- getMusicGroupAllClass -->
         <el-select v-model.trim="searchForm.class"
                    placeholder="班级名称"
@@ -40,7 +41,7 @@
                      :label="item.name"></el-option>
         </el-select>
       </el-form-item>
-      <el-form-item>
+      <el-form-item prop="isSettlement">
         <el-select v-model.trim="searchForm.isSettlement"
                    placeholder="是否结算"
                    filterable
@@ -51,7 +52,7 @@
                      label="已结算"></el-option>
         </el-select>
       </el-form-item>
-      <el-form-item>
+      <el-form-item prop="timer">
         <el-date-picker v-model.trim="searchForm.timer"
                         style="width:420px;"
                         type="daterange"
@@ -64,10 +65,10 @@
     }"></el-date-picker>
       </el-form-item>
       <el-form-item>
-        <div class="searchBtn"
-             @click="search">搜索</div>
+        <el-button native-type="submit" type="danger">搜索</el-button>
+          <el-button type="primary" native-type="reset">重置</el-button>
       </el-form-item>
-    </el-form>
+    </save-form>
     <div class="btnWraps">
       <!-- <div class="newBand"
            @click="removeCourses"
@@ -176,7 +177,9 @@
           </template>
         </el-table-column>
       </el-table>
-      <pagination :total="rules.total"
+      <pagination
+      sync
+      :total.sync="rules.total"
                   :page.sync="rules.page"
                   :limit.sync="rules.limit"
                   :page-sizes="rules.page_size"
@@ -350,7 +353,9 @@
           </template>
         </el-table-column>
       </el-table>
-      <pagination :total="rollCall.total"
+      <pagination
+      sync
+      :total.sync="rollCall.total"
                   :page.sync="rollCall.page"
                   :limit.sync="rollCall.limit"
                   :page-sizes="rollCall.page_size"
@@ -507,11 +512,11 @@ export default {
       //     this.teacherList = res.data;
       //   }
       // })
-      getTeacher().then(res => {
-        if (res.code == 200) {
-          this.teacherList = res.data;
-        }
-      });
+      // getTeacher().then(res => {
+      //   if (res.code == 200) {
+      //     this.teacherList = res.data;
+      //   }
+      // });
 
       // 获取班级列表
       getMusicGroupAllClass({ musicGroupId: this.teamid }).then(res => {
@@ -846,6 +851,9 @@ export default {
         this.$nextTick(res => {
         this.maskForm.endTime = addTimerFormMinute(this.maskForm.date,this.maskForm.startTime ,val );
       })
+    },
+    onReSet(){
+      this.$refs.searchForm.resetFields()
     }
 
   },

ファイルの差分が大きいため隠しています
+ 450 - 569
src/views/teamDetail/components/studentList.vue


+ 85 - 72
src/views/teamDetail/components/teacherList.vue

@@ -1,14 +1,18 @@
 <template>
-  <div class='t-container'>
+  <div class="t-container">
     <!-- 头部展示 -->
     <!-- <div class="headWrap" style="padding:0;">
-      
+
     </div> -->
 
     <!-- 搜索类型 -->
-    <el-form :inline="true"
-             class="searchForm"
-             v-model.trim="searchForm">
+    <save-form
+      :inline="true"
+      save-key="teamDetails-teacherList"
+      class="searchForm"
+      :model="searchForm"
+      @submit="search"
+    >
       <!-- <el-form-item>
         <el-select v-model.trim="searchForm.status"
                    placeholder="合奏班">
@@ -19,42 +23,53 @@
         </el-select>
       </el-form-item> -->
       <el-form-item>
-        <el-input placeholder="老师姓名 编号 手机号"
-                  v-model.trim="searchForm.search"></el-input>
+        <el-input
+          placeholder="老师姓名 编号 手机号"
+          clearable
+          v-model.trim="searchForm.search"
+        ></el-input>
       </el-form-item>
       <el-form-item>
-        <div class="searchBtn"
-             @click="search">搜索</div>
+        <el-button native-type="submit" type="danger">搜索</el-button>
       </el-form-item>
-      <el-form-item style="float: right;">
-        <div class="right newBand"
-             style="margin-bottom: 0;"
-             @click="gotoRecord"> 上课记录 </div>
+      <el-form-item style="float: right">
+        <div class="right newBand" style="margin-bottom: 0" @click="gotoRecord">
+          上课记录
+        </div>
       </el-form-item>
-    </el-form>
+    </save-form>
 
     <!-- 列表 -->
     <div class="tableWrap">
-      <el-table :data='tableList'
-                :header-cell-style="{background:'#EDEEF0',color:'#444'}">
-        <el-table-column align='center'
-                         prop="teacherId"
-                         label="老师编号">
+      <el-table
+        :data="tableList"
+        :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
+      >
+        <el-table-column align="center" prop="teacherId" label="老师编号">
+          <template slot-scope="scope">
+            <copy-text>
+              {{ scope.row.teacherId }}
+            </copy-text>
+          </template>
         </el-table-column>
-        <el-table-column align='center'
-                         prop="teacherName"
-                         label="老师姓名">
+        <el-table-column align="center" prop="teacherName" label="老师姓名">
+          <template slot-scope="scope">
+            <copy-text>
+              {{ scope.row.teacherName }}
+            </copy-text>
+          </template>
         </el-table-column>
-        <el-table-column align='center'
-                         prop="teacherPhone"
-                         label="联系电话">
+        <el-table-column align="center" prop="teacherPhone" label="联系电话">
+          <template slot-scope="scope">
+            <copy-text>
+              {{ scope.row.teacherPhone }}
+            </copy-text>
+          </template>
         </el-table-column>
-        <el-table-column align='center'
-                         prop="jobNature"
-                         label="工作类型">
+        <el-table-column align="center" prop="jobNature" label="工作类型">
           <template slot-scope="scope">
             <div>
-              {{ scope.row.jobNature|jobNature}}
+              {{ scope.row.jobNature | jobNature }}
             </div>
           </template>
         </el-table-column>
@@ -62,13 +77,9 @@
                          prop="name"
                          label="合奏班">
         </el-table-column> -->
-        <el-table-column align='center'
-                         prop="classGroupName"
-                         label="执教班级">
+        <el-table-column align="center" prop="classGroupName" label="执教班级">
         </el-table-column>
-        <el-table-column align='center'
-                         prop="num"
-                         label="出勤次数">
+        <el-table-column align="center" prop="num" label="出勤次数">
         </el-table-column>
         <!-- <el-table-column align='center'
                          label="操作">
@@ -86,26 +97,30 @@
           </template>
         </el-table-column> -->
       </el-table>
-      <pagination :total="rules.total"
-                  :page.sync="rules.page"
-                  :limit.sync="rules.limit"
-                  :page-sizes="rules.page_size"
-                  @pagination="getList" />
+      <pagination
+      sync
+        :total.sync="rules.total"
+        :page.sync="rules.page"
+        :limit.sync="rules.limit"
+        :page-sizes="rules.page_size"
+        @pagination="getList"
+      />
     </div>
   </div>
 </template>
 <script>
-import pagination from '@/components/Pagination/index'
-import { getTeamTeacherList, getAllClass } from '@/api/buildTeam'
+import pagination from "@/components/Pagination/index";
+import { getTeamTeacherList, getAllClass } from "@/api/buildTeam";
 export default {
-  name: 'tteacherList',
-  data () {
+  name: "tteacherList",
+  data() {
     return {
-      searchForm: { // 搜索框
-        status: '', // 工作类型
-        teachingClass: '', // 合奏班
-        attendance: '', // 出勤次数
-        search: ''
+      searchForm: {
+        // 搜索框
+        status: "", // 工作类型
+        teachingClass: "", // 合奏班
+        attendance: "", // 出勤次数
+        search: "",
       },
       searchLsit: [],
       tableList: [], //
@@ -115,23 +130,23 @@ export default {
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 30, 40] // 选择限制显示条数
+        page_size: [10, 20, 30, 40], // 选择限制显示条数
       },
-    }
+    };
   },
   components: {
-    pagination
+    pagination,
   },
-  mounted () {
+  mounted() {
     this.teamid = this.$route.query.id;
     this.getList();
-    getAllClass({ musicGroupId: this.teamid }).then(res => {
+    getAllClass({ musicGroupId: this.teamid }).then((res) => {
       if (res.code == 200) {
         this.mixCourseList = res.data;
       }
-    })
+    });
   },
-  activated () {
+  activated() {
     this.teamid = this.$route.query.id;
     this.getList();
     // getAllClass({ musicGroupId: this.teamid }).then(res => {
@@ -141,40 +156,38 @@ export default {
     // })
   },
   methods: {
-    search () {
+    search() {
       this.rules.page = 1;
       this.getList();
     },
-    getList () {
+    getList() {
       // this.teamid
       // 'classGroupName': '',
       //  'jobNature': '',
       getTeamTeacherList({
-
-        'musicGroupId': this.teamid,
+        musicGroupId: this.teamid,
         page: this.rules.page,
         rows: this.rules.limit,
-        search: this.searchForm.search || null
-
-      }).then(res => {
+        search: this.searchForm.search || null,
+      }).then((res) => {
         if (res.code == 200) {
           this.tableList = res.data.rows;
           this.rules.total = res.data.total;
         }
-      })
+      });
     },
-    gotoRecord () {
+    gotoRecord() {
       this.$router.push({
         path: `/business/teamTeacherRecord`,
         query: {
           id: this.teamid,
           status: this.$route.query.status,
-          name: this.$route.query.name
-        }
-      })
-    }
-  }
-}
+          name: this.$route.query.name,
+        },
+      });
+    },
+  },
+};
 </script>
 <style lang="scss" scope>
 .t-container {
@@ -185,4 +198,4 @@ export default {
   // .searchForm {
   // }
 }
-</style>
+</style>

+ 8 - 45
src/views/vipClass/vipDetail/components/fnanceInfo.vue

@@ -27,49 +27,10 @@
         <span>{{ offlineClassesUnitPrice | moneyFormat }}</span>
       </statistic-item>
     </statistic>
-    <!-- <div class="headWrap">
-      <div class="left">
-        <div class="headItem">
-          <p>
-            课程总价:
-            <span>{{ totalPrice|moneyFormat }}</span>
-          </p>
-        </div>
-        <div class="headItem">
-          <p>
-            实收笔数:
-            <span>{{ feeDeductionNum }}</span>
-          </p>
-        </div>
-        <div class="headItem">
-          <p>
-            线上课课酬:
-            <span>{{ onlineClassesUnitPrice|moneyFormat }}</span>
-          </p>
-        </div>
-        <div class="headItem">
-          <p>
-            课酬总额:
-            <span>{{ totalSalary|moneyFormat }}</span>
-          </p>
-        </div>
-        <div class="headItem">
-          <p>
-            实收总额:
-            <span>{{ totalFeeDeduction|moneyFormat }}</span>
-          </p>
-        </div>
-        <div class="headItem">
-          <p>
-            线下课课酬:
-            <span>{{offlineClassesUnitPrice |moneyFormat}}</span>
-          </p>
-        </div>
-      </div>
-    </div> -->
     <!-- 搜索栏 -->
-    <el-form :inline="true"
-             :model="searchForm">
+    <save-form :inline="true"
+    save-key='vipDetail-fnanceInfo'
+             :model="searchForm" @submit='search'>
       <el-form-item label="时间范围">
         <el-date-picker v-model.trim="searchForm.time"
                         style="width:400px;"
@@ -83,10 +44,10 @@
     }"></el-date-picker>
       </el-form-item>
       <el-form-item>
-        <el-button @click="search"
+        <el-button native-type="submit"
                    type="danger">搜索</el-button>
       </el-form-item>
-    </el-form>
+    </save-form>
     <div class="tableWrap">
       <el-table :header-cell-style="{background:'#EDEEF0',color:'#444'}"
                 :data="tableList">
@@ -132,7 +93,9 @@
         </el-table-column>
       </el-table>
       <!-- 分页器 -->
-      <pagination :total="rules.total"
+      <pagination
+      sync
+      :total.sync="rules.total"
                   :page.sync="rules.page"
                   :limit.sync="rules.limit"
                   :page-sizes="rules.page_size"

+ 355 - 310
src/views/vipClass/vipDetail/components/teacherRecord.vue

@@ -19,163 +19,153 @@
         <span>{{ complaintsNum }}</span>
       </statistic-item>
     </statistic>
-    <!-- <div class="headWrap">
-      <div class="left">
-        <div class="headItem">
-          <p>未上课时:<span>{{ totalClassTimes }}</span></p>
-        </div>
-        <div class="headItem">
-          <p>已上课时:<span>{{ currentClassTimes }}</span></p>
-        </div>
-        <div class="headItem">
-          <p>已结算:<span>{{ isSalaryNum }}</span></p>
-        </div>
-        <div class="headItem">
-          <p>被投诉:<span>{{ complaintsNum }}</span></p>
-        </div>
-      </div>
-      <div class="right">
-      </div>
-    </div> -->
     <!-- 搜索标题 -->
-    <el-form :inline="true"
-             label-position="right"
-             label-width="120px"
-             class="searchForm"
-             v-model.trim="searchForm">
+    <save-form
+      save-key='vipDetail-record'
+      :inline="true"
+      label-position="right"
+      label-width="120px"
+      class="searchForm"
+      @submit="search"
+      :model="searchForm"
+    >
       <el-form-item>
-        <el-select v-model.trim="searchForm.type"
-                   clearable
-                   placeholder="课程类型">
-          <el-option label="线上课"
-                     value="ONLINE"></el-option>
-          <el-option label="线下课"
-                     value="OFFLINE"></el-option>
+        <el-select
+          v-model.trim="searchForm.type"
+          clearable
+          placeholder="课程类型"
+        >
+          <el-option label="线上课" value="ONLINE"></el-option>
+          <el-option label="线下课" value="OFFLINE"></el-option>
         </el-select>
       </el-form-item>
       <el-form-item>
-        <el-select v-model.trim="searchForm.status"
-                   clearable
-                   placeholder="课程状态">
-          <el-option label="未开始"
-                     value="NOT_START"></el-option>
-          <el-option label="进行中"
-                     value="UNDERWAY"></el-option>
-          <el-option label="已结束"
-                     value="OVER"></el-option>
+        <el-select
+          v-model.trim="searchForm.status"
+          clearable
+          placeholder="课程状态"
+        >
+          <el-option label="未开始" value="NOT_START"></el-option>
+          <el-option label="进行中" value="UNDERWAY"></el-option>
+          <el-option label="已结束" value="OVER"></el-option>
         </el-select>
       </el-form-item>
       <el-form-item>
-        <el-date-picker v-model.trim="searchForm.time"
-                        style="width:400px"
-                        type="daterange"
-                        value-format="yyyy-MM-dd"
-                        range-separator="至"
-                        start-placeholder="课程开始日期"
-                        end-placeholder="课程结束日期"
-                        :picker-options="{
-        firstDayOfWeek: 1
-    }">
+        <el-date-picker
+          v-model.trim="searchForm.time"
+          style="width: 400px"
+          type="daterange"
+          value-format="yyyy-MM-dd"
+          range-separator="至"
+          start-placeholder="课程开始日期"
+          end-placeholder="课程结束日期"
+          :picker-options="{
+            firstDayOfWeek: 1,
+          }"
+        >
         </el-date-picker>
       </el-form-item>
       <el-form-item>
-        <el-button @click="search"
-                   type="primary">搜索</el-button>
+        <el-button native-type="submit" type="primary">搜索</el-button>
       </el-form-item>
-    </el-form>
+    </save-form>
     <!-- 列表 -->
     <div class="tableWrap">
-      <el-table :data='tableList'>
-        <el-table-column align='center'
-                         label="课程编号"
-                         prop="id">
+      <el-table :data="tableList">
+        <el-table-column align="center" label="课程编号" prop="id">
         </el-table-column>
-        <el-table-column align='center'
-                         label="上课时间"
-                         width="250px"
-                         prop="startClassTime">
+        <el-table-column
+          align="center"
+          label="上课时间"
+          width="250px"
+          prop="startClassTime"
+        >
           <template slot-scope="scope">
             <!--  {{ scope.row.classDate }} {{ scope.row.startClassTime ? scope.row.startClassTime.substr(0, 5) : '' }}-{{ scope.row.endClassTime ? scope.row.endClassTime.substr(0, 5) : '' }} -->
             <div>
-              <p>{{ scope.row.startClassTime | dateForMinFormat }}-{{ scope.row.endClassTime | endTime  }}</p>
+              <p>
+                {{ scope.row.startClassTime | dateForMinFormat }}-{{
+                  scope.row.endClassTime | endTime
+                }}
+              </p>
             </div>
           </template>
         </el-table-column>
-        <el-table-column align='center'
-                         label="课程类型"
-                         prop="teachMode">
+        <el-table-column align="center" label="课程类型" prop="teachMode">
           <template slot-scope="scope">
             <div>
-              <p>{{scope.row.teachMode | fitterTeachMode  }}</p>
+              <p>{{ scope.row.teachMode | fitterTeachMode }}</p>
             </div>
           </template>
         </el-table-column>
-        <el-table-column align='center'
-                         label="教学点"
-                         prop='schoolName'>
+        <el-table-column align="center" label="教学点" prop="schoolName">
           <template slot-scope="scope">
             <div>
-              {{scope.row.schoolName?scope.row.schoolName:'网络教室'}}
+              {{ scope.row.schoolName ? scope.row.schoolName : "网络教室" }}
             </div>
           </template>
         </el-table-column>
-        <el-table-column align='center'
-                         label="上课学员数"
-                         prop="attendanceNum">
+        <el-table-column align="center" label="上课学员数" prop="attendanceNum">
         </el-table-column>
-        <el-table-column align='center'
-                         prop="status"
-                         label="签到状态">
+        <el-table-column align="center" prop="status" label="签到状态">
           <template slot-scope="scope">
             <div>
-              <p>{{scope.row.signInStatus | attendanceType  }}</p>
+              <p>{{ scope.row.signInStatus | attendanceType }}</p>
             </div>
           </template>
         </el-table-column>
-        <el-table-column align='center'
-                         prop="status"
-                         label="签退状态">
+        <el-table-column align="center" prop="status" label="签退状态">
           <template slot-scope="scope">
             <div>
-              <p>{{scope.row.signOutStatus | attendanceOutType  }}</p>
+              <p>{{ scope.row.signOutStatus | attendanceOutType }}</p>
             </div>
           </template>
         </el-table-column>
-        <el-table-column align='center'
-                         prop="status"
-                         label="课程状态">
+        <el-table-column align="center" prop="status" label="课程状态">
           <template slot-scope="scope">
             <div>
-              <p>{{scope.row.status | fitterStatus  }}</p>
+              <p>{{ scope.row.status | fitterStatus }}</p>
             </div>
           </template>
         </el-table-column>
-        <el-table-column align='center'
-                         prop="isSalary"
-                         label="结算状态">
+        <el-table-column align="center" prop="isSalary" label="结算状态">
           <template slot-scope="scope">
             <div>
-              <p>{{scope.row.isSalary | fitterisSalary  }}</p>
+              <p>{{ scope.row.isSalary | fitterisSalary }}</p>
             </div>
           </template>
         </el-table-column>
-        <el-table-column align='center'
-                         label="操作"
-                         width="200">
+        <el-table-column align="center" label="操作" width="200">
           <template slot-scope="scope">
             <div>
-              <el-button type="text"
-                         v-if="scope.row.attendanceNum"
-                         permission="'vipGroupManage/findVipGroupAttendanceStudents'"
-                         @click="lookStudents(scope.row)">查看学员</el-button>
+              <el-button
+                type="text"
+                v-if="scope.row.attendanceNum"
+                permission="'vipGroupManage/findVipGroupAttendanceStudents'"
+                @click="lookStudents(scope.row)"
+                >查看学员</el-button
+              >
 
               <!-- 未结算没有点击功能 -->
-              <el-button v-if="scope.row.status == 'OVER' && !scope.row.isSalary && permission('teacherAttendance/updateTeacherAttendance')"
-                         type="text"
-                         @click="onMarkAttendance(scope.row)">补考勤</el-button>
-              <el-button v-if="scope.row.status == 'OVER' && permission('studentAttendance/updateStudentAttendances')"
-                         type="text"
-                         @click="onCallName(scope.row)">点名表</el-button>
+              <el-button
+                v-if="
+                  scope.row.status == 'OVER' &&
+                  !scope.row.isSalary &&
+                  permission('teacherAttendance/updateTeacherAttendance')
+                "
+                type="text"
+                @click="onMarkAttendance(scope.row)"
+                >补考勤</el-button
+              >
+              <el-button
+                v-if="
+                  scope.row.status == 'OVER' &&
+                  permission('studentAttendance/updateStudentAttendances')
+                "
+                type="text"
+                @click="onCallName(scope.row)"
+                >点名表</el-button
+              >
               <!-- <el-button type="text" v-permission="'vipGroupManage/classStartDateAdjust'"
                          @click="resetClass(scope.row)">课程调整</el-button> -->
             </div>
@@ -183,22 +173,30 @@
         </el-table-column>
       </el-table>
     </div>
-    <pagination :total="rules.total"
-                :page.sync="rules.page"
-                :limit.sync="rules.limit"
-                :page-sizes="rules.page_size"
-                @pagination="getList" />
-    <el-dialog title="上课学员"
-               :visible.sync="studentVisible"
-               width="30%"
-               :before-close="handleClose">
-      <span v-for="(item,index) in studentList"
-            :key="index"
-            style="margin-left:10px;">{{item}}</span>
-      <span slot="footer"
-            class="dialog-footer">
-        <el-button type="primary"
-                   @click="studentVisible = false">确 定</el-button>
+    <pagination
+      sync
+      :total.sync="rules.total"
+      :page.sync="rules.page"
+      :limit.sync="rules.limit"
+      :page-sizes="rules.page_size"
+      @pagination="getList"
+    />
+    <el-dialog
+      title="上课学员"
+      :visible.sync="studentVisible"
+      width="30%"
+      :before-close="handleClose"
+    >
+      <span
+        v-for="(item, index) in studentList"
+        :key="index"
+        style="margin-left: 10px"
+        >{{ item }}</span
+      >
+      <span slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="studentVisible = false"
+          >确 定</el-button
+        >
       </span>
     </el-dialog>
     <!-- <el-dialog title="课程调整"
@@ -261,169 +259,211 @@
       </span>
     </el-dialog> -->
 
-    <el-dialog title='补考勤'
-               width="400px"
-               :visible.sync="markAttendance.status">
+    <el-dialog
+      title="补考勤"
+      width="400px"
+      :visible.sync="markAttendance.status"
+    >
       <el-form>
-        <el-form-item label="签到状态">{{ markAttendance.dataInfo.signInStatus | attendanceType }} </el-form-item>
-        <el-form-item label="签到时间">{{ markAttendance.dataInfo.signInTime}}</el-form-item>
-        <el-form-item label="签退状态">{{ markAttendance.dataInfo.signOutStatus | attendanceOutType }} </el-form-item>
-        <el-form-item label="签退时间">{{ markAttendance.dataInfo.signOutTime}}</el-form-item>
+        <el-form-item label="签到状态"
+          >{{ markAttendance.dataInfo.signInStatus | attendanceType }}
+        </el-form-item>
+        <el-form-item label="签到时间">{{
+          markAttendance.dataInfo.signInTime
+        }}</el-form-item>
+        <el-form-item label="签退状态"
+          >{{ markAttendance.dataInfo.signOutStatus | attendanceOutType }}
+        </el-form-item>
+        <el-form-item label="签退时间">{{
+          markAttendance.dataInfo.signOutTime
+        }}</el-form-item>
       </el-form>
-      <div slot="footer"
-           class="dialog-footer">
+      <div slot="footer" class="dialog-footer">
         <el-button @click="markAttendance.status = false">取 消</el-button>
-        <el-button type="primary"
-                   :disabled="markAttendance.dataInfo.signOutStatus == 1 && markAttendance.dataInfo.signInStatus == 1 ? true : false"
-                   @click="batchAdjustmentTime">确定补卡</el-button>
+        <el-button
+          type="primary"
+          :disabled="
+            markAttendance.dataInfo.signOutStatus == 1 &&
+            markAttendance.dataInfo.signInStatus == 1
+              ? true
+              : false
+          "
+          @click="batchAdjustmentTime"
+          >确定补卡</el-button
+        >
       </div>
     </el-dialog>
 
-    <el-dialog title='点名表'
-               width="800px"
-               :visible.sync="rollCall.status">
+    <el-dialog title="点名表" width="800px" :visible.sync="rollCall.status">
       <el-table :data="rollCall.gridData">
-        <el-table-column align='center'
-                         property="userName"
-                         label="学员姓名"></el-table-column>
-        <el-table-column align='center'
-                         property="phone"
-                         label="手机号"></el-table-column>
-        <el-table-column align='center'
-                         property="subjectName"
-                         label="学员声部"></el-table-column>
-        <el-table-column align='center'
-                         label="到课状态">
+        <el-table-column
+          align="center"
+          property="userName"
+          label="学员姓名"
+        ></el-table-column>
+        <el-table-column
+          align="center"
+          property="phone"
+          label="手机号"
+        ></el-table-column>
+        <el-table-column
+          align="center"
+          property="subjectName"
+          label="学员声部"
+        ></el-table-column>
+        <el-table-column align="center" label="到课状态">
           <template slot-scope="scope">
             {{ scope.row.status | studentCallName }}
           </template>
         </el-table-column>
-        <el-table-column align='center'
-                         v-if="!rollCall.selectItem.isSalary"
-                         label="操作"
-                         width="240px">
+        <el-table-column
+          align="center"
+          v-if="!rollCall.selectItem.isSalary"
+          label="操作"
+          width="240px"
+        >
           <template slot-scope="scope">
-            <el-button size="small"
-                       @click="onChangeRollCall('TRUANT', scope.row)"
-                       type="primary"
-                       round>未到</el-button>
-            <el-button size="small"
-                       @click="onChangeRollCall('LEAVE', scope.row)"
-                       type="warning"
-                       round>请假</el-button>
-            <el-button size="small"
-                       @click="onChangeRollCall('NORMAL', scope.row)"
-                       type="success"
-                       round>到课</el-button>
+            <el-button
+              size="small"
+              @click="onChangeRollCall('TRUANT', scope.row)"
+              type="primary"
+              round
+              >未到</el-button
+            >
+            <el-button
+              size="small"
+              @click="onChangeRollCall('LEAVE', scope.row)"
+              type="warning"
+              round
+              >请假</el-button
+            >
+            <el-button
+              size="small"
+              @click="onChangeRollCall('NORMAL', scope.row)"
+              type="success"
+              round
+              >到课</el-button
+            >
           </template>
         </el-table-column>
       </el-table>
-      <pagination :total="rollCall.total"
-                  :page.sync="rollCall.page"
-                  :limit.sync="rollCall.limit"
-                  :page-sizes="rollCall.page_size"
-                  @pagination="getCallName" />
+      <pagination
+        :total="rollCall.total"
+        :page.sync="rollCall.page"
+        :limit.sync="rollCall.limit"
+        :page-sizes="rollCall.page_size"
+        @pagination="getCallName"
+      />
     </el-dialog>
   </div>
 </template>
 <script>
-import pagination from '@/components/Pagination/index'
-import { getSchool } from '@/api/systemManage'
-import { findVipGroupTeachingRecord, getStudyStudents, resetVipClass } from '@/api/vipSeting'
-import { findAttendanceStudentByCourseWithPage, updateStudentAttendances, updateTeacherAttendance } from '@/api/buildTeam'
-import { permission } from '@/utils/directivePage'
+import pagination from "@/components/Pagination/index";
+import { getSchool } from "@/api/systemManage";
+import {
+  findVipGroupTeachingRecord,
+  getStudyStudents,
+  resetVipClass,
+} from "@/api/vipSeting";
+import {
+  findAttendanceStudentByCourseWithPage,
+  updateStudentAttendances,
+  updateTeacherAttendance,
+} from "@/api/buildTeam";
+import { permission } from "@/utils/directivePage";
 export default {
   components: { pagination },
-  name: 'teacherRecord',
-  data () {
+  name: "teacherRecord",
+  data() {
     return {
       searchForm: {
-        type: '',
-        status: '',
-        time: []
+        type: "",
+        status: "",
+        time: [],
       },
       searchLsit: [],
       tableList: [],
-      id: '',
-      complaintsNum: '', //投诉数
-      currentClassTimes: '', //当前课数
-      isSalaryNum: '', // 已结算
-      totalClassTimes: '',// 未上课数
+      id: "",
+      complaintsNum: "", //投诉数
+      currentClassTimes: "", //当前课数
+      isSalaryNum: "", // 已结算
+      totalClassTimes: "", // 未上课数
       studentVisible: false, // 查看上课学员数的弹窗
       courseVisible: false, // 课时调整弹窗
       studentList: [],
       cooperationList: [],
       maskForm: {
-        data: '',
-        startTime: '',
-        endTime: '',
-        status: '',
-        type: '',
-        cooperation: ''
-
+        data: "",
+        startTime: "",
+        endTime: "",
+        status: "",
+        type: "",
+        cooperation: "",
       },
-      markAttendance: { // 考勤状态
+      markAttendance: {
+        // 考勤状态
         status: false,
-        dataInfo: {}
+        dataInfo: {},
       },
-      activeId: '',
+      activeId: "",
       activeRow: null, //
       maskrules: {
-        date: [{ required: true, message: '请选择修改日期', trigger: 'blur' }],
-        startTime: [{ required: true, message: '请选择开始', trigger: 'blur' }],
-        endTime: [{ required: true, message: '请选择结束', trigger: 'blur' }]
+        date: [{ required: true, message: "请选择修改日期", trigger: "blur" }],
+        startTime: [{ required: true, message: "请选择开始", trigger: "blur" }],
+        endTime: [{ required: true, message: "请选择结束", trigger: "blur" }],
       },
       rules: {
         // 分页规则
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50] // 选择限制显示条数
+        page_size: [10, 20, 40, 50], // 选择限制显示条数
       },
-      rollCall: { // 点名表
+      rollCall: {
+        // 点名表
         status: false,
         gridData: [],
         selectItem: {}, // 选中状态
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50] // 选择限制显示条数
-      }
-    }
+        page_size: [10, 20, 40, 50], // 选择限制显示条数
+      },
+    };
   },
-  mounted () {
-    this.__init()
+  mounted() {
+    this.__init();
   },
-  activated () {
-    this.__init()
+  activated() {
+    this.__init();
   },
   methods: {
-    __init () {
+    __init() {
       let id = this.$route.query.id;
       this.id = id;
-      this.rules.page = 1
+      this.rules.page = 1;
       // 获取vip教学记录
-      this.getList()
+      this.getList();
       // 获取分部教学点
-      getSchool({ organId: null }).then(res => {
+      getSchool({ organId: null }).then((res) => {
         if (res.code == 200) {
           this.cooperationList = res.data;
         }
-      })
+      });
     },
-    search () {
+    search() {
       this.rules.page = 1;
-      this.getList()
+      this.getList();
     },
-    getList () {
+    getList() {
       let startTime;
       let endTime;
       if (this.searchForm.time) {
-        startTime = this.searchForm.time[0]
-        endTime = this.searchForm.time[1]
+        startTime = this.searchForm.time[0];
+        endTime = this.searchForm.time[1];
       } else {
-        startTime = '';
-        endTime = '';
+        startTime = "";
+        endTime = "";
       }
       let obj = {
         vipGroupId: this.id,
@@ -432,9 +472,9 @@ export default {
         status: this.searchForm.status || null,
         teachMode: this.searchForm.type || null,
         startTime,
-        endTime
-      }
-      findVipGroupTeachingRecord(obj).then(res => {
+        endTime,
+      };
+      findVipGroupTeachingRecord(obj).then((res) => {
         if (res.code == 200) {
           this.complaintsNum = res.data.baseInfo.complaintsNum;
           // 当前课数
@@ -444,160 +484,165 @@ export default {
           this.totalClassTimes = res.data.baseInfo.courseNoStartNum;
           // this.totalClassTimes = res.data.baseInfo.totalClassTimes - this.currentClassTimes;
           this.tableList = res.data.pageInfo.rows;
-          this.rules.total = res.data.pageInfo.total
+          this.rules.total = res.data.pageInfo.total;
         }
-      })
+      });
     },
-    batchAdjustmentTime () {
-      let tempData = this.markAttendance.dataInfo
+    batchAdjustmentTime() {
+      let tempData = this.markAttendance.dataInfo;
       let params = {
-        "courseScheduleId": tempData.id,
-        "signInStatus": 1,
-        "signOutStatus": 1
-      }
-      updateTeacherAttendance(params).then(res => {
+        courseScheduleId: tempData.id,
+        signInStatus: 1,
+        signOutStatus: 1,
+      };
+      updateTeacherAttendance(params).then((res) => {
         if (res.code == 200) {
-          this.$message.success('补卡成功')
-          this.markAttendance.status = false
-          this.getList()
+          this.$message.success("补卡成功");
+          this.markAttendance.status = false;
+          this.getList();
         } else {
-          this.$message.error(res.msg)
+          this.$message.error(res.msg);
         }
-      })
+      });
     },
-    onMarkAttendance (item) { // 补考勤
+    onMarkAttendance(item) {
+      // 补考勤
       this.markAttendance = {
         status: true,
-        dataInfo: item
-      }
+        dataInfo: item,
+      };
     },
-    onCallName (item) { // 点名表
-      this.rollCall.page = 1
-      this.rollCall.selectItem = item
-      this.getCallName()
+    onCallName(item) {
+      // 点名表
+      this.rollCall.page = 1;
+      this.rollCall.selectItem = item;
+      this.getCallName();
     },
-    getCallName () {
-      let rollCall = this.rollCall
+    getCallName() {
+      let rollCall = this.rollCall;
       let params = {
         page: rollCall.page,
         rows: rollCall.limit,
-        courseScheduleId: rollCall.selectItem.id
-      }
-      findAttendanceStudentByCourseWithPage(params).then(res => {
-        let result = res.data
-        rollCall.status = true
+        courseScheduleId: rollCall.selectItem.id,
+      };
+      findAttendanceStudentByCourseWithPage(params).then((res) => {
+        let result = res.data;
+        rollCall.status = true;
         if (res.code == 200) {
-          rollCall.gridData = result.rows
-          rollCall.total = result.total
+          rollCall.gridData = result.rows;
+          rollCall.total = result.total;
         }
-      })
+      });
     },
-    onChangeRollCall (type, row) {
-      let rollCall = this.rollCall
+    onChangeRollCall(type, row) {
+      let rollCall = this.rollCall;
       let params = {
         courseScheduleId: rollCall.selectItem.id,
-        studentAttendances: [{
-          userId: row.studentId,
-          status: type
-        }]
-      }
-      updateStudentAttendances(params).then(res => {
+        studentAttendances: [
+          {
+            userId: row.studentId,
+            status: type,
+          },
+        ],
+      };
+      updateStudentAttendances(params).then((res) => {
         if (res.code == 200) {
-          this.$message.success('修改成功')
-          row.status = type
-          this.getList()
+          this.$message.success("修改成功");
+          row.status = type;
+          this.getList();
         } else {
-          this.$message.error(res.msg)
+          this.$message.error(res.msg);
         }
-      })
+      });
     },
-    lookStudents (row) {
+    lookStudents(row) {
       let id = row.id;
-      getStudyStudents({ courseScheduleId: id }).then(res => {
+      getStudyStudents({ courseScheduleId: id }).then((res) => {
         if (res.code == 200) {
           this.studentList = res.data;
           this.studentVisible = true;
         }
-      })
+      });
     },
-    permission (str) {
-      return permission(str)
+    permission(str) {
+      return permission(str);
     },
-    handleClose () {
+    handleClose() {
       this.studentList = [];
       this.studentVisible = false;
     },
-    resetClass (row) {
+    resetClass(row) {
       this.courseVisible = true;
       // 弹出弹窗
       this.activeId = row.id;
       this.activeRow = row;
       // resetVipClass().then()
-
     },
-    resetCourse () {
-
+    resetCourse() {
       // 点击弹窗效验
-      this.$refs['maskForm'].validate(valid => {
+      this.$refs["maskForm"].validate((valid) => {
         if (valid) {
           // 效验成功
-          resetVipClass({ id: this.activeId, classDate: this.maskForm.date, startClassTime: this.maskForm.date + ' ' + this.maskForm.startTime, endClassTime: this.maskForm.date + ' ' + this.maskForm.endTime, schoolId: this.maskForm.cooperation }).then(
-            res => {
-              if (res.code == 200) {
-                this.$message.success('调整成功')
-                this.getList()
-                this.courseVisible = false;
-                this.$refs['maskForm'].resetFields();
-              } else {
-                this.$message.error(res.msg)
-              }
+          resetVipClass({
+            id: this.activeId,
+            classDate: this.maskForm.date,
+            startClassTime: this.maskForm.date + " " + this.maskForm.startTime,
+            endClassTime: this.maskForm.date + " " + this.maskForm.endTime,
+            schoolId: this.maskForm.cooperation,
+          }).then((res) => {
+            if (res.code == 200) {
+              this.$message.success("调整成功");
+              this.getList();
+              this.courseVisible = false;
+              this.$refs["maskForm"].resetFields();
+            } else {
+              this.$message.error(res.msg);
             }
-          )
+          });
         }
-      })
-
-    }
+      });
+    },
   },
   filters: {
-    fitterisSalary (val) {
-      let arr = ['未结算', '已结算'];
-      return arr[val]
+    fitterisSalary(val) {
+      let arr = ["未结算", "已结算"];
+      return arr[val];
     },
-    fitterTeachMode (val) {
-      if (val == 'ONLINE') {
-        return '线上课'
-      } else if (val == 'OFFLINE') {
-        return '线下课'
+    fitterTeachMode(val) {
+      if (val == "ONLINE") {
+        return "线上课";
+      } else if (val == "OFFLINE") {
+        return "线下课";
       }
     },
-    fitterStatus (val) {
-      if (val == 'NOT_START') {
-        return '未开始'
-      } else if (val == 'UNDERWAY') {
-        return '进行中'
-      } else if (val == 'OVER') {
-        return '已结束'
+    fitterStatus(val) {
+      if (val == "NOT_START") {
+        return "未开始";
+      } else if (val == "UNDERWAY") {
+        return "进行中";
+      } else if (val == "OVER") {
+        return "已结束";
       }
     },
-    endTime (val) {
+    endTime(val) {
       if (val) {
-        return val.split(' ')[1].substring(0, 5)
+        return val.split(" ")[1].substring(0, 5);
       } else {
-        return val
+        return val;
       }
     },
-    studentCallName: value => {
+    studentCallName: (value) => {
       let template = {
         NORMAL: "到课",
         TRUANT: "未到",
         LEAVE: "请假",
         DROP_OUT: "退学",
-        '': '未到'
-      }
-      return template[value]
-    }
-  }
-}
+        "": "未到",
+      };
+      return template[value];
+    },
+  },
+};
 </script>
 <style lang="scss" scope>
 </style>

+ 7 - 3
src/views/vipClass/vipDetail/index.vue

@@ -7,30 +7,34 @@
     </h2>
     <div class="m-core">
       <!-- navMenu -->
-      <el-tabs v-model.trim="activeName"
+      <tab-router v-model.trim="activeName"
                type="card"
                @tab-click="handleClick">
         <el-tab-pane label="基本信息"
+        lazy
                      v-if="permissionList.vipBase"
                      name="1">
           <vipBase v-if="activeName == 1" />
         </el-tab-pane>
         <el-tab-pane label="教学记录"
                      v-if="permissionList.teacherRecord"
+                     lazy
                      name="2">
           <teacherRecord v-if="activeName == 2" />
         </el-tab-pane>
         <el-tab-pane label="VIP课程财务"
                      v-if="permissionList.fnanceInfo"
+                     lazy
                      name="3">
           <fnanceInfo v-if="activeName == 3" />
         </el-tab-pane>
         <el-tab-pane label="VIP学生列表"
                      v-if="permissionList.vipStudentList"
+                     lazy
                      name="4">
           <vipStudentList v-if="activeName == 4" />
         </el-tab-pane>
-      </el-tabs>
+      </tab-router>
     </div>
   </div>
 </template>
@@ -84,4 +88,4 @@ export default {
 }
 </script>
 <style lang="scss">
-</style>
+</style>

この差分においてかなりの量のファイルが変更されているため、一部のファイルを表示していません