Browse Source

Merge branch 'iteration_adminOptimiz' of http://git.dayaedu.com/molingzhide/dy-admin-manager into iteration_adminOptimiz

wolyshaw 4 years ago
parent
commit
c94928a9b8

File diff suppressed because it is too large
+ 0 - 0
dist/index.html


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.92315bfb.css


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/chunk-21af0999.c5172fd3.css


+ 0 - 1
dist/static/css/chunk-3569217f.0dd3a490.css

@@ -1 +0,0 @@
-.table[data-v-25279d2a]{margin-top:20px}.table[data-v-25279d2a] .el-table__header .has-gutter tr th{background-color:#edeef0;color:#444}

+ 0 - 1
dist/static/css/chunk-750a728a.33481f89.css

@@ -1 +0,0 @@
-.btns[data-v-3b950f08]{text-align:right}.remark[data-v-2db81401]{display:inline;overflow:hidden;white-space:pre}

+ 1 - 0
dist/static/css/chunk-a2b07e50.5c3d2ece.css

@@ -0,0 +1 @@
+.table[data-v-9b72d7ac]{margin-top:20px}.table[data-v-9b72d7ac] .el-table__header .has-gutter tr th{background-color:#edeef0;color:#444}

File diff suppressed because it is too large
+ 0 - 0
dist/static/css/chunk-e8382f86.20227ca4.css


+ 1 - 0
dist/static/css/chunk-f3dd4bc6.73152e07.css

@@ -0,0 +1 @@
+.btns[data-v-3b950f08]{text-align:right}.remark[data-v-7dfb10a6]{display:inline;overflow:hidden;white-space:pre}

File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.0dd41125.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/chunk-21af0999.0fd6d93a.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/chunk-3569217f.0d79f44d.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/chunk-750a728a.737b68b2.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/chunk-a2b07e50.f1bff38c.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/chunk-a6f20cb6.68af63ec.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/chunk-e8382f86.04602b9d.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/chunk-f3dd4bc6.af77f527.js


+ 1 - 0
src/router/notKeepAliveList.js

@@ -19,4 +19,5 @@ export default [
   '/journal/requestProcessing', // 课酬申述
   '/journal/payAppeal', // 考勤申诉
   '/business/teamDetail', // 乐团列表
+  '/business/vipList', // vip列表
 ]

+ 1 - 0
src/views/teamDetail/components/modals/class-pay-list-item.vue

@@ -165,6 +165,7 @@ export default {
       }
 
       this.cycle = {
+        ...this.cycle,
         paymentAmount: money,
       };
     },

+ 337 - 239
src/views/vipClass/vipList.vue

@@ -1,111 +1,146 @@
 <template>
   <div class="m-container">
     <h2>
-      <div class="squrt"></div>VIP课列表
+      <div class="squrt"></div>
+      VIP课列表
     </h2>
-    <div class="newBand"
-         v-permission="'/buildVip'"
-         @click="gotoBuildVip">新建VIP课</div>
-    <div class="newBand"
-         v-permission="'export/vipGroupList'"
-         @click="onVIPCourseExport">导出VIP课</div>
-    <div class="newBand"
-         v-permission="'export/vipGroup'"
-         @click="onStudentExport"
-         style="max-width: inherit;">VIP课程续费提醒导出</div>
+    <div class="newBand" v-permission="'/buildVip'" @click="gotoBuildVip">
+      新建VIP课
+    </div>
+    <div
+      class="newBand"
+      v-permission="'export/vipGroupList'"
+      @click="onVIPCourseExport"
+    >
+      导出VIP课
+    </div>
+    <div
+      class="newBand"
+      v-permission="'export/vipGroup'"
+      @click="onStudentExport"
+      style="max-width: inherit"
+    >
+      VIP课程续费提醒导出
+    </div>
     <div class="m-core">
       <!-- 搜索类型 -->
-      <el-form :inline="true"
-               class="searchForm"
-               v-model.trim="searchForm">
+      <save-form
+        :inline="true"
+        @submit="search"
+        @reset="onReSet"
+        class="searchForm"
+        :model="searchForm"
+      >
         <!-- 状态 指导老师 活动方案-->
         <el-form-item>
-          <el-input v-model.trim="searchForm.search"
-                    @keyup.enter.native="search"
-                    placeholder="课程名称"></el-input>
+          <el-input
+            v-model.trim="searchForm.search"
+            @keyup.enter.native="search"
+            placeholder="课程名称"
+          ></el-input>
         </el-form-item>
         <el-form-item prop="orgin">
-          <el-select class="multiple"
-                     v-model.trim="searchForm.orgin"
-                     filterable
-                     clearable
-                     placeholder="请选择分部">
-            <el-option v-for="(item,index) in organList"
-                       :key="index"
-                       :label="item.name"
-                       :value="item.id"></el-option>
+          <el-select
+            class="multiple"
+            v-model.trim="searchForm.orgin"
+            filterable
+            clearable
+            placeholder="请选择分部"
+          >
+            <el-option
+              v-for="(item, index) in organList"
+              :key="index"
+              :label="item.name"
+              :value="item.id"
+            ></el-option>
           </el-select>
         </el-form-item>
         <!-- statusList -->
         <el-form-item prop="status">
-          <el-select class="multiple"
-                     v-model.trim="searchForm.status"
-                     filterable
-                     clearable
-                     placeholder="请选课程状态">
-            <el-option v-for="(item,index) in statusList"
-                       :key="index"
-                       :label="item.lable"
-                       :value="item.value"></el-option>
+          <el-select
+            class="multiple"
+            v-model.trim="searchForm.status"
+            filterable
+            clearable
+            placeholder="请选课程状态"
+          >
+            <el-option
+              v-for="(item, index) in statusList"
+              :key="index"
+              :label="item.lable"
+              :value="item.value"
+            ></el-option>
           </el-select>
         </el-form-item>
 
         <el-form-item>
-          <el-select v-model.trim="searchForm.teacherId"
-                     clearable
-                     filterable
-                     placeholder="指导老师">
-            <el-option v-for="(item,index) in teacherList"
-                       :key="index"
-                       :value="item.id"
-                       :label="item.realName"></el-option>
+          <el-select
+            v-model.trim="searchForm.teacherId"
+            clearable
+            filterable
+            placeholder="指导老师"
+          >
+            <el-option
+              v-for="(item, index) in teacherList"
+              :key="index"
+              :value="item.id"
+              :label="item.realName"
+            ></el-option>
           </el-select>
         </el-form-item>
         <el-form-item>
-          <el-select v-model.trim="searchForm.activityId"
-                     clearable
-                     filterable
-                     placeholder="活动方案">
-            <el-option v-for="(item,index) in activeList"
-                       :key="index"
-                       :value="item.id"
-                       :label="item.name"></el-option>
+          <el-select
+            v-model.trim="searchForm.activityId"
+            clearable
+            filterable
+            placeholder="活动方案"
+          >
+            <el-option
+              v-for="(item, index) in activeList"
+              :key="index"
+              :value="item.id"
+              :label="item.name"
+            ></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>
-          <el-button @click="search"
-                     type="danger">搜索</el-button>
-          <el-button @click="onReSet"
-                     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>
-      </el-form>
+      </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"
-                           width="120px"
-                           prop="id"
-                           label="课程组编号"></el-table-column>
-          <el-table-column align="center"
-                           width="200px"
-                           prop="name"
-                           label="课程名称">
+        <el-table
+          style="width: 100%"
+          :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
+          :data="tableData"
+        >
+          <el-table-column
+            align="center"
+            width="120px"
+            prop="id"
+            label="课程组编号"
+          ></el-table-column>
+          <el-table-column
+            align="center"
+            width="200px"
+            prop="name"
+            label="课程名称"
+          >
             <!-- <template slot-scope="scope">
               <el-tooltip placement="top-start">
                   <div slot="content">{{ scope.row.name }}</div>
@@ -115,142 +150,194 @@
               </el-tooltip>
             </template> -->
           </el-table-column>
-          <el-table-column align="center"
-                           prop="vipGroupCategoryName"
-                           label="课程形式"></el-table-column>
-          <el-table-column align="center"
-                           prop="status"
-                           label="课程状态">
+          <el-table-column
+            align="center"
+            prop="vipGroupCategoryName"
+            label="课程形式"
+          ></el-table-column>
+          <el-table-column align="center" prop="status" label="课程状态">
             <template slot-scope="scope">
-              <div>{{ scope.row.status | formatterStatus}}</div>
+              <div>{{ scope.row.status | formatterStatus }}</div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="userName"
-                           label="指导老师"
-                           width='100px'></el-table-column>
-          <el-table-column align="center"
-                           prop="educationalTeacherName"
-                           label="教务老师"></el-table-column>
-          <el-table-column align="center"
-                           prop="studentNum"
-                           label="班级人数"></el-table-column>
-          <el-table-column align="center"
-                           label="课程单价">
+          <el-table-column
+            align="center"
+            prop="userName"
+            label="指导老师"
+            width="100px"
+          ></el-table-column>
+          <el-table-column
+            align="center"
+            prop="educationalTeacherName"
+            label="教务老师"
+          ></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>
-                <p>{{scope.row.courseUnitPrice| moneyFormat }} 元</p>
+                <p>{{ scope.row.courseUnitPrice | moneyFormat }} 元</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="vipGroupActivityName"
-                           label="活动方案"></el-table-column>
-          <el-table-column align="center"
-                           label="当前课次">
+          <el-table-column
+            align="center"
+            prop="vipGroupActivityName"
+            label="活动方案"
+          ></el-table-column>
+          <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"
-                           label="月均消耗">
-            <template slot-scope="scope">{{ scope.row.monthConsumeRate }}%</template>
+          <el-table-column align="center" label="月均消耗">
+            <template slot-scope="scope"
+              >{{ scope.row.monthConsumeRate }}%</template
+            >
           </el-table-column>
-          <el-table-column align="center"
-                           prop="createTime"
-                           label="上次课时间"
-                           width='100px'>
-
+          <el-table-column
+            align="center"
+            prop="createTime"
+            label="上次课时间"
+            width="100px"
+          >
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.lastOverTime | formatterTime}}</p>
+                <p>{{ scope.row.lastOverTime | formatterTime }}</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="paymentExpireDate"
-                           label="开课时间"
-                           width='100px'>
+          <el-table-column
+            align="center"
+            prop="paymentExpireDate"
+            label="开课时间"
+            width="100px"
+          >
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.courseStartDate | formatterTime}}</p>
+                <p>{{ scope.row.courseStartDate | formatterTime }}</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="coursesExpireDate"
-                           label="结束时间"
-                           width='100px'>
+          <el-table-column
+            align="center"
+            prop="coursesExpireDate"
+            label="结束时间"
+            width="100px"
+          >
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.coursesExpireDate | formatterTime}}</p>
+                <p>{{ scope.row.coursesExpireDate | formatterTime }}</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="createTime"
-                           label="申请时间"
-                           width='100px'>
+          <el-table-column
+            align="center"
+            prop="createTime"
+            label="申请时间"
+            width="100px"
+          >
             <template slot-scope="scope">
               <div>
-                <p>{{scope.row.createTime | formatterTime}}</p>
+                <p>{{ scope.row.createTime | formatterTime }}</p>
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center"
-                           prop="stopReason"
-                           label="备注">
+          <el-table-column align="center" prop="stopReason" label="备注">
           </el-table-column>
-          <el-table-column align="center"
-                           width="150px"
-                           fixed="right"
-                           label="操作">
+          <el-table-column
+            align="center"
+            width="150px"
+            fixed="right"
+            label="操作"
+          >
             <template slot-scope="scope">
               <div>
-                <el-button type="text"
-                           v-if="permission('/vipDetail')"
-                           @click="gotoVipDetail(scope.row)">查看</el-button>
+                <el-button
+                  type="text"
+                  v-if="permission('/vipDetail')"
+                  @click="gotoVipDetail(scope.row)"
+                  >查看</el-button
+                >
                 <!--
                 <el-button type="text">启动</el-button>-->
                 <!-- <el-button type="text"
                            v-if="scope.row.status <3"
                 @click='closeVip(scope.row.id)'>关闭</el-button>-->
-                <el-popover placement="top"
-                            width="160"
-                            v-if="scope.row.status < 3 && scope.row.enableDelete != 1 && permission('vipGroupManage/stopVipGroup')"
-                            :ref="scope.$index">
-                  <p style="margin-bottom:10px;">确定停止该vip课?</p>
-                  <el-input v-model.trim="stopReason"
-                            placeholder="请输入关闭原因"></el-input>
+                <el-popover
+                  placement="top"
+                  width="160"
+                  v-if="
+                    scope.row.status < 3 &&
+                    scope.row.enableDelete != 1 &&
+                    permission('vipGroupManage/stopVipGroup')
+                  "
+                  :ref="scope.$index"
+                >
+                  <p style="margin-bottom: 10px">确定停止该vip课?</p>
+                  <el-input
+                    v-model.trim="stopReason"
+                    placeholder="请输入关闭原因"
+                  ></el-input>
                   <div style="text-align: right; margin-top: 20px">
-                    <el-button size="mini"
-                               type="text"
-                               @click="onCancelVip(scope)">取消</el-button>
-                    <el-button type="primary"
-                               size="mini"
-                               @click="closeVip(scope)">确定</el-button>
+                    <el-button
+                      size="mini"
+                      type="text"
+                      @click="onCancelVip(scope)"
+                      >取消</el-button
+                    >
+                    <el-button
+                      type="primary"
+                      size="mini"
+                      @click="closeVip(scope)"
+                      >确定</el-button
+                    >
                   </div>
-                  <el-button type="text"
-                             slot="reference">停止</el-button>
+                  <el-button type="text" slot="reference">停止</el-button>
                 </el-popover>
-                <el-button type="text"
-                           @click="onVipDelete(scope.row)"
-                           v-if="scope.row.enableDelete == 1 && permission('vipGroupManage/deleteVipGroup')">删除</el-button>
-                <el-button type="text"
-                           v-if="scope.row.status > 1&&scope.row.status != 3 && permission('/vipReset')"
-                           @click="resetVip(scope.row)">修改</el-button>
+                <el-button
+                  type="text"
+                  @click="onVipDelete(scope.row)"
+                  v-if="
+                    scope.row.enableDelete == 1 &&
+                    permission('vipGroupManage/deleteVipGroup')
+                  "
+                  >删除</el-button
+                >
+                <el-button
+                  type="text"
+                  v-if="
+                    scope.row.status > 1 &&
+                    scope.row.status != 3 &&
+                    permission('/vipReset')
+                  "
+                  @click="resetVip(scope.row)"
+                  >修改</el-button
+                >
               </div>
             </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>
   </div>
@@ -262,18 +349,18 @@ import {
   vipGroupActivity,
   closeVip,
   getVipGroupDetail,
-  deleteVipGroup
+  deleteVipGroup,
 } from "@/api/vipSeting";
 import { getTeacher, getEmployeeOrgan } from "@/api/buildTeam";
 import store from "@/store";
 import axios from "axios";
 import { getToken } from "@/utils/auth";
 import load from "@/utils/loading";
-import { permission } from '@/utils/directivePage'
+import { permission } from "@/utils/directivePage";
 export default {
   components: { pagination },
   name: "vipList",
-  data () {
+  data() {
     return {
       organId: null,
       searchForm: {
@@ -282,7 +369,7 @@ export default {
         search: null,
         orgin: null,
         status: null,
-        hasEducationalTeacherId: null
+        hasEducationalTeacherId: null,
       },
       teacherList: [],
       activeList: [],
@@ -293,7 +380,7 @@ export default {
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50] // 选择限制显示条数
+        page_size: [10, 20, 40, 50], // 选择限制显示条数
       },
       statusList: [
         { lable: "未开始", value: "0" },
@@ -302,12 +389,12 @@ export default {
         { lable: "进行中", value: "2" },
         { lable: "已结束", value: "4" },
         { lable: "取消", value: "3" },
-        { lable: "暂停", value: "6" }
+        { lable: "暂停", value: "6" },
       ],
       stopReason: null, // 停止原因
     };
   },
-  created () {
+  created() {
     if (this.$route.query.searchForm) {
       this.$route.query.searchForm instanceof Object
         ? (this.searchForm = this.$route.query.searchForm)
@@ -319,49 +406,49 @@ export default {
         : (this.rules = JSON.parse(this.$route.query.rules));
     }
   },
-  mounted () {
+  mounted() {
     this.init();
   },
-  activated () {
+  activated() {
     this.init();
   },
   methods: {
-    init () {
-      getEmployeeOrgan().then(res => {
+    init() {
+      getEmployeeOrgan().then((res) => {
         if (res.code == 200) {
           this.organList = res.data;
         }
       });
 
       //   <!-- 状态 指导老师 活动方案-->
-      getTeacher({ organId: this.organId }).then(res => {
+      getTeacher({ organId: this.organId }).then((res) => {
         if (res.code == 200) {
           this.teacherList = res.data;
         }
       });
       // 获取活动方案
-      vipGroupActivity({ organId: this.organId, rows: 9999 }).then(res => {
+      vipGroupActivity({ organId: this.organId, rows: 9999 }).then((res) => {
         if (res.code == 200) {
           this.activeList = res.data.rows;
         }
       });
       this.getList();
     },
-    search () {
+    search() {
       this.rules.page = 1;
       this.getList();
     },
-    onReSet () {
+    onReSet() {
       this.searchForm = {
         teacherId: null,
         activityId: null,
         search: null,
         orgin: null,
-        status: null
+        status: null,
       };
       this.getList();
     },
-    getList () {
+    getList() {
       let params = this.searchForm;
       params.page = this.rules.page;
       params.rows = this.rules.limit;
@@ -369,7 +456,7 @@ export default {
         this.searchForm.hasEducationalTeacherId || null;
       params.organId = this.searchForm.orgin || null;
       params.status = this.searchForm.status || null;
-      getVipList(params).then(res => {
+      getVipList(params).then((res) => {
         if (res.code == 200) {
           // this.tableData = [];
           setTimeout(() => {
@@ -380,41 +467,39 @@ export default {
       });
     },
     // 跳转到vip详情
-    gotoVipDetail (row) {
+    gotoVipDetail(row) {
       let rules = JSON.stringify(this.rules);
       let searchForm = JSON.stringify(this.searchForm);
       let id = row.id;
       let name = row.name;
       this.$router.push({
         path: "/business/vipDetail",
-        query: { id, name, rules, searchForm }
+        query: { id, name, rules, searchForm },
       });
     },
-    closeVip (scope) {
+    closeVip(scope) {
       let id = scope.row.id;
-      closeVip({ vipGroupId: id, stopReason: this.stopReason }).then(
-        res => {
-          if (res.code == 200) {
-            this.$message.success("停止课程成功");
-            scope._self.$refs[scope.$index].doClose();
-            this.getList();
-          }
+      closeVip({ vipGroupId: id, stopReason: this.stopReason }).then((res) => {
+        if (res.code == 200) {
+          this.$message.success("停止课程成功");
+          scope._self.$refs[scope.$index].doClose();
+          this.getList();
         }
-      );
+      });
     },
-    onCancelVip (scope) {
-      this.stopReason = null
-      scope._self.$refs[scope.$index].doClose()
+    onCancelVip(scope) {
+      this.stopReason = null;
+      scope._self.$refs[scope.$index].doClose();
     },
-    gotoBuildVip () {
+    gotoBuildVip() {
       let rules = JSON.stringify(this.rules);
       let searchForm = JSON.stringify(this.searchForm);
       this.$router.push({
         path: "/business/buildVip",
-        query: { rules, searchForm }
+        query: { rules, searchForm },
       });
     },
-    onVIPCourseExport () {
+    onVIPCourseExport() {
       // 导出VIP课
       let searchForm = this.searchForm;
       let data = {
@@ -422,35 +507,35 @@ export default {
         activityId: searchForm.activityId || null,
         organId: searchForm.orgin || null,
         status: searchForm.status || null,
-        search: searchForm.search || null
+        search: searchForm.search || null,
       };
       let url = "/api-web/export/vipGroupList";
       const options = {
         method: "get",
         headers: {
-          Authorization: getToken()
+          Authorization: getToken(),
         },
         params: data,
         url,
-        responseType: "blob"
+        responseType: "blob",
       };
       this.$confirm("您确定导出VIP课吗?", "提示", {
         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);
@@ -467,44 +552,44 @@ export default {
               });
               load.endLoading();
             })
-            .catch(error => {
+            .catch((error) => {
               this.$message.error("导出数据失败,请联系管理员");
               load.endLoading();
             });
         })
-        .catch(() => { });
+        .catch(() => {});
     },
-    onStudentExport () {
+    onStudentExport() {
       // 导出VIP课
       // let searchForm = this.searchForm;
-      let data =  {}
+      let data = {};
       let url = "/api-web/export/vipGroup";
       const options = {
         method: "get",
         headers: {
-          Authorization: getToken()
+          Authorization: getToken(),
         },
         params: data,
         url,
-        responseType: "blob"
+        responseType: "blob",
       };
       this.$confirm("VIP课程续费提醒导出?", "提示", {
         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);
@@ -512,7 +597,8 @@ export default {
                 } else {
                   let objectUrl = URL.createObjectURL(blob);
                   let link = document.createElement("a");
-                  let fname = "VIP课程续费提醒" + new Date().getTime() + '.xlsx'; //下载文件的名字
+                  let fname =
+                    "VIP课程续费提醒" + new Date().getTime() + ".xlsx"; //下载文件的名字
                   link.href = objectUrl;
                   link.setAttribute("download", fname);
                   document.body.appendChild(link);
@@ -521,15 +607,15 @@ export default {
               });
               load.endLoading();
             })
-            .catch(error => {
+            .catch((error) => {
               this.$message.error("导出数据失败,请联系管理员");
               load.endLoading();
             });
         })
-        .catch(() => { });
+        .catch(() => {});
     },
     // 修改vip
-    resetVip (row) {
+    resetVip(row) {
       let id = row.id;
       let organId = row.organId;
       let educationalTeacherId = row.educationalTeacherId;
@@ -537,34 +623,46 @@ export default {
       let rules = JSON.stringify(this.rules);
       let searchForm = JSON.stringify(this.searchForm);
       let name = row.name;
-      let endTimeStr = row.coursesExpireDate
-      let startTimeStr = row.courseStartDate
+      let endTimeStr = row.coursesExpireDate;
+      let startTimeStr = row.courseStartDate;
       this.$router.push({
         path: "/business/vipReset",
-        query: { id, educationalTeacherId, organId, userId, rules, searchForm, name, endTimeStr, startTimeStr }
+        query: {
+          id,
+          educationalTeacherId,
+          organId,
+          userId,
+          rules,
+          searchForm,
+          name,
+          endTimeStr,
+          startTimeStr,
+        },
       });
     },
     // 删除VIP
-    onVipDelete (row) {
+    onVipDelete(row) {
       this.$confirm("您确定删除该VIP课吗?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning"
-      }).then(() => {
-        deleteVipGroup({ vipGroupId: row.id }).then(res => {
-          if (res.code == 200) {
-            this.$message.success("删除成功");
-            this.getList();
-          }
+        type: "warning",
+      })
+        .then(() => {
+          deleteVipGroup({ vipGroupId: row.id }).then((res) => {
+            if (res.code == 200) {
+              this.$message.success("删除成功");
+              this.getList();
+            }
+          });
         })
-      }).catch(() => { });
+        .catch(() => {});
+    },
+    permission(str) {
+      return permission(str);
     },
-    permission (str) {
-      return permission(str)
-    }
   },
   filters: {
-    formatterTime (val) {
+    formatterTime(val) {
       let result;
       if (val) {
         result = val.split(" ")[0];
@@ -573,7 +671,7 @@ export default {
       }
       return result;
     },
-    formatterStatus (val) {
+    formatterStatus(val) {
       let arr = [
         "未开始",
         "报名中",
@@ -581,11 +679,11 @@ export default {
         "取消",
         "已结束",
         "报名结束",
-        "暂停"
+        "暂停",
       ];
       return arr[val];
-    }
-  }
+    },
+  },
 };
 </script>
 <style lang="scss" scoped>
@@ -597,4 +695,4 @@ export default {
 .newBand {
   display: inline-block;
 }
-</style>
+</style>

Some files were not shown because too many files changed in this diff