Browse Source

修改信息

lex 2 năm trước cách đây
mục cha
commit
0a475c4b95
28 tập tin đã thay đổi với 2499 bổ sung2199 xóa
  1. 156 157
      src/api/specialSetting.js
  2. 8 5
      src/constant/index.js
  3. 3 4
      src/router/index.js
  4. 16 2
      src/utils/searchArray.js
  5. 87 80
      src/utils/validate.js
  6. 21 11
      src/views/baseRulesClassSetting/index.vue
  7. 26 62
      src/views/categroyManager/specialSetup/chargesList.vue
  8. 304 249
      src/views/categroyManager/specialSetup/discountManage.vue
  9. 69 42
      src/views/categroyManager/specialSetup/modals/chargesForm.vue
  10. 126 118
      src/views/categroyManager/specialSetup/modals/create-discount.vue
  11. 77 67
      src/views/categroyManager/specialSetup/musicCourseFee.vue
  12. 165 109
      src/views/resetTeaming/components/payInfoDetail.vue
  13. 116 105
      src/views/resetTeaming/components/resetPayList.vue
  14. 110 103
      src/views/resetTeaming/components/strudentPayInfo.vue
  15. 39 27
      src/views/resetTeaming/index.vue
  16. 4 2
      src/views/resetTeaming/modals/courseModel.vue
  17. 25 20
      src/views/resetTeaming/modals/payTeamCourse.vue
  18. 11 3
      src/views/resetTeaming/modals/subject-preview.vue
  19. 72 72
      src/views/resetTeaming/modals/user-pay-form.vue
  20. 96 100
      src/views/teamBuild/components/soundSetComponents/soundSetCore.vue
  21. 166 155
      src/views/teamBuild/components/teamBaseInfo.vue
  22. 268 215
      src/views/teamBuild/components/teamResetSound.vue
  23. 17 19
      src/views/teamBuild/components/teamSoundSet.vue
  24. 111 94
      src/views/teamBuild/teamSeting/index.vue
  25. 39 38
      src/views/teamDetail/components/modals/create-user-pay.vue
  26. 102 102
      src/views/teamDetail/components/resetClass.vue
  27. 117 107
      src/views/teamDetail/components/studentList.vue
  28. 148 131
      src/views/teamDetail/teamList.vue

+ 156 - 157
src/api/specialSetting.js

@@ -1,387 +1,386 @@
 // 系统专项设置api文件
-import request from '@/utils/request'
-import request2 from '@/utils/request2'
-import qs from 'qs'
-let api = '/api-web'
+import request from "@/utils/request";
+import request2 from "@/utils/request2";
+import qs from "qs";
+let api = "/api-web";
 // 分页查询分部列表
-export function branchQueryPage (data) {
+export function branchQueryPage(data) {
   return request({
-    url: api + '/organization/queryPage',
-    method: 'get',
+    url: api + "/organization/queryPage",
+    method: "get",
     params: data
-  })
+  });
 }
 
 // 分页查询分部列表
-export function branchAdd (data) {
+export function branchAdd(data) {
   return request({
-    url: api + '/organization/add',
-    method: 'post',
+    url: api + "/organization/add",
+    method: "post",
     data: qs.stringify(data)
-  })
+  });
 }
 
 // 分页查询分部列表
-export function branchUpdate (data) {
+export function branchUpdate(data) {
   return request({
-    url: api + '/organization/update',
-    method: 'post',
+    url: api + "/organization/update",
+    method: "post",
     data: qs.stringify(data)
-  })
+  });
 }
 
 // 根据父节点查询下一级子节点列表(不递归)
-export function areaQueryChild (data) {
+export function areaQueryChild(data) {
   // return request({
   //   url: api + '/area/queryChild',
   //   method: 'get',
   //   params: data
   // })
   return request2({
-    url: api + '/area/queryChild',
-    method: 'get',
+    url: api + "/area/queryChild",
+    method: "get",
     hideLoading: true,
     params: data
-  })
+  });
 }
 
-
 // 根据子级区域获取父级节点
-export function getParentArea (data) {
+export function getParentArea(data) {
   return request({
     url: api + `/area/getParentArea/${data.id}`,
-    method: 'get'
-  })
+    method: "get"
+  });
 }
 
 // 查询所有子集科目
-export function subSubjectList (data) {
+export function subSubjectList(data) {
   return request({
     url: api + `/subject/queryPageByIdOrName`,
-    method: 'post',
-    data:qs.stringify(data)
-  })
+    method: "post",
+    data: qs.stringify(data)
+  });
 }
 
 // 分页查询科目列表
-export function subjectListTree (data) {
+export function subjectListTree(data) {
   return request({
     url: api + `/subject/queryPageTree`,
-    method: 'get',
+    method: "get",
     params: data
-  })
+  });
 }
 
 // 修改、新增科目
-export function subjectUpset (data) {
+export function subjectUpset(data) {
   return request({
     url: api + `/subject/upset`,
-    method: 'post',
+    method: "post",
     data: data
-  })
+  });
 }
 
 // 分页查询收费类型列表
-export function chargeTypeList (data) {
+export function chargeTypeList(data) {
   return request({
-    url: api + '/chargeType/queryPage',
-    method: 'get',
+    url: api + "/chargeType/queryPage",
+    method: "get",
     params: data
-  })
+  });
 }
 
 // 新增、修改收费类型
-export function chargeTypeUpSet (data) {
+export function chargeTypeUpSet(data) {
   return request({
-    url: api + '/chargeType/upSet',
-    method: 'post',
+    url: api + "/chargeType/upSet",
+    method: "post",
     data: data
-  })
+  });
 }
 
 // 删除收费类型
-export function chargeTypeDel (data) {
+export function chargeTypeDel(data) {
   return request({
     url: api + `/chargeType/del/${data}`,
-    method: 'post'
-  })
+    method: "post"
+  });
 }
 
 // 分页查询训练模板列表
-export function courseHomeworkTemplateList (data) {
+export function courseHomeworkTemplateList(data) {
   return request({
-    url: api + '/courseHomeworkTemplate/queryPage',
-    method: 'post',
+    url: api + "/courseHomeworkTemplate/queryPage",
+    method: "post",
     data: data
-  })
+  });
 }
 
 // 修改训练模板
-export function homeWorkUpdate (data) {
+export function homeWorkUpdate(data) {
   return request({
-    url: api + '/courseHomeworkTemplate/update',
-    method: 'post',
+    url: api + "/courseHomeworkTemplate/update",
+    method: "post",
     data: qs.stringify(data)
-  })
+  });
 }
 
 // 修改训练模板
-export function homeWorkAdd (data) {
+export function homeWorkAdd(data) {
   return request({
-    url: api + '/courseHomeworkTemplate/add',
-    method: 'post',
+    url: api + "/courseHomeworkTemplate/add",
+    method: "post",
     data: qs.stringify(data)
-  })
+  });
 }
 
-
 // 修改训练模板
-export function homeWorkDel (id) {
+export function homeWorkDel(id) {
   return request({
     url: api + `/courseHomeworkTemplate/del/${id}`,
-    method: 'post'
-  })
+    method: "post"
+  });
 }
 
 // 查询已设置的分部列表
-export function queryOrganIdList (data) {
+export function queryOrganIdList(data) {
   return request({
     url: api + `/courseScheduleRewards/queryOrganIdList`,
-    method: 'get',
+    method: "get",
     params: data
-  })
+  });
 }
 
 // 获取收费类型分部关联的默认课程费用添加
-export function chargeTypeOrganizationFeeAdd (data) {
+export function chargeTypeOrganizationFeeAdd(data) {
   return request({
     url: api + `/chargeTypeOrganizationFee/add`,
-    method: 'post',
+    method: "post",
     data: qs.stringify(data)
-  })
+  });
 }
 
 // 获取收费类型分部关联的默认课程费用删除
-export function chargeTypeOrganizationFeeDelete (data) {
+export function chargeTypeOrganizationFeeDelete(data) {
   return request({
     url: api + `/chargeTypeOrganizationFee/delete`,
-    method: 'post',
+    method: "post",
     data: qs.stringify(data)
-  })
+  });
 }
 
 // 获取收费类型分部关联的默认课程费用修改
-export function chargeTypeOrganizationFeeUpdate (data) {
+export function chargeTypeOrganizationFeeUpdate(data) {
   return request({
     url: api + `/chargeTypeOrganizationFee/update`,
-    method: 'post',
+    method: "post",
     data: qs.stringify(data)
-  })
+  });
 }
 
 // 获取收费类型分部关联的默认课程费用列表
-export function chargeTypeOrganizationFee (data) {
+export function chargeTypeOrganizationFee(data) {
   return request({
     url: api + `/chargeTypeOrganizationFee/queryPage`,
-    method: 'get',
+    method: "get",
     params: data
-  })
+  });
 }
 
 // 获取收费类型分部关联的默认课程费用列表
-export function findEducationTeacher (data) {
+export function findEducationTeacher(data) {
   return request({
     url: api + `/employee/findEducationTeacher`,
-    method: 'get',
+    method: "get",
     params: data
-  })
+  });
 }
 
 // 获取收费类型与科目的关联服务
-export function chargeTypeSubjectMapper (data) {
+export function chargeTypeSubjectMapper(data) {
   return request2({
-    url: api + '/chargeTypeSubjectMapper/queryPage',
-    method: 'get',
+    url: api + "/chargeTypeSubjectMapper/queryPage",
+    method: "get",
     data: {},
     params: data,
-    requestType: 'form',
-  })
+    requestType: "form"
+  });
 }
 
 // 新增收费类型与科目的关联服务
-export function insertChargeTypeSubjectMapper (data) {
+export function insertChargeTypeSubjectMapper(data) {
   return request2({
-    url: api + '/chargeTypeSubjectMapper/insert',
-    method: 'post',
-    data,
-  })
+    url: api + "/chargeTypeSubjectMapper/insert",
+    method: "post",
+    data
+  });
 }
 
 // 修改收费类型与科目的关联服务
-export function updateChargeTypeSubjectMapper (data) {
+export function updateChargeTypeSubjectMapper(data) {
   return request2({
-    url: api + '/chargeTypeSubjectMapper/update',
-    method: 'post',
-    data,
-  })
+    url: api + "/chargeTypeSubjectMapper/update",
+    method: "post",
+    data
+  });
 }
 
 // 删除收费类型与科目的关联服务
-export function delChargeTypeSubjectMapper (data) {
-  const { id, ...rest } = data
+export function delChargeTypeSubjectMapper(data) {
+  const { id, ...rest } = data;
   return request2({
-    url: api + '/chargeTypeSubjectMapper/del/' + id,
-    method: 'post',
-    params: rest,
-  })
+    url: api + "/chargeTypeSubjectMapper/del/" + id,
+    method: "post",
+    params: rest
+  });
 }
 
 // 收费方式添加
-export function musicGroupOrganizationCourseSettingsAdd (data) {
+export function musicGroupOrganizationCourseSettingsAdd(data) {
   return request2({
-    url: api + '/musicGroupOrganizationCourseSettings/add',
-    method: 'post',
+    url: api + "/musicGroupOrganizationCourseSettings/add",
+    method: "post",
     data
-  })
+  });
 }
 
 // 收费方式修改
-export function musicGroupOrganizationCourseSettingsUpdate (data) {
+export function musicGroupOrganizationCourseSettingsUpdate(data) {
   return request2({
-    url: api + '/musicGroupOrganizationCourseSettings/update',
-    method: 'post',
+    url: api + "/musicGroupOrganizationCourseSettings/update",
+    method: "post",
     data
-  })
+  });
 }
 
 // 收费方式删除
-export function musicGroupOrganizationCourseSettingsDel (data) {
+export function musicGroupOrganizationCourseSettingsDel(data) {
   return request2({
-    url: api + '/musicGroupOrganizationCourseSettings/delSetting',
-    method: 'post',
+    url: api + "/musicGroupOrganizationCourseSettings/delSetting",
+    method: "post",
     data: {},
     params: data,
-    requestType: 'form',
-  })
+    requestType: "form"
+  });
 }
 
 // 收费方式列表
-export function musicGroupOrganizationCourseSettingsQueryPage (data) {
+export function musicGroupOrganizationCourseSettingsQueryPage(data) {
   return request2({
-    url: api + '/musicGroupOrganizationCourseSettings/queryPage',
-    method: 'get',
+    url: api + "/musicGroupOrganizationCourseSettings/queryPage",
+    method: "get",
     data: {},
     params: data,
-    requestType: 'form',
-  })
+    requestType: "form"
+  });
 }
 
 // 课程费用查询
-export function getOrganizationCourseUnitPriceSettings (data) {
+export function getOrganizationCourseUnitPriceSettings(data) {
   return request2({
     url: api + `/organizationCourseUnitPriceSettings/queryPage`,
-    method: 'get',
+    method: "get",
     params: data,
     data: {},
-    requestType: 'form',
-  })
+    requestType: "form"
+  });
 }
 
 // 新增课程费用
-export function addOrganizationCourseUnitPrice (data) {
+export function addOrganizationCourseUnitPrice(data) {
   return request2({
     url: api + `/organizationCourseUnitPriceSettings/save`,
-    method: 'post',
+    method: "post",
     data
-  })
+  });
 }
 
 // 修改课程费用
-export function resetOrganizationCourseUnitPrice (data) {
+export function resetOrganizationCourseUnitPrice(data) {
   return request2({
     url: api + `/organizationCourseUnitPriceSettings/update`,
-    method: 'post',
+    method: "post",
     data
-  })
+  });
 }
 
 // 删除课程费用
-export function deleteOrganizationCourseUnitPrice (data) {
+export function deleteOrganizationCourseUnitPrice(data) {
   return request2({
     url: api + `/organizationCourseUnitPriceSettings/del`,
-    method: 'post',
+    method: "post",
     data
-  })
+  });
 }
 
 // 查询课程时长
 export function getOrganizationCourseDurationSettings(data) {
   return request2({
     url: api + `/organizationCourseDurationSettings/queryPage`,
-    method: 'get',
-    data:{},
-    params: data,
-  })
+    method: "get",
+    data: {},
+    params: data
+  });
 }
 
 // 修改课程时长
 export function resetOrganizationCourseDurationSettings(data) {
   return request2({
     url: api + `/organizationCourseDurationSettings/update`,
-    method: 'post',
-    params:data,
-  })
+    method: "post",
+    params: data
+  });
 }
 
 // 新增课程时长
 export function addOrganizationCourseDurationSettings(data) {
   return request2({
     url: api + `/organizationCourseDurationSettings/insert`,
-    method: 'post',
-    params:data,
-  })
+    method: "post",
+    params: data
+  });
 }
 
 //删除课程时长
 export function delOrganizationCourseDurationSettings(data) {
   return request2({
     url: api + `/organizationCourseDurationSettings/del`,
-    method: 'post',
-    data:data,
-  })
+    method: "post",
+    data: data
+  });
 }
 
 export function organizationCloudTeacherFeeQueryPage(data) {
   return request2({
     url: api + `/organizationCloudTeacherFee/queryPage`,
-    method: 'get',
-    params: data,
-  })
+    method: "get",
+    params: data
+  });
 }
 
 //新增分部配置
 export function organizationCloudTeacherFeeAdd(data) {
   return request2({
     url: api + `/organizationCloudTeacherFee/add`,
-    method: 'post',
+    method: "post",
     requestType: "form",
-    data:data,
-  })
+    data: data
+  });
 }
 
 //修改分部配置
 export function organizationCloudTeacherFeeUpdate(data) {
   return request2({
     url: api + `/organizationCloudTeacherFee/update`,
-    method: 'post',
+    method: "post",
     requestType: "form",
-    data:data,
-  })
+    data: data
+  });
 }
 
-export function querySingle(data,data1) {
+export function querySingle(data, data1) {
   return request2({
-    url: api + `/organizationCourseUnitPriceSettings/querySingle/${data}/${data1}`,
-    method: 'get',
-  })
+    url:
+      api + `/organizationCourseUnitPriceSettings/querySingle/${data}/${data1}`,
+    method: "get"
+  });
 }

+ 8 - 5
src/constant/index.js

@@ -306,7 +306,7 @@ export const downListType = {
   20: "云教练统计导出",
   21: "班级列表导出",
   22: "云教练统计详情导出",
-  23:"老师云教练使用数据"
+  23: "老师云教练使用数据"
 };
 
 export const withdrawalStatus = {
@@ -332,11 +332,14 @@ export const vipResetType = {
   "2": "线下不可调为线上",
   "3": "线上线下不可互调"
 };
-//   1: 'AMR收费',
+// COURSE_FEE(0, "课程收费", 2),
+//   AMR(1, "器乐练习系统", 3),
+//   MEMBER_FEE(2, "会员收费", 4),
+//   FREE(3, "免费", 4);
 export const courseViewType = {
-  'COURSE_FEE': "课程收费",
-'MEMBER_FEE': "会员收费",
-  'FREE':"免费"
+  0: "课程收费",
+  2: "会员收费",
+  3: "免费"
 };
 
 export const couponType = {

+ 3 - 4
src/router/index.js

@@ -635,9 +635,8 @@ export const asyncRoutes = {
   // 训练详情
   exerciseDurationDetail: () =>
     import("@/views/main/cloudDate/exerciseDurationDetail.vue"),
-    // 新课表列表
-    newCourseList:()=>import("@/views/newCourseList"),
-    newOrderList:()=>import("@/views/newCourseList/orderList"),
-
+  // 新课表列表
+  newCourseList: () => import("@/views/newCourseList"),
+  newOrderList: () => import("@/views/newCourseList/orderList")
 };
 export default router;

+ 16 - 2
src/utils/searchArray.js

@@ -643,7 +643,7 @@ export const visitChiose1 = [
     children: [
       {
         value: "续费类回访",
-        label: "续费类回访" 
+        label: "续费类回访"
       },
       {
         value: "服务回访",
@@ -839,7 +839,21 @@ export const vipResetTypeList = [
 ];
 export const musicGroupStatus = getValueForKey(musicGroupType);
 export const classTimeList = getValueForKey(classTime);
-export const courseViewTypeList = getValueForKey(courseViewType);
+export const courseViewTypeList = [
+  {
+    label: "课程收费",
+    value: 0
+  },
+  {
+    label: "会员收费",
+    value: 2
+  },
+  {
+    label: "免费",
+    value: 3
+  }
+];
+
 export const payOrderTypeList = getValueForKey(payOrderType);
 export const auditTypeList = getValueForKey(auditType);
 export const auditPaymentTypeList = getValueForKey(auditPaymentType);

+ 87 - 80
src/utils/validate.js

@@ -3,154 +3,161 @@
  * @returns {Boolean}
  */
 export function isExternal(path) {
-  return /^(https?:|mailto:|tel:)/.test(path)
+  return /^(https?:|mailto:|tel:)/.test(path);
 }
 
-
 /**
  * @param {string} str
  * @returns {Boolean}
  */
 export function validUsername(str) {
-  const valid_map = ['admin', 'editor']
-  return valid_map.indexOf(str.trim()) >= 0
+  const valid_map = ["admin", "editor"];
+  return valid_map.indexOf(str.trim()) >= 0;
 }
 
 // 手机号验证
 export function isvalidPhone(str) {
-  const reg = /^1[3|4|5|6|7|8|9][0-9]\d{8}$/
-  return reg.test(str)
+  const reg = /^1[3|4|5|6|7|8|9][0-9]\d{8}$/;
+  return reg.test(str);
 }
 
 // 学生地址
 export function vaildStudentUrl() {
-  let url = window.location.href
-  let returnUrl = ''
-  if (/online/.test(url)) { //线上
-    returnUrl = 'https://mstuonline.dayaedu.com'
-  } else if (/dev/.test(url)) { // dev 环境
-    returnUrl = 'http://mstudev.dayaedu.com'
-  } else if (/test/.test(url)) { // dev 环境
-    returnUrl = 'http://mstutest.dayaedu.com'
-  } else { // 默认dev环境
-    returnUrl = 'http://mstudev.dayaedu.com'
+  let url = window.location.href;
+  let returnUrl = "";
+  if (/online/.test(url)) {
+    //线上
+    returnUrl = "https://mstuonline.dayaedu.com";
+  } else if (/dev/.test(url)) {
+    // dev 环境
+    returnUrl = "http://mstudev.dayaedu.com";
+  } else if (/test/.test(url)) {
+    // dev 环境
+    returnUrl = "http://mstutest.dayaedu.com";
+  } else {
+    // 默认dev环境
+    returnUrl = "http://mstutest.dayaedu.com";
   }
-  return returnUrl
+  return returnUrl;
 }
 
 // 老师地址
 export function vaildTeacherUrl() {
-  let url = window.location.href
-  let returnUrl = ''
-  if (/online/.test(url)) { //线上
-    returnUrl = 'https://mteaonline.dayaedu.com'
-  } else if (/dev/.test(url)) { // dev 环境
-    returnUrl = 'http://mteadev.dayaedu.com'
-  } else if (/test/.test(url)) { // dev 环境
-    returnUrl = 'http://mteatest.dayaedu.com'
-  } else { // 默认dev环境
-    returnUrl = 'https://mteatest.dayaedu.com'
+  let url = window.location.href;
+  let returnUrl = "";
+  if (/online/.test(url)) {
+    //线上
+    returnUrl = "https://mteaonline.dayaedu.com";
+  } else if (/dev/.test(url)) {
+    // dev 环境
+    returnUrl = "http://mteadev.dayaedu.com";
+  } else if (/test/.test(url)) {
+    // dev 环境
+    returnUrl = "http://mteatest.dayaedu.com";
+  } else {
+    // 默认dev环境
+    returnUrl = "https://mteatest.dayaedu.com";
   }
-  return returnUrl
+  return returnUrl;
 }
 
 // 教务地址
 export function vaildTeachingUrl() {
-  let url = window.location.href
-  let returnUrl = ''
-  if (/online/.test(url)) { //线上
-    returnUrl = 'https://manonline.dayaedu.com'
-  } else if (/dev/.test(url)) { // dev 环境
-    returnUrl = 'http://mandev.dayaedu.com'
-  } else if (/test/.test(url)) { // dev 环境
-    returnUrl = 'http://mantest.dayaedu.com'
-  } else { // 默认dev环境
-    returnUrl = 'http://mandev.dayaedu.com'
+  let url = window.location.href;
+  let returnUrl = "";
+  if (/online/.test(url)) {
+    //线上
+    returnUrl = "https://manonline.dayaedu.com";
+  } else if (/dev/.test(url)) {
+    // dev 环境
+    returnUrl = "http://mandev.dayaedu.com";
+  } else if (/test/.test(url)) {
+    // dev 环境
+    returnUrl = "http://mantest.dayaedu.com";
+  } else {
+    // 默认dev环境
+    returnUrl = "http://mantest.dayaedu.com";
   }
-  return returnUrl
+  return returnUrl;
 }
 
 // OA地址
 export function validOaUrl() {
-  let url = window.location.href
-  let returnUrl = ''
-  if (/online/.test(url)) { //线上
-    returnUrl = 'https://oaonline.dayaedu.com'
-  } else if (/dev/.test(url)) { // dev 环境
-    returnUrl = 'http://oadev.dayaedu.com'
-  } else if (/test/.test(url)) { // dev 环境
-    returnUrl = 'https://oatest.dayaedu.com'
-  } else { // 默认dev环境
-    returnUrl = 'http://oadev.dayaedu.com'
+  let url = window.location.href;
+  let returnUrl = "";
+  if (/online/.test(url)) {
+    //线上
+    returnUrl = "https://oaonline.dayaedu.com";
+  } else if (/dev/.test(url)) {
+    // dev 环境
+    returnUrl = "http://oadev.dayaedu.com";
+  } else if (/test/.test(url)) {
+    // dev 环境
+    returnUrl = "https://oatest.dayaedu.com";
+  } else {
+    // 默认dev环境
+    returnUrl = "http://oatest.dayaedu.com";
   }
-  return returnUrl
+  return returnUrl;
 }
 
 // 商城地址
 export function validMallUrl() {
-  let url = window.location.href
-  let returnUrl = ''
-  if (/online/.test(url)) { //线上
-    returnUrl = 'https://online.dayaedu.com/mall/'
-  } else if (/dev/.test(url)) { // dev 环境
-    returnUrl = 'https://dev.dayaedu.com/mall/'
-  } else if (/test/.test(url)) { // dev 环境
-    returnUrl = 'https://test.dayaedu.com/mall/'
-  } else { // 默认dev环境
-    returnUrl = 'https://test.dayaedu.com/mall/'
+  let url = window.location.href;
+  let returnUrl = "";
+  if (/online/.test(url)) {
+    //线上
+    returnUrl = "https://online.dayaedu.com/mall/";
+  } else if (/dev/.test(url)) {
+    // dev 环境
+    returnUrl = "https://dev.dayaedu.com/mall/";
+  } else if (/test/.test(url)) {
+    // dev 环境
+    returnUrl = "https://test.dayaedu.com/mall/";
+  } else {
+    // 默认dev环境
+    returnUrl = "https://test.dayaedu.com/mall/";
   }
-  return returnUrl
+  return returnUrl;
 }
-export function nextMonthLastDay(year, month) { //日期显示为次月最后一天
+export function nextMonthLastDay(year, month) {
+  //日期显示为次月最后一天
   // var time = date ? new Date(date) : new Date();
   // var year = time.getFullYear();
   // //var year = 1900; //用于测试
   // var month = time.getMonth() + 2;
   if (month > 12) {
-
     month = month - 12;
 
     year = year + 1;
-
   }
 
   var day = nextMonthDay(year, month);
 
   return [year, month, day];
-
 }
 
-function nextMonthDay(year, month) { //判断每月多少天
+function nextMonthDay(year, month) {
+  //判断每月多少天
 
   var day31 = [1, 3, 5, 7, 8, 10, 12];
 
   var day30 = [4, 6, 9, 11];
 
   if (day31.indexOf(month) > -1) {
-
     return 31;
-
   } else if (day30.indexOf(month) > -1) {
-
     return 30;
-
   } else {
-
     if (isLeapYear(year)) {
-
       return 29;
-
     } else {
-
       return 28;
-
     }
-
   }
-
 }
 
-function isLeapYear(year) { //判断是否为闰年
-  return (year % 4 == 0) && (year % 100 != 0 || year % 400 == 0);
-
+function isLeapYear(year) {
+  //判断是否为闰年
+  return year % 4 == 0 && (year % 100 != 0 || year % 400 == 0);
 }

+ 21 - 11
src/views/baseRulesClassSetting/index.vue

@@ -7,7 +7,12 @@
     <div class="m-core">
       <!-- navMenu -->
       <tab-router v-model.trim="activeIndex" @tab-click="handleClick">
-        <el-tab-pane label="乐团收费标准" lazy name="3" v-if="permissionList.chargesList">
+        <el-tab-pane
+          label="乐团收费标准"
+          lazy
+          name="3"
+          v-if="permissionList.chargesList"
+        >
           <chargesList v-if="activeIndex == 3" />
         </el-tab-pane>
         <el-tab-pane
@@ -18,14 +23,14 @@
         >
           <courseTimerSetting v-if="activeIndex == 1" />
         </el-tab-pane>
-        <el-tab-pane
+        <!-- <el-tab-pane
           label="乐团收费类型设置"
           lazy
           name="6"
           v-if="permissionList.typesManager"
         >
           <typesManager v-if="activeIndex == 6" />
-        </el-tab-pane>
+        </el-tab-pane> -->
         <el-tab-pane
           label="商品折扣&声部设置"
           lazy
@@ -43,7 +48,12 @@
           <musicCourseFee v-if="activeIndex == 2" />
         </el-tab-pane>
 
-        <el-tab-pane label="VIP课设置" lazy name="4" v-if="permissionList.vipCourseType">
+        <el-tab-pane
+          label="VIP课设置"
+          lazy
+          name="4"
+          v-if="permissionList.vipCourseType"
+        >
           <vipCourseType v-if="activeIndex == '4'" />
         </el-tab-pane>
         <el-tab-pane
@@ -69,7 +79,7 @@
 <script>
 import courseTimerSetting from "@/views/categroyManager/specialSetup/courseTimerSetting";
 import musicCourseFee from "@/views/categroyManager/specialSetup/musicCourseFee";
-import typesManager from "@/views/categroyManager//specialSetup/typesManager";
+import typesManager from "@/views/categroyManager/specialSetup/typesManager";
 import chargesList from "@/views/categroyManager/specialSetup/chargesList";
 import vipCourseType from "@/views/categroyManager/generalSettings/vipCourseType";
 import discountManage from "@/views/categroyManager/specialSetup/discountManage";
@@ -87,7 +97,7 @@ export default {
     typesManager,
     discountManage,
     vipChargeSeting,
-    practiceRules,
+    practiceRules
   },
   name: "baseRulersManager",
   data() {
@@ -101,8 +111,8 @@ export default {
         typesManager: permission("/globalConfig/typesManager"),
         discountManage: permission("/specialSetup/discountManage"),
         vipChargeSeting: permission("/vipChargeSeting"),
-        practiceRules: permission("/practiceRules"),
-      },
+        practiceRules: permission("/practiceRules")
+      }
     };
   },
   mounted() {
@@ -111,15 +121,15 @@ export default {
   methods: {
     handleClick(val) {
       this.activeIndex = val.name;
-    },
+    }
   },
   watch: {
     "$route.query"(val) {
       if (val.tabrouter) {
         this.handleClick(val.tabrouter);
       }
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss" scoped>

+ 26 - 62
src/views/categroyManager/specialSetup/chargesList.vue

@@ -27,8 +27,8 @@
         </el-form-item>
         <el-form-item>
           <el-select
-            placeholder="收费类型"
-            v-model="searchForm.chargeTypeId"
+            placeholder="收费模式"
+            v-model="searchForm.courseViewType"
             clearable
             filterable
           >
@@ -64,7 +64,7 @@
               {{ scope.row.organName }}
             </template>
           </el-table-column>
-          <el-table-column prop="chargeTypeId" label="乐团模式">
+          <el-table-column prop="courseViewType" label="收费模式">
             <template slot-scope="scope">
               {{ scope.row.courseViewType | courseViewType }}
             </template>
@@ -76,7 +76,10 @@
                 现价(元)
                 <el-tooltip placement="top" popper-class="mTooltip">
                   <div slot="content">学生实际缴费金额</div>
-                  <i class="el-icon-question" style="font-size: 18px; color: #f56c6c"></i>
+                  <i
+                    class="el-icon-question"
+                    style="font-size: 18px; color: #f56c6c"
+                  ></i>
                 </el-tooltip>
               </p>
             </template>
@@ -89,7 +92,8 @@
               {{ numeral(scope.row.totalOriginalPrice).format("0,0") }}
             </template>
           </el-table-column>
-          <el-table-column prop="updateTime" label="修改时间"> </el-table-column>
+          <el-table-column prop="updateTime" label="修改时间">
+          </el-table-column>
           <el-table-column align="center" label="操作">
             <template slot-scope="scope">
               <el-button
@@ -152,7 +156,7 @@ import {
   chargeTypeOrganizationFeeUpdate,
   chargeTypeOrganizationFee,
   branchQueryPage,
-  musicGroupOrganizationCourseSettingsQueryPage,
+  musicGroupOrganizationCourseSettingsQueryPage
 } from "@/api/specialSetting";
 import { getType } from "@/api/buildTeam";
 import chargesForm from "./modals/chargesForm";
@@ -163,7 +167,7 @@ export default {
   components: {
     pagination,
     chargesForm,
-    emptyPage,
+    emptyPage
   },
   name: "chargesList",
   data() {
@@ -178,34 +182,24 @@ export default {
       formActionTitle: "create",
       formTitle: {
         create: "添加乐团收费标准",
-        update: "修改乐团收费标准",
+        update: "修改乐团收费标准"
       },
       searchForm: {
         organId: null,
-        chargeTypeId: null,
+        courseViewType: null
       },
       chargeStatus: false,
-      formLabelWidth: "100px",
-      form: {
-        chargeTypeId: null,
-        courseFee: null,
-      },
-      rules: {
-        courseFee: [{ required: true, message: "请输入课程费用", trigger: "blur" }],
-        chargeTypeId: [{ required: true, message: "请选择收费类型", trigger: "change" }],
-        organId: [{ required: true, message: "请选择所属分部", trigger: "change" }],
-      },
       pageInfo: {
         // 分页规则
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50], // 选择限制显示条数
+        page_size: [10, 20, 40, 50] // 选择限制显示条数
       },
       context:
         "此处用于设置乐团训练的标准课程组合包,可根据不同分部不同的乐团模式创建不同的课程组合包及组合包的标准价格,创建完成后,在设置乐团报名、续费时可直接选择收费标准快速创建乐团课程缴费。",
       contextFlag: false,
-      courseViewTypeList,
+      courseViewTypeList
     };
   },
   async mounted() {
@@ -236,15 +230,15 @@ export default {
     // 分部列表
     branchQueryPage({
       rows: 9999,
-      page: 1,
-    }).then((res) => {
+      page: 1
+    }).then(res => {
       if (res.code == 200) {
         const branchById = {};
-        this.branchList = res.data.rows.map((item) => {
+        this.branchList = res.data.rows.map(item => {
           branchById[item.id] = item.name;
           return {
             label: item.name,
-            value: item.id,
+            value: item.id
           };
         });
         this.branchById = branchById;
@@ -260,32 +254,10 @@ export default {
     onReSet() {
       this.searchForm = {
         organId: null,
-        chargeTypeId: null,
+        courseViewType: null
       };
       this.search();
     },
-    onTypesSubmit(formName) {
-      // 添加数据
-      this.$refs[formName].validate((valid) => {
-        if (valid) {
-          if (this.formActionTitle == "create") {
-            if (this.form.id) {
-              // 判断有没有Id,如果有则删除
-              delete this.form.id;
-            }
-            chargeTypeOrganizationFeeAdd(this.form).then((res) => {
-              this.messageTips("添加", res);
-            });
-          } else if (this.formActionTitle == "update") {
-            chargeTypeOrganizationFeeUpdate(this.form).then((res) => {
-              this.messageTips("修改", res);
-            });
-          }
-        } else {
-          return false;
-        }
-      });
-    },
     messageTips(title, res) {
       if (res.code == 200) {
         this.$message.success(title + "成功");
@@ -309,10 +281,10 @@ export default {
       this.$confirm("您确定删除该收费标准?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
-          musicGroupOrganizationCourseSettingsDel({ id: row.id }).then((res) => {
+          musicGroupOrganizationCourseSettingsDel({ id: row.id }).then(res => {
             this.messageTips("删除", res);
           });
         })
@@ -322,8 +294,8 @@ export default {
       musicGroupOrganizationCourseSettingsQueryPage({
         rows: this.pageInfo.limit,
         page: this.pageInfo.page,
-        ...this.searchForm,
-      }).then((res) => {
+        ...this.searchForm
+      }).then(res => {
         if (res.code == 200) {
           this.contextFlag = true;
           this.dataList = res.data.rows;
@@ -331,18 +303,10 @@ export default {
         }
       });
     },
-    onFormClose(formName) {
-      // 关闭弹窗重置验证
-      this.form = {
-        courseFee: null,
-        chargeTypeId: null,
-      };
-      this.$refs[formName].resetFields();
-    },
     closeModal() {
       this.chargeStatus = false;
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss" scoped>

+ 304 - 249
src/views/categroyManager/specialSetup/discountManage.vue

@@ -2,38 +2,48 @@
   <div>
     <!-- <h2>折扣设置</h2> -->
     <div>
-      <save-form :inline="true"
-
-               @submit="search"
-               @reset="onReSet"
-               :saveKey="'discountManage'"
-               :model="searchForm">
+      <save-form
+        :inline="true"
+        @submit="search"
+        @reset="onReSet"
+        :saveKey="'discountManage'"
+        :model="searchForm"
+      >
         <el-form-item>
-          <el-select v-model.trim="searchForm.subjectId"
-                     filterable
-                     placeholder="请选择声部组合"
-                     clearable>
-            <el-option-group v-for="group in subjectList"
-                             :key="group.id"
-                             :label="group.label">
-              <el-option v-for="item in group.options"
-                         :key="item.value"
-                         :label="item.label"
-                         :value="item.value">
+          <el-select
+            v-model.trim="searchForm.subjectId"
+            filterable
+            placeholder="请选择声部组合"
+            clearable
+          >
+            <el-option-group
+              v-for="group in subjectList"
+              :key="group.id"
+              :label="group.label"
+            >
+              <el-option
+                v-for="item in group.options"
+                :key="item.value"
+                :label="item.label"
+                :value="item.value"
+              >
               </el-option>
             </el-option-group>
           </el-select>
         </el-form-item>
         <el-form-item>
-          <el-select v-model.trim="searchForm.chargeTypeId"
-                     filterable
-                     placeholder="请选择收费类型"
-                     clearable>
-            <el-option v-for="item in typesList"
-                       :key="item.value"
-                       :label="item.label"
-                       :value="item.value">
-            </el-option>
+          <el-select
+            placeholder="收费模式"
+            v-model="searchForm.courseViewType"
+            clearable
+            filterable
+          >
+            <el-option
+              v-for="(item, index) in courseViewTypeList"
+              :label="item.label"
+              :value="item.value"
+              :key="index"
+            ></el-option>
           </el-select>
         </el-form-item>
 
@@ -43,165 +53,209 @@
         </el-form-item>
       </save-form>
       <el-button
-       type="primary"
-
-       style="margin-bottom:20px;"
-           v-permission="'chargeTypeSubjectMapper/insert'"
-           @click="createVisible = true">添加</el-button>
+        type="primary"
+        style="margin-bottom:20px;"
+        v-permission="'chargeTypeSubjectMapper/insert'"
+        @click="createVisible = true"
+        >添加</el-button
+      >
       <!-- 列表 -->
       <div class="tableWrap">
-        <el-table :data='tableList'
-
-                  :header-cell-style="{background:'#EDEEF0',color:'#444'}">
-          <el-table-column align='center'
-                           prop="chargeTypeId"
-                           label="收费类型">
-            <template slot-scope="scope">{{ typesListById[scope.row.chargeTypeId] }}</template>
+        <el-table
+          :data="tableList"
+          :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
+        >
+          <el-table-column
+            align="center"
+            prop="courseViewType"
+            label="收费模式"
+          >
+            <template slot-scope="scope">{{
+              scope.row.courseViewType | courseViewType
+            }}</template>
           </el-table-column>
-          <el-table-column align='center'
-                           prop="subjectId"
-                           label="声部">
-            <template slot-scope="scope">{{ subjectListById[scope.row.subjectId] }}</template>
+          <el-table-column align="center" prop="subjectId" label="声部">
+            <template slot-scope="scope">{{
+              subjectListById[scope.row.subjectId]
+            }}</template>
           </el-table-column>
-          <el-table-column align='center'
-                           prop="goodsDiscountRate"
-                           label="折扣(%)">
+          <el-table-column
+            align="center"
+            prop="goodsDiscountRate"
+            label="折扣(%)"
+          >
           </el-table-column>
-          <el-table-column align='center'
-                           prop="fee"
-                           label="经营报表确认收入(元)">
+          <el-table-column
+            align="center"
+            prop="fee"
+            label="经营报表确认收入(元)"
+          >
           </el-table-column>
-          <el-table-column align='center'
-                           label="操作">
+          <el-table-column align="center" label="操作">
             <template slot-scope="scope">
-              <el-button @click="openTypes('update', scope.row)"
-                         v-permission="'chargeTypeSubjectMapper/update'"
-                         type="text">修改</el-button>
+              <el-button
+                @click="openTypes('update', scope.row)"
+                v-permission="'chargeTypeSubjectMapper/update'"
+                type="text"
+                >修改</el-button
+              >
               <!-- <el-button @click="onTypesDel(scope.row)"
                          v-permission="'chargeTypeSubjectMapper/del'"
                          type="text">删除</el-button> -->
             </template>
           </el-table-column>
         </el-table>
-        <pagination sync
-         :saveKey="'discountManage'"
-        :total.sync="pageInfo.total"
-                    :page.sync="pageInfo.page"
-                    :limit.sync="pageInfo.limit"
-                    :page-sizes="pageInfo.page_size"
-                    @pagination="getList" />
+        <pagination
+          sync
+          :saveKey="'discountManage'"
+          :total.sync="pageInfo.total"
+          :page.sync="pageInfo.page"
+          :limit.sync="pageInfo.limit"
+          :page-sizes="pageInfo.page_size"
+          @pagination="getList"
+        />
       </div>
     </div>
-    <el-dialog :title="formTitle[formActionTitle]"
-               :visible.sync="typeStatus"
-               @close="onFormClose('ruleForm')"
-               width="500px">
-      <el-form :model="form"
-               :rules="rules"
-               label-width="220px"
-               ref="ruleForm">
-        <el-form-item label="收费类型"
-                      prop="chargeTypeId"
-                      :label-width="formLabelWidth">
-          <el-select v-model.trim="form.chargeTypeId"
-                     filterable
-                     disabled
-                     placeholder="请选择收费类型"
-                     clearable>
-            <el-option v-for="item in typesList"
-                       :key="item.value"
-                       :label="item.label"
-                       :value="item.value">
-            </el-option>
+    <el-dialog
+      :title="formTitle[formActionTitle]"
+      :visible.sync="typeStatus"
+      @close="onFormClose('ruleForm')"
+      width="500px"
+    >
+      <el-form :model="form" :rules="rules" label-width="220px" ref="ruleForm">
+        <el-form-item
+          label="收费模式"
+          prop="courseViewType"
+          :label-width="formLabelWidth"
+        >
+          <el-select
+            placeholder="收费模式"
+            v-model="form.courseViewType"
+            clearable
+            filterable
+          >
+            <el-option
+              v-for="(item, index) in courseViewTypeList"
+              :label="item.label"
+              :value="item.value"
+              :key="index"
+            ></el-option>
           </el-select>
         </el-form-item>
-        <el-form-item label="声部选择"
-                      v-if="form.classGroupType != 'MIX'"
-                      prop="subjectId"
-                      :label-width="formLabelWidth">
-          <el-select v-model.trim="form.subjectId"
-                     filterable
-                      disabled
-                     placeholder="请选择声部组合"
-                     clearable>
-            <el-option-group v-for="group in subjectList"
-                             :key="group.id"
-                             :label="group.label">
-              <el-option v-for="item in group.options"
-                         :key="item.value"
-                         :label="item.label"
-                         :value="item.value">
+        <el-form-item
+          label="声部选择"
+          v-if="form.classGroupType != 'MIX'"
+          prop="subjectId"
+          :label-width="formLabelWidth"
+        >
+          <el-select
+            v-model.trim="form.subjectId"
+            filterable
+            disabled
+            placeholder="请选择声部组合"
+            clearable
+          >
+            <el-option-group
+              v-for="group in subjectList"
+              :key="group.id"
+              :label="group.label"
+            >
+              <el-option
+                v-for="item in group.options"
+                :key="item.value"
+                :label="item.label"
+                :value="item.value"
+              >
               </el-option>
             </el-option-group>
           </el-select>
         </el-form-item>
-        <el-form-item label="乐器折扣(%)"
-                      prop="goodsDiscountRate"
-                      :label-width="formLabelWidth">
-          <el-input v-model.trim="form.goodsDiscountRate"
-                    autocomplete="off"
-                    type="number"
-                    placeholder="请输入折扣 0%-100%"
-                    controls-position="right"
-                    class="number-input"
-                    min="0"
-                    max="100"></el-input>
+        <el-form-item
+          label="乐器折扣(%)"
+          prop="goodsDiscountRate"
+          :label-width="formLabelWidth"
+        >
+          <el-input
+            v-model.trim="form.goodsDiscountRate"
+            autocomplete="off"
+            type="number"
+            placeholder="请输入折扣 0%-100%"
+            controls-position="right"
+            class="number-input"
+            min="0"
+            max="100"
+          ></el-input>
         </el-form-item>
-        <el-form-item label="经营报表确认收入(元)"
-                      prop="fee"
-                      :label-width="formLabelWidth">
-          <el-input v-model.trim="form.fee"
-                    autocomplete="off"
-                    type="number"
-                    placeholder="请输入折扣 0%-100%"
-                    controls-position="right"
-                    class="number-input"
-                    min="0"
-                    max="100"></el-input>
+        <el-form-item
+          label="经营报表确认收入(元)"
+          prop="fee"
+          :label-width="formLabelWidth"
+        >
+          <el-input
+            v-model.trim="form.fee"
+            autocomplete="off"
+            type="number"
+            placeholder="请输入折扣 0%-100%"
+            controls-position="right"
+            class="number-input"
+            min="0"
+            max="100"
+          ></el-input>
         </el-form-item>
       </el-form>
-      <span slot="footer"
-            class="dialog-footer">
+      <span slot="footer" class="dialog-footer">
         <el-button @click="typeStatus = false">取 消</el-button>
-        <el-button type="primary"
-                   @click="onTypesSubmit('ruleForm')">确 定</el-button>
+        <el-button type="primary" @click="onTypesSubmit('ruleForm')"
+          >确 定</el-button
+        >
       </span>
     </el-dialog>
-    <el-dialog class="dialog" :visible.sync="createVisible"
-               title="添加商品折扣"
-               top="10vh"
-               width="500px">
-      <createDiscount @close="createVisible = false"
-                      @submited="getList"
-                      :typesList="typesList"
-                      :subjectList="subjectList" />
+    <el-dialog
+      class="dialog"
+      :visible.sync="createVisible"
+      title="添加商品折扣"
+      top="10vh"
+      width="500px"
+    >
+      <createDiscount
+        @close="createVisible = false"
+        @submited="getList"
+        :subjectList="subjectList"
+      />
     </el-dialog>
   </div>
 </template>
 <script>
-import pagination from '@/components/Pagination/index'
-import { chargeTypeList, subjectListTree, insertChargeTypeSubjectMapper, updateChargeTypeSubjectMapper, delChargeTypeSubjectMapper, chargeTypeSubjectMapper } from '@/api/specialSetting'
+import pagination from "@/components/Pagination/index";
+import {
+  chargeTypeList,
+  subjectListTree,
+  insertChargeTypeSubjectMapper,
+  updateChargeTypeSubjectMapper,
+  delChargeTypeSubjectMapper,
+  chargeTypeSubjectMapper
+} from "@/api/specialSetting";
 import { getType } from "@/api/buildTeam";
-import createDiscount from './modals/create-discount'
+import { courseViewTypeList } from "@/utils/searchArray";
+import createDiscount from "./modals/create-discount";
 export default {
-  name: 'typesManager',
+  name: "typesManager",
   components: { pagination, createDiscount },
-  data () {
+  data() {
     return {
       tableList: [],
-      typesList: [],
-      typesListById: {},
       subjectList: [], // 声部列表
       subjectListById: {}, // 声部列表
-      formActionTitle: 'create',
+      formActionTitle: "create",
       formTitle: {
-        create: '添加折扣',
-        update: '修改折扣'
+        create: "添加折扣",
+        update: "修改折扣"
       },
       createVisible: false,
       typeStatus: false, // 添加教学点
-      formLabelWidth: '120px',
+      formLabelWidth: "120px",
       form: {
+        courseViewType: null,
         name: null, //
         subjectId: null,
         goodsDiscountRate: null,
@@ -209,19 +263,33 @@ export default {
       },
       searchForm: {
         subjectId: null,
-        chargeTypeId: null,
+        courseViewType: null
       },
       rules: {
-        chargeTypeId: [{ required: true, message: '请选择收费类型', trigger: 'blur' }],
-        subjectId: [{ required: true, message: '请选择声部组合', trigger: 'change' }],
+        courseViewType: [
+          { required: true, message: "请选择收费模式", trigger: "blur" }
+        ],
+        subjectId: [
+          { required: true, message: "请选择声部组合", trigger: "change" }
+        ],
         goodsDiscountRate: [
-          { required: true, message: '请输入折扣', trigger: 'blur' },
-          { pattern: /^(\d{1,2}(\.[0-9]{1,8})?)$|^100$/, message: '请输入正确的折扣' }
+          { required: true, message: "请输入折扣", trigger: "blur" },
+          {
+            pattern: /^(\d{1,2}(\.[0-9]{1,8})?)$|^100$/,
+            message: "请输入正确的折扣"
+          }
         ],
         fee: [
-          { required: true, message: '请输入经营报表确认收入', trigger: 'blur' },
-          { pattern: /^\d{1,}(\.[0-9]{1,2})?$/, message: '请输入正确的经营报表确认收入' }
-        ],
+          {
+            required: true,
+            message: "请输入经营报表确认收入",
+            trigger: "blur"
+          },
+          {
+            pattern: /^\d{1,}(\.[0-9]{1,2})?$/,
+            message: "请输入正确的经营报表确认收入"
+          }
+        ]
       },
       pageInfo: {
         // 分页规则
@@ -229,153 +297,140 @@ export default {
         page: 1, // 当前页
         total: 0, // 总条数
         page_size: [10, 20, 40, 50] // 选择限制显示条数
-      }
-    }
+      },
+      courseViewTypeList
+    };
   },
-  mounted () {
-    this.getList()
-    this.getChargeTypeList()
-    this.getSubjectTree()
+  mounted() {
+    this.getList();
+    this.getSubjectTree();
   },
   methods: {
-    search () {
+    search() {
       this.pageInfo.page = 1;
       this.getList();
     },
-    onReSet () {
+    onReSet() {
       this.searchForm = {
         subjectId: null,
-        chargeTypeId: null,
+        courseViewType: null
       };
       this.search();
     },
-    onTypesSubmit (formName) { // 添加数据
-      this.$refs[formName].validate((valid) => {
+    onTypesSubmit(formName) {
+      // 添加数据
+      this.$refs[formName].validate(valid => {
         if (valid) {
-          if (this.formActionTitle == 'create') {
-            if (this.form.id) { // 判断有没有Id,如果有则删除
-              delete this.form.id
+          if (this.formActionTitle == "create") {
+            if (this.form.id) {
+              // 判断有没有Id,如果有则删除
+              delete this.form.id;
             }
             insertChargeTypeSubjectMapper(this.form).then(res => {
-              this.messageTips('添加', res)
-            })
-          } else if (this.formActionTitle == 'update') {
+              this.messageTips("添加", res);
+            });
+          } else if (this.formActionTitle == "update") {
             updateChargeTypeSubjectMapper([this.form]).then(res => {
-              this.messageTips('修改', res)
-            })
+              this.messageTips("修改", res);
+            });
           }
         } else {
           return false;
         }
-      })
+      });
     },
-    messageTips (title, res) {
+    messageTips(title, res) {
       if (res.code == 200) {
-        this.$message.success(title + '成功')
-        this.typeStatus = false
-        this.getList()
+        this.$message.success(title + "成功");
+        this.typeStatus = false;
+        this.getList();
       } else {
-        this.$message.error(res.msg)
+        this.$message.error(res.msg);
       }
     },
-    async onTypesDel (row) {
+    async onTypesDel(row) {
       try {
-        await this.$confirm('是否删除此条数据?', '提示', {
-          confirmButtonText: '确定',
-          cancelButtonText: '取消',
-          type: 'warning'
-        })
+        await this.$confirm("是否删除此条数据?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        });
         delChargeTypeSubjectMapper({ id: row.id }).then(res => {
-          this.messageTips('删除', res)
-        })
-      } catch (error) { }
+          this.messageTips("删除", res);
+        });
+      } catch (error) {}
     },
-    getChargeTypeList () {
-      getType({
-        rows: 9999,
-        page: 1
-      }).then(res => {
-        if (res.code == 200) {
-          const typesListById = {}
-          res.data.forEach(item => {
-            typesListById[item.id] = item.name
-            this.typesList.push({
-              label: item.name,
-              value: item.id,
-            })
-          })
-          this.typesListById = typesListById
-        }
-      })
-    },
-    getList () {
+
+    getList() {
       chargeTypeSubjectMapper({
         rows: this.pageInfo.limit,
         page: this.pageInfo.page,
         ...this.searchForm
       }).then(res => {
-        let result = res.data
-        this.tableList = result.rows
-        this.pageInfo.total = result.total
-      })
+        let result = res.data;
+        this.tableList = result.rows;
+        this.pageInfo.total = result.total;
+      });
     },
-    openTypes (type, row) {
-      this.typeStatus = true
-      this.formActionTitle = type
+    openTypes(type, row) {
+      this.typeStatus = true;
+      this.formActionTitle = type;
       // 修改的时候赋值
-      if (type == 'update') {
+      if (type == "update") {
         this.form = {
           id: row.id,
-          chargeTypeId: row.chargeTypeId,
+          courseViewType: row.courseViewType,
           subjectId: row.subjectId,
           goodsDiscountRate: row.goodsDiscountRate,
           fee: row.fee
-        }
+        };
       }
     },
-    onFormClose (formName) { // 关闭弹窗重置验证
+    onFormClose(formName) {
+      // 关闭弹窗重置验证
       this.form = {
         name: null, // 训练模块名称
         subjectId: null,
+        courseViewType: null,
         goodsDiscountRate: null,
         fee: null
-      }
-      this.$refs[formName].resetFields()
+      };
+      this.$refs[formName].resetFields();
     },
-    getSubjectTree () { // 获取声部列表
+    getSubjectTree() {
+      // 获取声部列表
       subjectListTree({
-        delFlag: 'NO',
+        delFlag: "NO",
         rows: 9999
       }).then(res => {
-        const subjectListById = {}
-        let result = res.data
+        const subjectListById = {};
+        let result = res.data;
         if (res.code == 200) {
-          let tempArray = []
+          let tempArray = [];
           result.rows.forEach((item, index) => {
-            let subject = []
+            let subject = [];
             if (item.subjects) {
               item.subjects.forEach(s => {
-                subjectListById[s.id] = s.name
+                subjectListById[s.id] = s.name;
                 subject.push({
                   value: s.id,
                   label: s.name
-                })
-              })
+                });
+              });
             }
             tempArray[index] = {
               label: item.name,
-              id:item.id,
+              id: item.id,
               options: subject
-            }
-          })
-          this.subjectListById = subjectListById
-          this.subjectList = tempArray
-
+            };
+          });
+          this.subjectListById = subjectListById;
+          this.subjectList = tempArray;
         }
-      })
+      });
     }
   }
-}
+};
 </script>
 <style lang="scss" scoped>
 ::v-deep .el-date-editor.el-input {
@@ -385,19 +440,19 @@ export default {
   width: 100% !important;
 }
 .number-input {
-  ::v-deep  .el-input__inner {
+  ::v-deep .el-input__inner {
     text-align: left;
   }
 
   width: 100%;
 }
-.dialog{
+.dialog {
   ::v-deep {
-    .el-dialog{
+    .el-dialog {
       border-radius: 4px;
       overflow: hidden;
     }
-    .el-dialog__header{
+    .el-dialog__header {
       display: flex;
       flex-shrink: 0;
       justify-content: space-between;
@@ -406,44 +461,44 @@ export default {
       width: 100%;
       height: 48px;
       padding: 0 20px;
-      .el-dialog__title{
+      .el-dialog__title {
         font-weight: 500;
         font-size: 16px;
       }
-      .el-dialog__headerbtn{
+      .el-dialog__headerbtn {
         position: relative;
         top: 0;
         right: 0;
-        &::before{
+        &::before {
           position: absolute;
           display: block;
           box-sizing: border-box;
           background-color: transparent;
           border-radius: 50%;
-          transition: background-color .1s cubic-bezier(0,0,1,1);
+          transition: background-color 0.1s cubic-bezier(0, 0, 1, 1);
           content: "";
           top: 50%;
           left: 50%;
           width: 20px;
           height: 20px;
-          transform: translate(-50%,-50%);
+          transform: translate(-50%, -50%);
         }
       }
-      .el-dialog__headerbtn:hover{
-        &::before{
-          background-color: rgba(0,0,0, .5);
+      .el-dialog__headerbtn:hover {
+        &::before {
+          background-color: rgba(0, 0, 0, 0.5);
         }
       }
-      .el-dialog__close{
+      .el-dialog__close {
         position: relative;
       }
     }
-    .el-dialog__body{
+    .el-dialog__body {
       padding: 10px 20px;
     }
-    .el-input-group__append{
+    .el-input-group__append {
       padding: 0 10px;
     }
   }
-  }
+}
 </style>

+ 69 - 42
src/views/categroyManager/specialSetup/modals/chargesForm.vue

@@ -4,7 +4,9 @@
       <el-form-item
         label="所属分部"
         prop="organId"
-        :rules="[{ required: true, message: '请选择所属分部', trigger: 'change' }]"
+        :rules="[
+          { required: true, message: '请选择所属分部', trigger: 'change' }
+        ]"
         :label-width="formLabelWidth"
       >
         <el-select
@@ -23,15 +25,17 @@
         </el-select>
       </el-form-item>
       <el-form-item
-        label="乐团模式"
+        label="收费模式"
         prop="courseViewType"
-        :rules="[{ required: true, message: '请选择乐团模式', trigger: 'change' }]"
+        :rules="[
+          { required: true, message: '请选择收费模式', trigger: 'change' }
+        ]"
         :label-width="formLabelWidth"
       >
         <el-select
           v-model.trim="form.courseViewType"
           clearable
-          placeholder="请选择乐团模式"
+          placeholder="请选择收费模式"
           filterable
         >
           <el-option
@@ -46,7 +50,9 @@
       <el-form-item
         label="收费方式名称"
         prop="name"
-        :rules="[{ required: true, message: '请输入收费方式名称', trigger: 'blur' }]"
+        :rules="[
+          { required: true, message: '请输入收费方式名称', trigger: 'blur' }
+        ]"
         :label-width="formLabelWidth"
       >
         <el-input
@@ -70,7 +76,9 @@
           <div class="item" v-for="(item, index) in form.details" :key="index">
             <el-form-item
               :prop="`details.${index}.courseType`"
-              :rules="[{ required: true, message: '请选择课程类型', trigger: 'change' }]"
+              :rules="[
+                { required: true, message: '请选择课程类型', trigger: 'change' }
+              ]"
             >
               <el-select
                 v-model.trim="item.courseType"
@@ -103,7 +111,9 @@
             </el-form-item> -->
             <el-form-item
               :prop="`details.${index}.courseTotalMinuties`"
-              :rules="[{ required: true, message: '请输入课程时长', trigger: 'blur' }]"
+              :rules="[
+                { required: true, message: '请输入课程时长', trigger: 'blur' }
+              ]"
             >
               <el-input-number
                 style="width: 90% !important"
@@ -118,7 +128,9 @@
             </el-form-item>
             <el-form-item
               :prop="`details.${index}.courseCurrentPrice`"
-              :rules="[{ required: true, message: '请输入课程现价', trigger: 'blur' }]"
+              :rules="[
+                { required: true, message: '请输入课程现价', trigger: 'blur' }
+              ]"
             >
               <el-input-number
                 style="width: 90% !important"
@@ -131,7 +143,9 @@
             </el-form-item>
             <el-form-item
               :prop="`details.${index}.courseOriginalPrice`"
-              :rules="[{ required: true, message: '请输入课程原价', trigger: 'blur' }]"
+              :rules="[
+                { required: true, message: '请输入课程原价', trigger: 'blur' }
+              ]"
             >
               <el-input-number
                 style="width: 90% !important"
@@ -162,12 +176,20 @@
       </div>
       <el-row>
         <el-col :span="6">
-          <el-form-item label="原价" prop="totalOriginalPrice" label-width="50px">
+          <el-form-item
+            label="原价"
+            prop="totalOriginalPrice"
+            label-width="50px"
+          >
             {{ totalOriginalPrice | moneyFormat }}元
           </el-form-item>
         </el-col>
         <el-col :span="6">
-          <el-form-item label="现价" prop="totalCurrentPrice" label-width="50px">
+          <el-form-item
+            label="现价"
+            prop="totalCurrentPrice"
+            label-width="50px"
+          >
             {{ totalCurrentPrice | moneyFormat }}元
           </el-form-item>
         </el-col>
@@ -180,17 +202,17 @@
   </div>
 </template>
 <script>
-const initItem = {
-  courseType: "",
-  isStudentOptional: "",
-  courseTotalMinuties: "",
-  courseOriginalPrice: "",
-  courseCurrentPrice: "",
-};
+// const initItem = {
+//   courseType: "",
+//   isStudentOptional: "",
+//   courseTotalMinuties: "",
+//   courseOriginalPrice: "",
+//   courseCurrentPrice: ""
+// };
 import {
   musicGroupOrganizationCourseSettingsAdd,
   musicGroupOrganizationCourseSettingsUpdate,
-  getOrganizationCourseUnitPriceSettings,
+  getOrganizationCourseUnitPriceSettings
 } from "@/api/specialSetting";
 import { classTimeList, array2object } from "@/utils/searchArray";
 import { queryByMusicGroupOrganizationCourseSettingsId } from "../../../resetTeaming/api";
@@ -211,9 +233,9 @@ const plusNum = (items = [], key) => {
 const initForm = {
   organId: "",
   classTimeList: "",
-  chargeTypeId: "",
+  courseViewType: "",
   name: "",
-  details: [{}],
+  details: [{}]
 };
 
 export default {
@@ -228,7 +250,7 @@ export default {
       boolOptions: objectToOptions(boolOptions),
       courseTypes: [],
       courseTypesByType: {},
-      loading: false,
+      loading: false
     };
   },
   computed: {
@@ -240,21 +262,21 @@ export default {
     },
     classTimeList() {
       return array2object(classTimeList);
-    },
+    }
   },
   watch: {
     rowDetail: {
       deep: true,
       handler() {
         this.updateForm();
-      },
+      }
     },
     async "form.organId"() {
       this.FetchOrganizationCourseUnitPriceSettings();
     },
-    async "form.chargeTypeId"() {
+    async "form.courseViewType"() {
       this.FetchOrganizationCourseUnitPriceSettings();
-    },
+    }
   },
   mounted() {
     this.updateForm();
@@ -270,8 +292,9 @@ export default {
           this.$set(this.form, "details", [{}]);
           const res = await getOrganizationCourseUnitPriceSettings({
             courseViewType: this.form.courseViewType,
+            // courseViewType: "COURSE_FEE",
             organId: this.form.organId,
-            rows: 9999,
+            rows: 9999
           });
           const d = {};
           this.courseTypes = res.data.rows;
@@ -295,7 +318,7 @@ export default {
         _list[index] = {
           ...item,
           courseCurrentPrice: price,
-          courseOriginalPrice: price,
+          courseOriginalPrice: price
         };
         this.$refs.form.validateField(`details.${index}.courseTotalMinuties`);
         this.$set(this.form, `details`, [..._list]);
@@ -303,23 +326,23 @@ export default {
     },
     async updateForm() {
       if (this.rowDetail) {
-        const { organId, classTimeList, chargeTypeId, name } = this.rowDetail;
+        const { organId, classTimeList, courseViewType, name } = this.rowDetail;
         this.form = {
           organId,
           classTimeList,
-          chargeTypeId,
-          name,
+          courseViewType,
+          name
         };
         try {
           const res = await queryByMusicGroupOrganizationCourseSettingsId({
-            id: this.rowDetail.id,
+            id: this.rowDetail.id
           });
           this.$set(
             this.form,
             "details",
-            res.data.map((item) => ({
+            res.data.map(item => ({
               ...item,
-              isStudentOptional: String(item.isStudentOptional),
+              isStudentOptional: String(item.isStudentOptional)
             }))
           );
         } catch (error) {}
@@ -328,7 +351,7 @@ export default {
       }
     },
     isOptionDisabled(key) {
-      const selected = this.form.details.map((item) => item.courseType);
+      const selected = this.form.details.map(item => item.courseType);
       return selected.includes(key);
     },
     addItem() {
@@ -338,20 +361,22 @@ export default {
     removeItem(index) {
       const _items = [...this.form.details];
       _items[index] = null;
-      this.form.details = _items.filter((item) => !!item);
+      this.form.details = _items.filter(item => !!item);
     },
     submit() {
-      this.$refs.form.validate(async (valid) => {
+      this.$refs.form.validate(async valid => {
         if (valid) {
           try {
             if (this.rowDetail) {
               const res = await musicGroupOrganizationCourseSettingsUpdate({
                 id: this.rowDetail.id,
-                ...this.form,
+                ...this.form
               });
               this.$message.success("更新成功");
             } else {
-              const res = await musicGroupOrganizationCourseSettingsAdd(this.form);
+              const res = await musicGroupOrganizationCourseSettingsAdd(
+                this.form
+              );
               this.$message.success("提交成功");
             }
             this.$listeners.close();
@@ -369,13 +394,15 @@ export default {
           this.classTimeList[courseType] &&
           value < this.classTimeList[courseType]
         ) {
-          callback(new Error(`单节课不得少于${this.classTimeList[courseType]}分钟`));
+          callback(
+            new Error(`单节课不得少于${this.classTimeList[courseType]}分钟`)
+          );
           return;
         }
         callback();
       };
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="less" scoped>

+ 126 - 118
src/views/categroyManager/specialSetup/modals/create-discount.vue

@@ -1,23 +1,30 @@
 <template>
   <div>
-    <el-form class="elForm"  label-position="top"  :model="form"
-             ref="form">
-      <el-form-item label="声部选择"
-                    prop="subjectId"
-                    :label-width="formLabelWidth"
-                    :rules="[{ required: true, message: '请选择声部', trigger: 'change' }]">
-        <el-select v-model.trim="form.subjectId"
-                   filterable
-                   style="width: 100%!important;"
-                   placeholder="请选择声部组合"
-                   clearable>
-          <el-option-group v-for="group in subjectList"
-                           :key="group.id"
-                           :label="group.label">
-            <el-option v-for="item in group.options"
-                       :key="item.value"
-                       :label="item.label"
-                       :value="item.value">
+    <el-form class="elForm" label-position="top" :model="form" ref="form">
+      <el-form-item
+        label="声部选择"
+        prop="subjectId"
+        :label-width="formLabelWidth"
+        :rules="[{ required: true, message: '请选择声部', trigger: 'change' }]"
+      >
+        <el-select
+          v-model.trim="form.subjectId"
+          filterable
+          style="width: 100%!important;"
+          placeholder="请选择声部组合"
+          clearable
+        >
+          <el-option-group
+            v-for="group in subjectList"
+            :key="group.id"
+            :label="group.label"
+          >
+            <el-option
+              v-for="item in group.options"
+              :key="item.value"
+              :label="item.label"
+              :value="item.value"
+            >
             </el-option>
           </el-option-group>
         </el-select>
@@ -26,127 +33,129 @@
       <div v-for="(item, index) in form.types" :key="index">
         <div class="lineTitle">{{ item.label }} 乐团</div>
         <div class="wrap">
-          <el-form-item label="乐器折扣"
-                        :prop="`types[${index}].goodsDiscountRate`"
-                        :label-width="formLabelWidth"
-                        :rules="[
-                          { required: true, message: '请输入折扣值', trigger: 'blur' },
-                          { pattern: /^(\d{1,2}(\.[0-9]{1,8})?)$|^100$/, message: '请输入正确的折扣' }
-                          // { pattern: /^\d+(\.\d{1,8})?$|^100$/, message: '请输入正确的折扣' }
-                        ]">
-            <el-input v-model.trim="form.types[index].goodsDiscountRate"
-                      autocomplete="off"
-                      type="number"
-                      placeholder="请输入折扣值"
-                      controls-position="right"
-                      class="number-input"
-                      min="0"
-                      max="100">
-                      <template slot="append">%</template>
-                    </el-input>
+          <el-form-item
+            label="乐器折扣"
+            :prop="`types[${index}].goodsDiscountRate`"
+            :label-width="formLabelWidth"
+            :rules="[
+              { required: true, message: '请输入折扣值', trigger: 'blur' },
+              {
+                pattern: /^(\d{1,2}(\.[0-9]{1,8})?)$|^100$/,
+                message: '请输入正确的折扣'
+              }
+              // { pattern: /^\d+(\.\d{1,8})?$|^100$/, message: '请输入正确的折扣' }
+            ]"
+          >
+            <el-input
+              v-model.trim="form.types[index].goodsDiscountRate"
+              autocomplete="off"
+              type="number"
+              placeholder="请输入折扣值"
+              controls-position="right"
+              class="number-input"
+              min="0"
+              max="100"
+            >
+              <template slot="append"
+                >%</template
+              >
+            </el-input>
           </el-form-item>
-          <el-form-item label="经营报表确认收入"
-                        :prop="`types[${index}].fee`"
-                        :label-width="formLabelWidth"
-                        :rules="[
-                          { required: true, message: '请输入经营报表确认收入', trigger: 'blur' },
-                          { pattern: /^(\d{1,}(\.[0-9]{1,2})?)$/, message: '请输入正确的经营报表确认收入' }
-                          // { pattern: /^\d+(\.\d{1,8})?$/, message: '请输入正确的折扣' }
-                        ]">
-            <el-input v-model.trim="form.types[index].fee"
-                      autocomplete="off"
-                      type="number"
-                      placeholder="请输入经营报表"
-                      controls-position="right"
-                      class="number-input"
-                      :min="0"
-                      :max="100">
-                      <template slot="append">元</template>
-                    </el-input>
+          <el-form-item
+            label="经营报表确认收入"
+            :prop="`types[${index}].fee`"
+            :label-width="formLabelWidth"
+            :rules="[
+              {
+                required: true,
+                message: '请输入经营报表确认收入',
+                trigger: 'blur'
+              },
+              {
+                pattern: /^(\d{1,}(\.[0-9]{1,2})?)$/,
+                message: '请输入正确的经营报表确认收入'
+              }
+              // { pattern: /^\d+(\.\d{1,8})?$/, message: '请输入正确的折扣' }
+            ]"
+          >
+            <el-input
+              v-model.trim="form.types[index].fee"
+              autocomplete="off"
+              type="number"
+              placeholder="请输入经营报表"
+              controls-position="right"
+              class="number-input"
+              :min="0"
+              :max="100"
+            >
+              <template slot="append"
+                >元</template
+              >
+            </el-input>
           </el-form-item>
         </div>
       </div>
-      <!-- <el-form-item v-for="item in typesList"
-                    :key="item.value"
-                    :label="item.label + '折扣(%)'"
-                    :prop="`types.${item.value}`"
-                    :label-width="formLabelWidth"
-                    :rules="[
-                      { required: true, message: '请输入折扣', trigger: 'blur' },
-                      { pattern: /^\d+(\.\d{1,8})?$/, message: '请输入正确的折扣' }
-                    ]">
-        <el-input v-model.trim="form.types[item.value]"
-                  autocomplete="off"
-                  type="number"
-                  placeholder="请输入折扣"
-                  controls-position="right"
-                  class="number-input"
-                  min="0"
-                  max="100"></el-input>
-      </el-form-item> -->
     </el-form>
-    <span slot="footer"
-          class="dialog-footer">
+    <span slot="footer" class="dialog-footer">
       <el-button @click="$listeners.close">取 消</el-button>
-      <el-button type="primary"
-                 @click="submit">确 定</el-button>
+      <el-button type="primary" @click="submit">确 定</el-button>
     </span>
   </div>
 </template>
 <script>
-import { insertChargeTypeSubjectMapper } from '@/api/specialSetting'
-import { listeners } from 'process';
+import { insertChargeTypeSubjectMapper } from "@/api/specialSetting";
+import { courseViewTypeList } from "@/utils/searchArray";
 export default {
-  props: ['typesList', 'subjectList'],
-  data () {
+  props: ["subjectList"],
+  data() {
     return {
-      formLabelWidth: '130px',
+      formLabelWidth: "130px",
       form: {
-        subjectId: '',
-        types: [],
+        subjectId: "",
+        types: []
       }
-    }
+    };
   },
   methods: {
-    submit () {
+    submit() {
       this.$refs.form.validate(async valid => {
         if (valid) {
-          const data = []
+          const data = [];
           for (const item of this.form.types) {
             data.push({
               ...item,
-              subjectId: this.form.subjectId,
-            })
+              courseViewType: item.courseViewType,
+              subjectId: this.form.subjectId
+            });
           }
           try {
-            await insertChargeTypeSubjectMapper(data)
-            this.handleInit()
-            this.$message.success('创建成功')
-            this.$listeners.submited()
-            this.$listeners.close()
-          } catch (error) { }
+            await insertChargeTypeSubjectMapper(data);
+            this.handleInit();
+            this.$message.success("创建成功");
+            this.$listeners.submited();
+            this.$listeners.close();
+          } catch (error) {}
         }
-      })
+      });
     },
 
     handleInit() {
-      this.form.types = []
-      let list = []
-      for(let i = 0; i < this.typesList.length; i++){
+      this.form.types = [];
+      let list = [];
+      for (let i = 0; i < courseViewTypeList.length; i++) {
         list.push({
-          label: this.typesList[i].label,
-          chargeTypeId: this.typesList[i].value,
-          goodsDiscountRate: '',
+          label: courseViewTypeList[i].label,
+          courseViewType: courseViewTypeList[i].value,
+          goodsDiscountRate: "",
           fee: null
-        })
+        });
       }
-      list = list.sort((a, b) => a.label - b.label)
-      this.form.types = list
-      console.log(list)
+      this.form.types = list;
     }
   },
-  mounted(){
-    this.handleInit()
+  mounted() {
+    this.form.subjectId = "";
+    this.handleInit();
   }
 };
 </script>
@@ -156,16 +165,16 @@ export default {
   text-align: right;
 }
 .number-input {
-  ::v-deep  .el-input__inner {
+  ::v-deep .el-input__inner {
     text-align: left;
   }
 
   width: 100%;
 }
 
-.elForm{
+.elForm {
   ::v-deep {
-    .el-form-item__label{
+    .el-form-item__label {
       max-width: 100%;
       color: #4e5969;
       font-size: 14px;
@@ -176,21 +185,20 @@ export default {
     }
   }
 }
-.lineTitle{
-  background-color: rgba(247,247,247,1);
+.lineTitle {
+  background-color: rgba(247, 247, 247, 1);
   padding: 10px;
   border-radius: 4px;
   color: #333;
 }
-.wrap{
+.wrap {
   display: flex;
   align-items: center;
-  ::v-deep .el-form-item:not(:last-child){
+  ::v-deep .el-form-item:not(:last-child) {
     margin-right: 20px;
-    
   }
-  .el-form-item{
-      width: 180px;
-    }
+  .el-form-item {
+    width: 180px;
+  }
 }
 </style>

+ 77 - 67
src/views/categroyManager/specialSetup/musicCourseFee.vue

@@ -69,9 +69,9 @@
               scope.row.courseType | coursesType
             }}</template>
           </el-table-column>
-          <el-table-column align="center" prop="chargeName" label="乐团收费类型">
+          <el-table-column align="center" prop="chargeName" label="收费模式">
             <template slot-scope="scope">{{
-              scope.row.chargeType.name
+              scope.row.courseViewType | courseViewType
             }}</template>
           </el-table-column>
           <el-table-column
@@ -146,7 +146,7 @@
         <el-form-item
           label="课程类型"
           :rules="[
-            { required: true, message: '请选择课程类型', trigger: 'change' },
+            { required: true, message: '请选择课程类型', trigger: 'change' }
           ]"
           prop="courseType"
           :label-width="formLabelWidth"
@@ -170,24 +170,26 @@
         </el-form-item>
         <div v-for="(item, index) in dataList" :key="index">
           <el-form-item
-            :label="`${item.name}`"
+            :label="`${item.label}`"
             :label-width="formLabelWidth"
             :rules="[
               {
                 required: true,
                 message: '请输入每分钟课程费用',
-                trigger: 'blur',
-              },
+                trigger: 'blur'
+              }
             ]"
-            :prop="`unitPriceJson.${item.id}.price`"
+            :prop="`unitPriceJson.${item.value}.price`"
           >
             <el-input
               type="number"
               min="0"
               step="0.00000001"
-              v-model="createForm.unitPriceJson[item.id].price"
+              v-model="createForm.unitPriceJson[item.value].price"
             >
-              <template slot="append">每分钟费用(元)</template>
+              <template slot="append"
+                >每分钟费用(元)</template
+              >
             </el-input>
           </el-form-item>
         </div>
@@ -228,7 +230,7 @@
         <el-form-item
           label="课程类型"
           :rules="[
-            { required: true, message: '请选择课程类型', trigger: 'blur' },
+            { required: true, message: '请选择课程类型', trigger: 'blur' }
           ]"
           prop="courseType"
           :label-width="formLabelWidth"
@@ -251,14 +253,20 @@
         </el-form-item>
         <el-form-item
           v-if="actvieRow"
-          :label="`${actvieRow.chargeType.name}模式`"
+          :label="
+            `${
+              actvieRow.courseViewType != null
+                ? courseViewType[actvieRow.courseViewType]
+                : ''
+            }模式`
+          "
           :label-width="formLabelWidth"
           :rules="[
             {
               required: true,
               message: '请输入每分钟课程费用',
-              trigger: 'blur',
-            },
+              trigger: 'blur'
+            }
           ]"
           prop="unitPrice"
         >
@@ -268,7 +276,9 @@
             step="0.00000001"
             v-model="resetForm.unitPrice"
           >
-            <template slot="append">每分钟费用(元)</template>
+            <template slot="append"
+              >每分钟费用(元)</template
+            >
           </el-input>
         </el-form-item>
       </el-form>
@@ -289,16 +299,18 @@ import {
   addOrganizationCourseUnitPrice,
   resetOrganizationCourseUnitPrice,
   deleteOrganizationCourseUnitPrice,
-  querySingle,
+  querySingle
 } from "@/api/specialSetting";
 import { getType } from "@/api/buildTeam";
 import createDiscount from "./modals/create-discount";
-import { musicCourseType } from "@/utils/searchArray";
+import { courseViewType } from "@/constant";
+import { musicCourseType, courseViewTypeList } from "@/utils/searchArray";
 export default {
   name: "typesManager",
   components: { pagination, createDiscount, emptyPage },
   data() {
     return {
+      courseViewType,
       musicCourseType,
       newVisiable: false,
       resetVisible: false,
@@ -307,55 +319,49 @@ export default {
       organList: [],
       searchForm: {
         organId: null,
-        courseScheduleType: null,
+        courseScheduleType: null
       },
       createForm: {
         organId: null,
         courseType: null,
-        unitPriceJson: {},
+        unitPriceJson: {}
       },
       resetForm: {
         unitPrice: null,
         courseType: null,
         id: null,
-        organId: null,
+        organId: null
       },
       pageInfo: {
         // 分页规则
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50], // 选择限制显示条数
+        page_size: [10, 20, 40, 50] // 选择限制显示条数
       },
       formLabelWidth: "120px",
       actvieRow: null,
       context:
         "系统支持不同分部在不同的乐团模式中设置各课程类型的不同价格标准,该标准为具体课程类型每分钟的收费价格,在创建乐团课程组合包或乐团临时加课时,根据组合包中的课程时长或临时加课的课程时长计算应该向学员收费的标准费用。不以此标准价格创建学员缴费,则需要审核才可生效。",
-      contextFlag: false,
+      contextFlag: false
     };
   },
   mounted() {
-    getType ({
-      rows: 99999,
-      page: 1,
-    }).then((res) => {
-      if (res.code == 200) {
-        this.dataList = res.data;
-        this.dataList.forEach((item) => {
-          this.$set(this.createForm.unitPriceJson, item.id, {
-            price: null,
-            id: null,
-          });
-        });
-        if (this.dataList.length <= 0) {
-          this.$bus.$emit("showguide", ["teamPayType"]);
-          return;
-        }
-      }
-    });
     // 获取分部
     this.$store.dispatch("setBranchs");
     this.getList();
+
+    this.dataList = courseViewTypeList;
+    this.dataList.forEach(item => {
+      this.$set(this.createForm.unitPriceJson, item.value, {
+        price: null,
+        id: null
+      });
+    });
+    if (this.dataList.length <= 0) {
+      this.$bus.$emit("showguide", ["teamPayType"]);
+      return;
+    }
   },
   methods: {
     search() {
@@ -372,9 +378,9 @@ export default {
         await this.$confirm("是否删除此条数据?", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
-          type: "warning",
+          type: "warning"
         });
-        delChargeTypeSubjectMapper({ id: row.id }).then((res) => {
+        delChargeTypeSubjectMapper({ id: row.id }).then(res => {
           this.messageTips("删除", res);
         });
       } catch (error) {}
@@ -385,8 +391,8 @@ export default {
         rows: this.pageInfo.limit,
         page: this.pageInfo.page,
         organId: this.searchForm.organId,
-        courseScheduleType: this.searchForm.courseScheduleType,
-      }).then((res) => {
+        courseScheduleType: this.searchForm.courseScheduleType
+      }).then(res => {
         this.contextFlag = true;
         let result = res.data;
         this.tableList = result.rows;
@@ -396,18 +402,18 @@ export default {
     },
     submitInfo() {
       console.log(this.createForm);
-      this.$refs.ruleForm.validate(async (valid) => {
+      this.$refs.ruleForm.validate(async valid => {
         const data = [];
         for (const key in this.createForm.unitPriceJson) {
           if (this.createForm.unitPriceJson.hasOwnProperty(key)) {
             const item = this.createForm.unitPriceJson[key].price;
             const id = this.createForm.unitPriceJson[key].id;
             data.push({
-              chargeTypeId: key,
+              courseViewType: Number(key),
               courseType: this.createForm.courseType,
               organId: this.createForm.organId,
               unitPrice: item,
-              id,
+              id
             });
           }
         }
@@ -420,12 +426,12 @@ export default {
             this.createForm = {
               organId: null,
               courseType: null,
-              unitPriceJson: {},
+              unitPriceJson: {}
             };
-            this.dataList.forEach((item) => {
-              this.$set(this.createForm.unitPriceJson, item.id, {
+            this.dataList.forEach(item => {
+              this.$set(this.createForm.unitPriceJson, item.value, {
                 price: null,
-                id: null,
+                id: null
               });
             });
           } catch (error) {}
@@ -435,17 +441,17 @@ export default {
     openTypes(row) {
       this.actvieRow = row;
       this.resetForm = {
-        chargeTypeId: row.chargeTypeId,
+        courseViewType: row.courseViewType,
         unitPrice: row.unitPrice,
         courseType: row.courseType,
         id: row.id,
-        organId: row.organId,
+        organId: row.organId
       };
       this.resetVisible = true;
     },
     resetSubmit() {
       // resetOrganizationCourseUnitPrice
-      this.$refs.resetForm.validate(async (valid) => {
+      this.$refs.resetForm.validate(async valid => {
         if (valid) {
           try {
             await resetOrganizationCourseUnitPrice(this.resetForm);
@@ -456,7 +462,7 @@ export default {
               unitPrice: null,
               courseType: null,
               id: null,
-              organId: null,
+              organId: null
             };
           } catch (error) {}
         }
@@ -464,21 +470,25 @@ export default {
     },
     changeCourseScheduleType(val) {
       if (val) {
-        this.$refs.ruleForm.validateField("organId", async (flag) => {
+        this.$refs.ruleForm.validateField("organId", async flag => {
           if (!flag) {
             try {
               const res = await querySingle(this.createForm.organId, val);
               //
-              res.data.forEach((item) => {
+              res.data.forEach(item => {
                 if (
                   this.createForm.unitPriceJson.hasOwnProperty(
-                    item.chargeTypeId
+                    item.courseViewType
                   )
                 ) {
-                  this.$set(this.createForm.unitPriceJson, item.chargeTypeId, {
-                    price: item.unitPrice,
-                    id: item.id,
-                  });
+                  this.$set(
+                    this.createForm.unitPriceJson,
+                    item.courseViewType,
+                    {
+                      price: item.unitPrice,
+                      id: item.id
+                    }
+                  );
                 }
               });
               this.$forceUpdate();
@@ -491,19 +501,19 @@ export default {
     },
     changeOrgan(val) {
       if (val) {
-        this.$refs.ruleForm.validateField("courseType", async (flag) => {
+        this.$refs.ruleForm.validateField("courseType", async flag => {
           if (!flag) {
             try {
               const res = querySingle(val, this.createForm.courseType);
-              res.data.forEach((item) => {
+              res.data.forEach(item => {
                 if (
                   this.createForm.unitPriceJson.hasOwnProperty(
-                    item.chargeTypeId
+                    item.courseViewType
                   )
                 ) {
                   this.$set(
                     this.createForm,
-                    unitPriceJson[item.chargeTypeId],
+                    unitPriceJson[item.courseViewType],
                     item.unitPrice
                   );
                 }
@@ -514,8 +524,8 @@ export default {
           }
         });
       }
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss" scoped>

+ 165 - 109
src/views/resetTeaming/components/payInfoDetail.vue

@@ -28,7 +28,11 @@
                     placeholder="请选择计价标准"
                   >
                     <el-option label="按学生" value="STUDENT"> </el-option>
-                    <el-option label="按老师" value="TEACHER" :disabled="!teamCourse">
+                    <el-option
+                      label="按老师"
+                      value="TEACHER"
+                      :disabled="!teamCourse"
+                    >
                     </el-option>
                   </el-select>
                 </el-form-item>
@@ -38,7 +42,7 @@
                   class="checkBtn"
                   :class="[
                     teamCourse ? 'active' : '',
-                    teamCourseDisabled ? 'disabled' : '',
+                    teamCourseDisabled ? 'disabled' : ''
                   ]"
                   @click.prevent="
                     () => {
@@ -71,7 +75,10 @@
                 </div>
                 <div
                   class="checkBtn"
-                  :class="[member ? 'active' : '', memberDisabled ? 'disabled' : '']"
+                  :class="[
+                    member ? 'active' : '',
+                    memberDisabled ? 'disabled' : ''
+                  ]"
                   @click.prevent="
                     () => {
                       if (memberDisabled) return;
@@ -96,10 +103,15 @@
                 </div>
                 <div
                   v-if="
-                    isShowLeBao && tenantId == 1 && $route.query.team_status != 'PROGRESS'
+                    isShowLeBao &&
+                      tenantId == 1 &&
+                      $route.query.team_status != 'PROGRESS'
                   "
                   class="checkBtn"
-                  :class="[leBao ? 'active' : '', leBaoDisabled ? 'disabled' : '']"
+                  :class="[
+                    leBao ? 'active' : '',
+                    leBaoDisabled ? 'disabled' : ''
+                  ]"
                   @click.prevent="
                     () => {
                       if (leBaoDisabled) return;
@@ -126,7 +138,7 @@
                   class="checkBtn"
                   :class="[
                     teamActive ? 'active' : '',
-                    teamActiveDisabled ? 'disabled' : '',
+                    teamActiveDisabled ? 'disabled' : ''
                   ]"
                   @click.prevent="
                     () => {
@@ -157,7 +169,9 @@
               <payTeamCourse
                 :form="form"
                 :charges="charges"
-                :courseUnitPriceSettingsByType="organizationCourseUnitPriceSettingsByType"
+                :courseUnitPriceSettingsByType="
+                  organizationCourseUnitPriceSettingsByType
+                "
                 v-if="teamCourse"
                 @create="addExtraClass"
                 @remove="removeExtraClass"
@@ -185,7 +199,9 @@
               />
               <paySchoolInfo
                 :form="form"
-                :courseUnitPriceSettingsByType="organizationCourseUnitPriceSettingsByType"
+                :courseUnitPriceSettingsByType="
+                  organizationCourseUnitPriceSettingsByType
+                "
                 :teamCourse="teamCourse"
                 :member="member"
                 :teamActive="teamActive"
@@ -195,7 +211,10 @@
                 @checkType="checkType"
               />
               <backMoney
-                v-if="$route.query.payUserType == 'SCHOOL' && form.currentTotalAmount > 0"
+                v-if="
+                  $route.query.payUserType == 'SCHOOL' &&
+                    form.currentTotalAmount > 0
+                "
                 :form="form"
               />
             </div>
@@ -214,8 +233,8 @@
                       {
                         required: true,
                         message: '请选择缴费时间',
-                        trigger: 'blur',
-                      },
+                        trigger: 'blur'
+                      }
                     ]"
                     ref="paymentDate"
                   >
@@ -293,8 +312,8 @@
                       {
                         required: true,
                         message: '请输入备注',
-                        trigger: 'blur',
-                      },
+                        trigger: 'blur'
+                      }
                     ]"
                     ref="memo"
                   >
@@ -333,10 +352,10 @@
           <div
             v-if="
               !teamCourse &&
-              !member &&
-              !leBao &&
-              !teamActive &&
-              $route.query.team_status == 'PROGRESS'
+                !member &&
+                !leBao &&
+                !teamActive &&
+                $route.query.team_status == 'PROGRESS'
             "
           >
             <empty desc="暂无缴费项目配置" />
@@ -397,7 +416,7 @@ import dayjs from "dayjs";
 import subjectPreview from "@/views/resetTeaming/modals/subject-preview";
 import {
   chargeTypeList,
-  musicGroupOrganizationCourseSettingsQueryPage,
+  musicGroupOrganizationCourseSettingsQueryPage
 } from "@/api/specialSetting";
 import { getSysTenantConfig } from "@/views/courseRulersManager/api";
 import { sysConfigList } from "@/api/generalSettings";
@@ -406,12 +425,12 @@ import {
   getAllmemberRank,
   musicGroupcreateCalender,
   musicGroupresetCalender,
-  getAutoActivationFlag,
+  getAutoActivationFlag
 } from "../api";
 import {
   getMusicGroupPaymentCalenderDetail,
   findMusicGroupSubjectInfo,
-  getAgreement,
+  getAgreement
 } from "@/api/buildTeam";
 import { vipGroupActivity } from "@/api/vipSeting";
 export default {
@@ -422,7 +441,7 @@ export default {
     payTeamActive,
     subjectPreview,
     paySchoolInfo,
-    backMoney,
+    backMoney
   },
   data() {
     return {
@@ -438,8 +457,8 @@ export default {
             actualAmount: "",
             memberRankSettingId: "",
             optionalFlag: null,
-            autoActivationFlag: false,
-          },
+            autoActivationFlag: false
+          }
         ],
         leBaoList: [{}],
         activeList: [{}],
@@ -453,12 +472,12 @@ export default {
         calenderFeeJson: {
           discountTotal: "",
           allTotal: "",
-          sutdentNumber: "",
+          sutdentNumber: ""
         },
         calenderFeeType: "STUDENT",
         musicGroupCalenderRefundPeriods: [{ refundDate: "", refundAmount: "" }],
         currentTotalAmount: 0,
-        contractUrl: "",
+        contractUrl: ""
       },
       teamCourse: false,
       member: false,
@@ -488,7 +507,7 @@ export default {
         minHalfYearFee: null,
         maxHalfYearFee: null,
         minYearFee: null,
-        maxYearFee: null,
+        maxYearFee: null
       },
       dialogSubjectVisible: false, // 预览
       dialogSubjectList: [],
@@ -497,7 +516,7 @@ export default {
       tenantId: null,
       isField: false,
       showAutoActivationFlag: false,
-      initDetail: false,
+      initDetail: false
     };
   },
   mounted() {
@@ -521,13 +540,19 @@ export default {
     async init() {
       this.organId = this.musicGroup?.organId;
       this.courseViewType = this.baseInfo?.musicGroup?.courseViewType;
-      if (this.courseViewType != 2 && this.$route.query.team_status == "DRAFT") {
+      if (
+        this.courseViewType != 2 &&
+        this.$route.query.team_status == "DRAFT"
+      ) {
         // 课程团的创建缴费
         this.teamCourse = true;
         // 现在课程团不在
         // this.teamCourseDisabled = true;
         this.form.paymentType = "MUSIC_APPLY";
-      } else if (this.courseViewType == 2 && this.$route.query.team_status == "DRAFT") {
+      } else if (
+        this.courseViewType == 2 &&
+        this.$route.query.team_status == "DRAFT"
+      ) {
         // 会员团的创建缴费
         this.member = true;
         this.memberDisabled = true;
@@ -559,8 +584,8 @@ export default {
         // 说明是修改  查缴项目详情
         this.initDetail = true;
         await getMusicGroupPaymentCalenderDetail({
-          id: this.$route.query.calenderId,
-        }).then((res) => {
+          id: this.$route.query.calenderId
+        }).then(res => {
           if (res.code == 200) {
             if (res.data?.calender?.musicGroupOrganizationCourseSettingId) {
               this.form.leixing = "1";
@@ -577,11 +602,15 @@ export default {
             ) {
               this.$set(this.form, "paymentDate", [
                 res.data?.calender?.startPaymentDate,
-                res.data?.calender?.deadlinePaymentDate,
+                res.data?.calender?.deadlinePaymentDate
               ]);
             }
 
-            this.$set(this.form, "contractUrl", res.data?.calender?.contractUrl);
+            this.$set(
+              this.form,
+              "contractUrl",
+              res.data?.calender?.contractUrl
+            );
             this.$set(this.form, "memo", res.data?.calender?.memo);
 
             this.$set(
@@ -592,14 +621,19 @@ export default {
             this.$set(
               this.form,
               "isShowMusicInsuranceForPay",
-              res.data?.calender?.paymentItemShowState?.isShowMusicInsuranceForPay
+              res.data?.calender?.paymentItemShowState
+                ?.isShowMusicInsuranceForPay
             );
             this.$set(
               this.form,
               "isShowVipCourseForPay",
               res.data?.calender?.paymentItemShowState?.isShowVipCourseForPay
             );
-            this.$set(this.form, "isShowSalePrice", res.data?.calender?.isShowSalePrice);
+            this.$set(
+              this.form,
+              "isShowSalePrice",
+              res.data?.calender?.isShowSalePrice
+            );
             this.$set(
               this.form,
               "isShowMusicCourseForPay",
@@ -626,7 +660,11 @@ export default {
                 this.$set(this.form, "eclass", res.data?.course);
                 console.log([...res.data?.course], "res.data?.course");
                 this.initDetail = true;
-                this.$set(this.form, "payUserType", res.data?.calender?.payUserType);
+                this.$set(
+                  this.form,
+                  "payUserType",
+                  res.data?.calender?.payUserType
+                );
 
                 this.$set(
                   this.form,
@@ -668,7 +706,7 @@ export default {
               this.teamActive = true;
 
               this.$set(this.form, "activeList", res.data.activity);
-              this.form.activeList.forEach((active) => {
+              this.form.activeList.forEach(active => {
                 active.vipGroupCategoryNames = active.categoryName;
               });
             }
@@ -686,8 +724,8 @@ export default {
         page: 1,
         status: "PROGRESS",
         activityChannel: 1,
-        enable: true,
-      }).then((res) => {
+        enable: true
+      }).then(res => {
         if (res.code == 200) {
           this.activeList = res.data.rows;
           if (this.activeList.length <= 0) {
@@ -709,9 +747,11 @@ export default {
       try {
         const res = await sysConfigList({ group: "DEFAULT" });
         const paramName = "cloud_price_range";
-        res.data.forEach((item) => {
+        res.data.forEach(item => {
           if (item.paramName == paramName) {
-            const itemValue = item.paranValue ? JSON.parse(item.paranValue) : null;
+            const itemValue = item.paranValue
+              ? JSON.parse(item.paranValue)
+              : null;
             if (itemValue) {
               this.rulesForm = itemValue;
             }
@@ -725,7 +765,7 @@ export default {
       try {
         const res = await getSysTenantConfig({ group: "MUSIC_REPAIR" });
         this.leBaoInfo = res.data;
-        res.data.forEach((element) => {
+        res.data.forEach(element => {
           if (element.id == 188) {
             this.isShowLeBao = !!element.paranValue;
           }
@@ -748,15 +788,14 @@ export default {
     },
     async getCharges() {
       const organId = this.musicGroup?.organId;
-      const chargeTypeId = this.musicGroup?.chargeTypeId;
-      this.chargeTypeName = this.musicGroup?.chargeTypeName;
+      const courseViewType = this.musicGroup?.courseViewType;
       try {
         const res = await musicGroupOrganizationCourseSettingsQueryPage({
           row: 9999,
-          chargeTypeId,
-          organId,
+          courseViewType,
+          organId
         });
-        const ids = res.data.rows.map((item) => item.id);
+        const ids = res.data.rows.map(item => item.id);
         if (!ids.includes(this.form.musicGroupOrganizationCourseSettingId)) {
           this.$set(this.form, "musicGroupOrganizationCourseSettingId", null);
         }
@@ -782,13 +821,13 @@ export default {
         this.$store.dispatch("delVisitedViews", this.$route);
         this.$router.push({
           path: "/business/resetTeaming",
-          query,
+          query
         });
       } else if (query.type == "look") {
         this.$store.dispatch("delVisitedViews", this.$route);
         this.$router.push({
           path: "/business/resetTeaming",
-          query,
+          query
         });
       } else if (
         query.type == "teamDraft" ||
@@ -798,25 +837,32 @@ export default {
         this.$store.dispatch("delVisitedViews", this.$route);
         this.$router.push({
           path: "/business/resetTeaming",
-          query,
+          query
         });
       }
     },
     formatCourse() {
       // 格式化课程类型
       const organId = this.musicGroup?.organId;
-      const chargeTypeId = this.musicGroup?.chargeTypeId;
+      const courseViewType = this.musicGroup?.courseViewType;
+      console.log(
+        this.musicGroup.courseViewType,
+        "musicGroup.courseViewType",
+        this.organizationCourseUnitPriceSettings
+      );
       const _ = {};
       const list = (this.organizationCourseUnitPriceSettings || []).filter(
-        (item) =>
+        item =>
           organId &&
           organId == item.organId &&
-          chargeTypeId &&
-          chargeTypeId == item.chargeTypeId
+          courseViewType != null &&
+          courseViewType == item.courseViewType
       );
+      console.log(list, "list");
       for (const item of list) {
         _[item.courseType] = item;
       }
+
       this.organizationCourseUnitPriceSettingsByType = _;
       return _;
     },
@@ -846,7 +892,9 @@ export default {
           if (item.isStudentOptional) {
             first += item.courseCurrentPrice;
           } else {
-            const floorMoney = Math.floor(item.courseCurrentPrice / this.cycles.length);
+            const floorMoney = Math.floor(
+              item.courseCurrentPrice / this.cycles.length
+            );
             const remainder = item.courseCurrentPrice % this.cycles.length;
             first += floorMoney + remainder;
             other += floorMoney;
@@ -874,35 +922,33 @@ export default {
       this.$set(
         this.form,
         "activeList",
-        this.form.activeList.filter((item) => !!item)
+        this.form.activeList.filter(item => !!item)
       );
     },
     removeExtraClass(index) {
       this.form.eclass[index] = null;
-      this.$set(
-        this.form,
-        "eclass",
-        this.form.eclass.filter((item) => !!item)
-      );
+      this.$set(this.form, "eclass", this.form.eclass.filter(item => !!item));
       // this.form.eclass = this.form.eclass.filter((item) => !!item);
     },
     async onPreview() {
       // 开始预览
       const musicGroupId = this.$route.query.id;
-      await findMusicGroupSubjectInfo({ musicGroupId: musicGroupId }).then((res) => {
-        if (res.code == 200) {
-          this.dialogSubjectList = res.data.musicGroupSubjectPlans;
-          // 默认预览第一个
-          if (this.dialogSubjectList.length <= 0) {
-            this.$message.error("请先设置声部信息");
-            return;
+      await findMusicGroupSubjectInfo({ musicGroupId: musicGroupId }).then(
+        res => {
+          if (res.code == 200) {
+            this.dialogSubjectList = res.data.musicGroupSubjectPlans;
+            // 默认预览第一个
+            if (this.dialogSubjectList.length <= 0) {
+              this.$message.error("请先设置声部信息");
+              return;
+            }
+            this.activeName = this.dialogSubjectList[0].subjectId.toString();
+            this.dialogSubjectVisible = true;
+          } else {
+            this.$message.warning("没有可预览的声部");
           }
-          this.activeName = this.dialogSubjectList[0].subjectId.toString();
-          this.dialogSubjectVisible = true;
-        } else {
-          this.$message.warning("没有可预览的声部");
         }
-      });
+      );
     },
     checkType() {
       this.$refs.form.validate();
@@ -918,7 +964,7 @@ export default {
               {
                 confirmButtonText: "确定",
                 cancelButtonText: "取消",
-                type: "warning",
+                type: "warning"
               }
             )
               .then(() => {
@@ -938,12 +984,12 @@ export default {
       });
     },
     onSubmit() {
-      this.$refs.form.validate(async (isok) => {
+      this.$refs.form.validate(async isok => {
         if (isok) {
           let obj = this.fommatDate();
           if (obj.payUserType == "SCHOOL") {
             let total = 0;
-            this.form.musicGroupCalenderRefundPeriods.forEach((item) => {
+            this.form.musicGroupCalenderRefundPeriods.forEach(item => {
               total += item.refundAmount * 1;
             });
             if (total != this.form.currentTotalAmount) {
@@ -964,7 +1010,7 @@ export default {
                   res.msg || `当前乐团存在未排课的缴费项目,请再次确认操作`,
                   "提示",
                   {
-                    type: "warning",
+                    type: "warning"
                   }
                 );
                 obj.confirmCreate = true;
@@ -987,7 +1033,7 @@ export default {
                   res.msg || `当前乐团存在未排课的缴费项目,请再次确认操作`,
                   "提示",
                   {
-                    type: "warning",
+                    type: "warning"
                   }
                 );
                 obj.confirmCreate = true;
@@ -1019,7 +1065,7 @@ export default {
           // 值有start,center,end,nearest,当前显示在视图区域中间
           block: "center",
           // 值有auto、instant,smooth,缓动动画(当前是慢速的)
-          behavior: "smooth",
+          behavior: "smooth"
         });
         break; // 跳出循环了
       }
@@ -1032,17 +1078,18 @@ export default {
       let tmpActiveList = form.activeList?.length > 0 ? form.activeList : [];
       let activeList = [];
       if (tmpActiveList.length > 0) {
-        tmpActiveList.forEach((active) => {
+        tmpActiveList.forEach(active => {
           if (active.activityId) {
             active.categoryName = active.vipGroupCategoryNames;
             activeList.push(active);
           }
         });
       }
-      let memberObj = form.memberList?.length > 0 ? { ...form.memberList[0] } : null;
+      let memberObj =
+        form.memberList?.length > 0 ? { ...form.memberList[0] } : null;
       // 获取会员名称
       if (memberObj) {
-        this.memberRankList.forEach((item) => {
+        this.memberRankList.forEach(item => {
           if (item.id == memberObj.memberRankSettingId) {
             memberObj.name = item.name;
           }
@@ -1052,7 +1099,7 @@ export default {
       let tempCourseList = form.eclass?.length > 0 ? form.eclass : [];
       let courseList = [];
       if (tempCourseList.length > 0) {
-        tempCourseList.forEach((course) => {
+        tempCourseList.forEach(course => {
           if (course.courseType) {
             course.isStudentOptional = true;
             courseList.push(course);
@@ -1064,7 +1111,7 @@ export default {
         musicGroup: this.musicGroup,
         paymentCalender: {
           calender: {
-            isShowSalePrice: form.isShowSalePrice,
+            isShowSalePrice: form.isShowSalePrice
           },
           activity: [...activeList], // 小班课
           course: courseList, // 课程
@@ -1075,12 +1122,12 @@ export default {
             this.isShowLeBao &&
             this.$route.query.team_status != "PROGRESS"
               ? { ...form.leBaoList[0], optionalFlag: false }
-              : null, // 乐保
+              : null // 乐保
         },
         isShowMemberForPay: form.isShowMemberForPay,
         isShowMusicInsuranceForPay: form.isShowMusicInsuranceForPay,
         isShowVipCourseForPay: form.isShowVipCourseForPay,
-        isShowMusicCourseForPay: form.isShowMusicCourseForPay,
+        isShowMusicCourseForPay: form.isShowMusicCourseForPay
       };
     },
     fommatDate() {
@@ -1095,7 +1142,9 @@ export default {
           calenderActivityList:
             this.form.activeList?.length > 0 ? this.form.activeList : null,
           musicRepair:
-            this.form.leBaoList?.length > 0 ? { ...this.form.leBaoList[0] } : null,
+            this.form.leBaoList?.length > 0
+              ? { ...this.form.leBaoList[0] }
+              : null,
           calenderMember:
             this.form.memberList?.length > 0 &&
             this.form.memberList[0]?.memberRankSettingId
@@ -1108,9 +1157,9 @@ export default {
             isShowMemberForPay: this.form.isShowMemberForPay,
             isShowMusicInsuranceForPay: this.form.isShowMusicInsuranceForPay,
             isShowVipCourseForPay: this.form.isShowVipCourseForPay,
-            isShowMusicCourseForPay: this.form.isShowMusicCourseForPay,
+            isShowMusicCourseForPay: this.form.isShowMusicCourseForPay
           }),
-          isShowSalePrice: this.form.isShowSalePrice,
+          isShowSalePrice: this.form.isShowSalePrice
         };
       } else {
         let calenderFeeJson = this.form.calenderFeeJson;
@@ -1128,7 +1177,9 @@ export default {
           calenderActivityList:
             this.form.activeList?.length > 0 ? this.form.activeList : null,
           musicRepair:
-            this.form.leBaoList?.length > 0 ? { ...this.form.leBaoList[0] } : null,
+            this.form.leBaoList?.length > 0
+              ? { ...this.form.leBaoList[0] }
+              : null,
           calenderMember:
             this.form.memberList?.length > 0 &&
             this.form.memberList[0]?.memberRankSettingId
@@ -1141,13 +1192,14 @@ export default {
             isShowMemberForPay: this.form.isShowMemberForPay,
             isShowMusicInsuranceForPay: this.form.isShowMusicInsuranceForPay,
             isShowVipCourseForPay: this.form.isShowVipCourseForPay,
-            isShowMusicCourseForPay: this.form.isShowMusicCourseForPay,
+            isShowMusicCourseForPay: this.form.isShowMusicCourseForPay
           }),
           calenderFeeType: this.form.calenderFeeType,
           calenderFeeJson: JSON.stringify(calenderFeeJson),
-          musicGroupCalenderRefundPeriods: this.form.musicGroupCalenderRefundPeriods,
+          musicGroupCalenderRefundPeriods: this.form
+            .musicGroupCalenderRefundPeriods,
           currentTotalAmount: this.form.currentTotalAmount,
-          contractUrl: this.form.contractUrl,
+          contractUrl: this.form.contractUrl
         };
       }
     },
@@ -1166,7 +1218,8 @@ export default {
       this.form.calenderFeeJson.allTotal = val;
       if (this.form.calenderFeeJson.discountTotal) {
         this.form.currentTotalAmount =
-          this.form.calenderFeeJson.allTotal - this.form.calenderFeeJson.discountTotal;
+          this.form.calenderFeeJson.allTotal -
+          this.form.calenderFeeJson.discountTotal;
       } else {
         this.form.currentTotalAmount = this.form.calenderFeeJson.allTotal;
       }
@@ -1175,7 +1228,7 @@ export default {
     },
     currentTotalAmount(val) {
       this.$set(this.form, "currentTotalAmount", val);
-    },
+    }
   },
   watch: {
     teamCourse(val) {
@@ -1209,19 +1262,19 @@ export default {
           return;
         } else {
           let arr = [];
-          newValue.forEach((item) => {
+          newValue.forEach(item => {
             arr.push({
               courseType: item.courseType,
               teacherNumber: 0,
               courseNumber: 0,
-              courseCurrentPrice: 0,
+              courseCurrentPrice: 0
             });
           });
 
           this.$set(this.form, "teacherFeeList", arr);
         }
       },
-      deep: true,
+      deep: true
     },
     // "form.calenderFeeType"(val, oldValue) {
     //   if (val == "TEACHER" && !oldValue) {
@@ -1247,12 +1300,12 @@ export default {
       console.log(val, oldValue, this.initDetail);
       if (val == "TEACHER" && !this.initDetail) {
         let arr = [];
-        this.form.eclass.forEach((item) => {
+        this.form.eclass.forEach(item => {
           arr.push({
             courseType: item.courseType,
             teacherNumber: 0,
             courseNumber: 0,
-            courseCurrentPrice: 0,
+            courseCurrentPrice: 0
           });
         });
 
@@ -1265,14 +1318,13 @@ export default {
       if (val && !this.isSetCourseSettingsId) {
         try {
           const res = await queryByMusicGroupOrganizationCourseSettingsId({
-            id: val,
+            id: val
           });
-          let CourseSettingDetail = res.data.map((course) => {
+          let CourseSettingDetail = res.data.map(course => {
             return {
-              ...course,
+              ...course
             };
           });
-          console.log("获取musicGroupOrganizationCourseSettingId重置eclass");
           this.$set(this.form, "eclass", res.data);
           // this.syncAllMoney();
         } catch (error) {}
@@ -1285,7 +1337,11 @@ export default {
       this.cycle = {};
 
       if (val != "1") {
-        this.$set(this.form, "musicGroupOrganizationCourseSettingId", undefined);
+        this.$set(
+          this.form,
+          "musicGroupOrganizationCourseSettingId",
+          undefined
+        );
       }
 
       // this.$set(this.cycle, "paymentAmount", undefined);
@@ -1296,7 +1352,7 @@ export default {
         this.$set(this.form, "eclass", [{}]);
       }
       this.isSetCourseSettingsId = false;
-    },
+    }
   },
   computed: {
     musicGroup() {
@@ -1304,8 +1360,8 @@ export default {
     },
     Eclass() {
       return JSON.parse(JSON.stringify(this.form.eclass));
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss" scoped>
@@ -1349,7 +1405,7 @@ export default {
   }
   .baseWrapFixed {
     top: 105px;
-    left: 210px; // 205
+    left: 215px; // 205
     position: fixed;
     background-color: #fff;
     width: calc(100% - 220px);

+ 116 - 105
src/views/resetTeaming/components/resetPayList.vue

@@ -61,12 +61,12 @@
         新建学校缴费
       </div>
       <div
-            class="newBand"
-            v-permission="'musicGroup/extensionPayment'"
-            @click="extendTime"
-          >
-            延长缴费
-          </div>
+        class="newBand"
+        v-permission="'musicGroup/extensionPayment'"
+        @click="extendTime"
+      >
+        延长缴费
+      </div>
       <!-- <div class="newBand"
            v-if="teamStatus"
            v-permission="'/studentPayBase'"
@@ -184,14 +184,15 @@
                 auths="musicGroupPaymentCalenderDetail/batchAdd/3890"
                 v-if="
                   scope.row.status != 'REJECT' &&
-                  scope.row.status != 'AUDITING' &&
-                  scope.row.status != 'DRAFT' &&
-                  teamStatus &&
-                  scope.row.paymentType != 'MUSIC_APPLY' &&
-                  scope.row.paymentType != 'ADD_STUDENT' &&
-                  scope.row.paymentType != 'SPAN_GROUP_CLASS_ADJUST'"
+                    scope.row.status != 'AUDITING' &&
+                    scope.row.status != 'DRAFT' &&
+                    teamStatus &&
+                    scope.row.paymentType != 'MUSIC_APPLY' &&
+                    scope.row.paymentType != 'ADD_STUDENT' &&
+                    scope.row.paymentType != 'SPAN_GROUP_CLASS_ADJUST'
+                "
               >
-              <!--    &&scope.row.payUserType === 'STUDENT' -->
+                <!--    &&scope.row.payUserType === 'STUDENT' -->
                 <el-button type="text" @click="openChioseStudent(scope.row)"
                   >添加学员</el-button
                 >
@@ -201,9 +202,10 @@
               <auth
                 auths="musicGroupPaymentCalender/update/4313"
                 v-if="
-                  teamStatus && scope.row.paymentType != 'ADD_STUDENT' &&
-                  (scope.row.status === 'REJECT' ||
-                    scope.row.status === 'DRAFT')
+                  teamStatus &&
+                    scope.row.paymentType != 'ADD_STUDENT' &&
+                    (scope.row.status === 'REJECT' ||
+                      scope.row.status === 'DRAFT')
                 "
               >
                 <el-button type="text" @click="resetPay(scope.row)"
@@ -213,9 +215,10 @@
               <auth
                 auths="musicGroupPaymentCalender/update/4313"
                 v-if="
-                team_status == 'FEE_AUDIT_FAILED' && scope.row.paymentType != 'ADD_STUDENT' &&
-                  (scope.row.status === 'REJECT' ||
-                    scope.row.status === 'DRAFT')
+                  team_status == 'FEE_AUDIT_FAILED' &&
+                    scope.row.paymentType != 'ADD_STUDENT' &&
+                    (scope.row.status === 'REJECT' ||
+                      scope.row.status === 'DRAFT')
                 "
               >
                 <el-button type="text" @click="resetPay(scope.row)"
@@ -227,8 +230,8 @@
                 auths="musicGroupPaymentCalender/revoke"
                 v-if="
                   (team_status == 'FEE_AUDIT' || team_status == 'PROGRESS') &&
-                  scope.row.status === 'AUDITING' &&
-                  scope.row.paymentType != 'ADD_STUDENT'
+                    scope.row.status === 'AUDITING' &&
+                    scope.row.paymentType != 'ADD_STUDENT'
                 "
               >
                 <el-button type="text" @click="revoke(scope.row)"
@@ -240,8 +243,9 @@
                 auths="musicGroupPaymentCalender/delByBatchNo/4305"
                 v-if="
                   teamStatus &&
-                  scope.row.paymentType != 'ADD_STUDENT' &&
-                  (scope.row.status == 'DRAFT' || scope.row.status == 'REJECT')
+                    scope.row.paymentType != 'ADD_STUDENT' &&
+                    (scope.row.status == 'DRAFT' ||
+                      scope.row.status == 'REJECT')
                 "
               >
                 <el-button type="text" @click="removeBatchNo(scope.row)"
@@ -252,8 +256,9 @@
                 auths="musicGroupPaymentCalender/delByBatchNo/4305"
                 v-if="
                   teamStatus &&
-                  scope.row.paymentType == 'ADD_STUDENT' &&
-                  (scope.row.status == 'DRAFT' || scope.row.status == 'REJECT')
+                    scope.row.paymentType == 'ADD_STUDENT' &&
+                    (scope.row.status == 'DRAFT' ||
+                      scope.row.status == 'REJECT')
                 "
               >
                 <el-button type="text" @click="removeBatchNo(scope.row)"
@@ -265,10 +270,11 @@
                 type="text"
                 v-if="
                   !isNewGropu &&
-                  teamStatus &&
-                  scope.row.paymentType != 'MUSIC_APPLY' &&
-                  (scope.row.status == 'OPEN' || scope.row.status == 'OVER')&&
-                  scope.row.payUserType === 'STUDENT'
+                    teamStatus &&
+                    scope.row.paymentType != 'MUSIC_APPLY' &&
+                    (scope.row.status == 'OPEN' ||
+                      scope.row.status == 'OVER') &&
+                    scope.row.payUserType === 'STUDENT'
                 "
                 @click="onCreateQRCode(scope.row)"
                 >续费二维码</el-button
@@ -277,10 +283,10 @@
                 type="text"
                 v-if="
                   scope.row.payUserType === 'STUDENT' &&
-                  scope.row.paymentType == 'MUSIC_APPLY' &&
-                  $helpers.permission(
-                    'musicGroup/findMusicGroupSubjectInfo/966'
-                  )
+                    scope.row.paymentType == 'MUSIC_APPLY' &&
+                    $helpers.permission(
+                      'musicGroup/findMusicGroupSubjectInfo/966'
+                    )
                 "
                 @click="onPreview(scope.row)"
                 >预览</el-button
@@ -332,7 +338,7 @@
         <el-form-item
           label="缴费开始日期"
           :rules="[
-            { required: true, message: '请设置缴费开始日期', trigger: 'blur' },
+            { required: true, message: '请设置缴费开始日期', trigger: 'blur' }
           ]"
           prop="startPaymentDate"
         >
@@ -348,7 +354,7 @@
         <el-form-item
           label="缴费结束日期"
           :rules="[
-            { required: true, message: '请设置缴费结束日期', trigger: 'blur' },
+            { required: true, message: '请设置缴费结束日期', trigger: 'blur' }
           ]"
           prop="deadlinePaymentDate"
         >
@@ -384,8 +390,8 @@
             {
               required: true,
               message: '请设置缴费有效期开始日期',
-              trigger: 'blur',
-            },
+              trigger: 'blur'
+            }
           ]"
           prop="paymentValidStartDate"
         >
@@ -404,8 +410,8 @@
             {
               required: true,
               message: '请设置缴费有效期结束日期',
-              trigger: 'blur',
-            },
+              trigger: 'blur'
+            }
           ]"
           prop="paymentValidEndDate"
         >
@@ -421,7 +427,7 @@
           label="收费类型"
           v-if="isNew"
           :rules="[
-            { required: true, message: '请选择收费类型', trigger: 'blur' },
+            { required: true, message: '请选择收费类型', trigger: 'blur' }
           ]"
           prop="type"
         >
@@ -590,7 +596,10 @@
         >
       </div>
     </el-dialog>
-    <el-button type="primary" @click="submitAudit" v-if="team_status == 'DRAFT' || team_status == 'AUDIT_FAILED'"
+    <el-button
+      type="primary"
+      @click="submitAudit"
+      v-if="team_status == 'DRAFT' || team_status == 'AUDIT_FAILED'"
       >提交审核</el-button
     >
     <el-button
@@ -618,14 +627,14 @@ import {
   getTeamBaseInfo,
   auditSuccess,
   auditFailed,
-  musicGroupAuditing,
+  musicGroupAuditing
 } from "@/api/buildTeam";
 // import { auditSuccess, auditFailed } from "@/api/buildTeam";
 import {
   resetMusicGroupPaymentCalender,
   delMusicGroupPaymentCalender,
   findMusicGroupSubjectInfo,
-  extensionPayment,
+  extensionPayment
 } from "@/api/buildTeam";
 import { getAuditList } from "@/api/auditManager";
 import { getOrganizationCourseUnitPriceSettings } from "@/api/specialSetting";
@@ -633,7 +642,7 @@ import {
   getMusicGroupStu,
   musicGroupPaymentCalenderDetailBatchAdd,
   musicGroupPaymentCalenderDelByBatchNo,
-  revokeMusicGroupPaymentCalender,
+  revokeMusicGroupPaymentCalender
 } from "../api";
 import setStudentFee from "./studentPayBase";
 import userPayForm from "../modals/user-pay-form";
@@ -658,7 +667,7 @@ export default {
     review,
     reviewDetail,
     "pay-items": payItems,
-    subjectPreview,
+    subjectPreview
   },
   data() {
     return {
@@ -672,7 +681,7 @@ export default {
       organizationCourseUnitPriceSettings: [],
       searchForm: {
         paymentType: null,
-        payUserType: null,
+        payUserType: null
       },
       viewDetail: null,
       tableList: [],
@@ -681,7 +690,7 @@ export default {
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50], // 选择限制显示条数
+        page_size: [10, 20, 40, 50] // 选择限制显示条数
       },
       isInit: false,
       diTitle: "新增缴费",
@@ -693,7 +702,7 @@ export default {
         paymentValidStartDate: null,
         paymentValidEndDate: null,
         type: null,
-        memo: null,
+        memo: null
       },
       isNew: false,
       activeRow: null,
@@ -701,7 +710,7 @@ export default {
         firstDayOfWeek: 1,
         disabledDate(time) {
           return time.getTime() + 86400000 <= new Date().getTime();
-        },
+        }
       },
       qrcodeStatus: false, // 生成二维码
       codeUrl: null,
@@ -721,14 +730,14 @@ export default {
       payUserTypeList: payUserTypeList,
       extendPaymentStatus: "",
       extendForm: {
-        expireDate: null,
+        expireDate: null
       },
       extendRule: {
         expireDate: [
-          { required: true, message: "请选择延长时间", trigger: "change" },
-        ],
+          { required: true, message: "请选择延长时间", trigger: "change" }
+        ]
       },
-      applyDates: this.applyDate(),
+      applyDates: this.applyDate()
     };
   },
   //生命周期 - 创建完成(可以访问当前this实例)
@@ -740,7 +749,7 @@ export default {
     // 获取分部
     try {
       const res = await getOrganizationCourseUnitPriceSettings({
-        rows: 9999,
+        rows: 9999
       });
       this.organizationCourseUnitPriceSettings = res.data.rows;
       // this.organizationCourseUnitPriceSettings=[];
@@ -770,11 +779,15 @@ export default {
     },
     teamStatus() {
       // let type = this.$route.query.type;
-      return this.team_status == "DRAFT" || this.team_status == "PROGRESS" || this.team_status == "AUDIT_FAILED";
+      return (
+        this.team_status == "DRAFT" ||
+        this.team_status == "PROGRESS" ||
+        this.team_status == "AUDIT_FAILED"
+      );
     },
     team_status() {
       return this.$route.query.team_status;
-    },
+    }
   },
   // activated () {
   //   this.init();
@@ -784,7 +797,7 @@ export default {
       // this.team_status = this.$route.query.team_status;
       try {
         const res = await getMusicGroupStu({
-          musicGroupId: this.$route.query.id,
+          musicGroupId: this.$route.query.id
         });
       } catch (error) {}
       this.getTeamInfo();
@@ -792,7 +805,7 @@ export default {
     },
     getTeamInfo() {
       if (this.$route.query.id) {
-        getTeamBaseInfo({ musicGroupId: this.$route.query.id }).then((res) => {
+        getTeamBaseInfo({ musicGroupId: this.$route.query.id }).then(res => {
           if (res.code == 200) {
             this.baseInfo = res.data;
             this.$emit("getBaseInfo", this.baseInfo);
@@ -810,7 +823,7 @@ export default {
       let query = this.$route.query;
       this.$router.push({
         path: "/business/studentPaySet",
-        query: { ...query, payUserType: "STUDENT" },
+        query: { ...query, payUserType: "STUDENT" }
       });
       // 判断一下乐团是课程缴费 还是会员缴费 且乐团状态为创建缴费中
       // if (
@@ -833,9 +846,9 @@ export default {
       this.$router.push(
         {
           path: "/business/studentPaySet",
-          query: { ...query, payUserType: "SCHOOL" },
+          query: { ...query, payUserType: "SCHOOL" }
         },
-        (route) => {
+        route => {
           route.meta.title = "学校缴费设置";
         }
       );
@@ -847,8 +860,8 @@ export default {
         rows: this.rules.limit,
         musicGroupId: musicGroupId,
         payUserType: this.searchForm.payUserType,
-        paymentType: this.searchForm.paymentType,
-      }).then((res) => {
+        paymentType: this.searchForm.paymentType
+      }).then(res => {
         if (res.code == 200) {
           this.rules.total = res.data.total;
           this.tableList = res.data.rows;
@@ -893,7 +906,7 @@ export default {
         let query = this.$route.query;
         this.$router.push({
           path: "/business/studentPaySet",
-          query: { ...query, payUserType: row.payUserType, calenderId: row.id },
+          query: { ...query, payUserType: row.payUserType, calenderId: row.id }
         });
         // 跳转新接口
         // this.memberVisible = true;
@@ -906,10 +919,10 @@ export default {
         await this.$confirm("是否撤回此缴费项目的审批?", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
-          type: "warning",
+          type: "warning"
         });
         const res = await revokeMusicGroupPaymentCalender({
-          batchNo: row.batchNo,
+          batchNo: row.batchNo
         });
         this.$message.success("取消审批成功");
         this.getList();
@@ -926,11 +939,11 @@ export default {
         await this.$confirm("缴费创建完成, 是否立即排课?", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
-          type: "warning",
+          type: "warning"
         });
         if (this.$listeners.changeActive) {
           this.$listeners.changeActive({
-            name: "5",
+            name: "5"
           });
         }
       } catch (error) {}
@@ -940,10 +953,10 @@ export default {
       this.$confirm(`确定删除该缴费周期?`, "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
-          delMusicGroupPaymentCalender({ id }).then((res) => {
+          delMusicGroupPaymentCalender({ id }).then(res => {
             if (res.code == 200) {
               this.$message.success("删除成功");
 
@@ -973,13 +986,13 @@ export default {
         await this.$confirm("确定提交审核?", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
-          type: "warning",
+          type: "warning"
         });
         const res = await musicGroupAuditing({ musicGroupId: this.teamid });
         this.$message.success("提交成功");
         this.$store.dispatch("delVisitedViews", this.$route);
         this.$router.push({
-          path: "/teamList",
+          path: "/teamList"
         });
       } catch (e) {
         console.log(e);
@@ -989,16 +1002,16 @@ export default {
       this.extendPaymentStatus = true;
     },
     onExtendPayment(formName) {
-      this.$refs[formName].validate((valid) => {
+      this.$refs[formName].validate(valid => {
         if (valid) {
           extensionPayment({
             musicGroupId: this.$route.query.id,
-            expireDate: this.extendForm.expireDate,
-          }).then((res) => {
+            expireDate: this.extendForm.expireDate
+          }).then(res => {
             if (res.code == 200) {
               this.$message.success("延长缴费成功");
               this.extendPaymentStatus = false;
-              this.getList()
+              this.getList();
             } else {
               this.$message.error(res.msg);
             }
@@ -1013,7 +1026,7 @@ export default {
     async removeBatchNo(row) {
       try {
         await this.$confirm("是否确认删除该缴费批次?", "提示", {
-          type: "warning",
+          type: "warning"
         });
         await musicGroupPaymentCalenderDelByBatchNo({ batchNo: row.batchNo });
         this.$message.success("删除成功");
@@ -1021,7 +1034,7 @@ export default {
       } catch (error) {}
     },
     newPayInfo() {
-      this.$refs["payForm"].validate((res) => {
+      this.$refs["payForm"].validate(res => {
         if (res) {
           /**
            *   payForm: {
@@ -1044,11 +1057,11 @@ export default {
       }
 
       let obj = {};
-      obj.userIdList = this.chioseStudentList.map((stu) => {
+      obj.userIdList = this.chioseStudentList.map(stu => {
         return stu.userId;
       });
       obj.batchNo = this.batchNo;
-      musicGroupPaymentCalenderDetailBatchAdd(obj).then((res) => {
+      musicGroupPaymentCalenderDetailBatchAdd(obj).then(res => {
         if (res.code == 200) {
           this.$message.success("添加成功");
           this.$refs.setStudentFee.clearTable();
@@ -1070,8 +1083,8 @@ export default {
         paymentValidEndDate: this.payForm.paymentValidEndDate
           ? dayjs(this.payForm.paymentValidEndDate).format("YYYY-MM-DD")
           : this.payForm.paymentValidEndDate,
-        paymentPattern: this.payForm.paymentPattern,
-      }).then((res) => {
+        paymentPattern: this.payForm.paymentPattern
+      }).then(res => {
         if (res.code == 200) {
           this.$message.success("修改成功");
           this.payVisible = false;
@@ -1108,7 +1121,7 @@ export default {
             return time.getTime() + 86400000 < Date.now();
             //开始时间不选时,结束时间最大值小于等于当天
           }
-        },
+        }
       };
     },
     search() {
@@ -1139,7 +1152,7 @@ export default {
       // 开始预览
       this.dialogCalenderId = row.id;
       const musicGroupId = this.$route.query.id;
-      findMusicGroupSubjectInfo({ musicGroupId: musicGroupId }).then((res) => {
+      findMusicGroupSubjectInfo({ musicGroupId: musicGroupId }).then(res => {
         if (res.code == 200) {
           this.dialogSubjectList = res.data.musicGroupSubjectPlans;
 
@@ -1162,16 +1175,16 @@ export default {
       this.$confirm(`是否审核通过?`, "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
-          auditSuccess({ musicGroupId: this.teamid }).then((res) => {
+          auditSuccess({ musicGroupId: this.teamid }).then(res => {
             if (res.code == 200) {
               this.$message.success("审核通过");
               this.$store.dispatch("delVisitedViews", this.$route);
               this.$router.push({
                 path: "/teamList",
-                query: { search: this.Fsearch, rules: this.Frules },
+                query: { search: this.Fsearch, rules: this.Frules }
               });
             }
           });
@@ -1182,25 +1195,23 @@ export default {
       // auditFailed
       this.$prompt("请输入拒绝原因", "提示", {
         confirmButtonText: "确定",
-        cancelButtonText: "取消",
+        cancelButtonText: "取消"
       }).then(({ value }) => {
         //   点击确认  值是value
         if (!value) {
           this.$message.error("请输入驳回原因");
           return;
         } else {
-          auditFailed({ musicGroupId: this.teamid, memo: value }).then(
-            (res) => {
-              if (res.code == 200) {
-                this.$message.success("已拒绝");
-                this.$store.dispatch("delVisitedViews", this.$route);
-                this.$router.push({
-                  path: "/teamList",
-                  query: { search: this.Fsearch, rules: this.Frules },
-                });
-              }
+          auditFailed({ musicGroupId: this.teamid, memo: value }).then(res => {
+            if (res.code == 200) {
+              this.$message.success("已拒绝");
+              this.$store.dispatch("delVisitedViews", this.$route);
+              this.$router.push({
+                path: "/teamList",
+                query: { search: this.Fsearch, rules: this.Frules }
+              });
             }
-          );
+          });
         }
       });
     },
@@ -1210,9 +1221,9 @@ export default {
         firstDayOfWeek: 1,
         disabledDate(time) {
           return time.getTime() + 86400000 < new Date().getTime();
-        },
+        }
       };
-    },
+    }
   },
   watch: {
     chioseStudentVisible() {
@@ -1227,15 +1238,15 @@ export default {
           paymentValidEndDate: null,
           type: null,
           memo: null,
-          deadlinePaymentDate: null,
+          deadlinePaymentDate: null
         };
         this.$refs["payForm"].resetFields();
       }
-    },
-  },
+    }
+  }
 };
 </script>
-<style lang='scss' scoped>
+<style lang="scss" scoped>
 .topWrap {
   display: flex;
   flex-direction: row;

+ 110 - 103
src/views/resetTeaming/components/strudentPayInfo.vue

@@ -21,7 +21,7 @@
           >
             {{ "已开启" }}
           </p>
-                 <p
+          <p
             class="status"
             style="color: #ff6a6a"
             v-if="info.paymentStatus == 'AUDITING'"
@@ -42,14 +42,13 @@
           >
             {{ "已结束" }}
           </p>
-              <p
+          <p
             class="status"
             style="color: #5ccdb8"
             v-if="info.paymentStatus == 'REJECT'"
           >
             {{ "已拒绝" }}
           </p>
-
         </span>
       </statistic-item>
       <statistic-item>
@@ -130,8 +129,8 @@
         <el-form-item>
           <el-input
             v-model.trim="searchForm.search"
-           @keyup.enter.native="
-              (e) => {
+            @keyup.enter.native="
+              e => {
                 e.target.blur();
                 $refs.searchForm.save();
                 search();
@@ -253,30 +252,30 @@
             width="55"
           >
           </el-table-column>
-                 <el-table-column type="expand">
-          <template slot-scope="props">
-            <el-form label-position="left" inline class="demo-table-expand">
-              <el-form-item label="乐团课金额">
-                <span>{{ props.row.courseAmount | moneyFormat}}元</span>
-              </el-form-item>
-              <el-form-item label="云教练金额">
-                <span>{{ props.row.cloudAmount | moneyFormat}}元</span>
-              </el-form-item>
-              <el-form-item label="乐保金额">
-                <span>{{ props.row.maintenanceAmount | moneyFormat}}元</span>
-              </el-form-item>
-              <el-form-item label="乐团活动金额">
-                <span>{{ props.row.activityAmount | moneyFormat}}元</span>
-              </el-form-item>
-              <el-form-item label="乐器金额">
-                <span>{{ props.row.musicalAmount | moneyFormat}}元</span>
-              </el-form-item>
-              <el-form-item label="辅件金额">
-                <span>{{ props.row.accessoriesAmount | moneyFormat}}元</span>
-              </el-form-item>
-            </el-form>
-          </template>
-        </el-table-column>
+          <el-table-column type="expand">
+            <template slot-scope="props">
+              <el-form label-position="left" inline class="demo-table-expand">
+                <el-form-item label="乐团课金额">
+                  <span>{{ props.row.courseAmount | moneyFormat }}元</span>
+                </el-form-item>
+                <el-form-item label="云教练金额">
+                  <span>{{ props.row.cloudAmount | moneyFormat }}元</span>
+                </el-form-item>
+                <el-form-item label="乐保金额">
+                  <span>{{ props.row.maintenanceAmount | moneyFormat }}元</span>
+                </el-form-item>
+                <el-form-item label="乐团活动金额">
+                  <span>{{ props.row.activityAmount | moneyFormat }}元</span>
+                </el-form-item>
+                <el-form-item label="乐器金额">
+                  <span>{{ props.row.musicalAmount | moneyFormat }}元</span>
+                </el-form-item>
+                <el-form-item label="辅件金额">
+                  <span>{{ props.row.accessoriesAmount | moneyFormat }}元</span>
+                </el-form-item>
+              </el-form>
+            </template>
+          </el-table-column>
           <el-table-column
             align="center"
             prop="userId"
@@ -479,7 +478,6 @@
         highlight-current-row
         @current-change="handleCurrentChange"
       >
-
         <!-- <el-table-column type="selection"
                          width="55">
         </el-table-column> -->
@@ -504,7 +502,12 @@
         <el-button type="primary" @click="submitAddStudent">确 定</el-button>
       </div>
     </el-dialog>
-    <el-dialog width="900px" title="查看缴费详情" :visible.sync="detailVisible" v-if="detailVisible">
+    <el-dialog
+      width="900px"
+      title="查看缴费详情"
+      :visible.sync="detailVisible"
+      v-if="detailVisible"
+    >
       <reviewDetail
         @close="detailVisible = false"
         @submited="getList"
@@ -576,7 +579,7 @@ import {
   queryCanAddStudent,
   addMusicGroupPaymentCalenderStudent,
   delMusicGroupPaymentCalenderStudent,
-  sendWaitRenewMessage,
+  sendWaitRenewMessage
 } from "@/api/buildTeam";
 let that;
 export default {
@@ -587,7 +590,7 @@ export default {
         search: null,
         subjectId: null,
         paymentStatus: null,
-        musicGroupStatus: null,
+        musicGroupStatus: null
       },
       teacherList: [],
       soundList: [],
@@ -597,7 +600,7 @@ export default {
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50], // 选择限制显示条数
+        page_size: [10, 20, 40, 50] // 选择限制显示条数
       },
       payVisible: false,
       resetPayVisible: false,
@@ -608,14 +611,14 @@ export default {
         firstDayOfWeek: 1,
         disabledDate(time) {
           return time.getTime() + 86400000 <= new Date().getTime();
-        },
+        }
       },
       payForm: {
-        startDate: null,
+        startDate: null
       },
       resetPayForm: {
         momey: null,
-        expectMemberAmount: null,
+        expectMemberAmount: null
       },
       activeChiose: [],
       id: null,
@@ -626,7 +629,7 @@ export default {
         deadlinePaymentDate: null,
         expectNum: null,
         actualNum: null,
-        sumActualAmount: null,
+        sumActualAmount: null
       },
 
       msgList: [],
@@ -641,13 +644,13 @@ export default {
         memberPaymentAmount: "",
         memberRankSettingName: "",
         originalMemberPaymentAmount: "",
-        memberValidDate: "",
+        memberValidDate: ""
       },
       timerVisible: false,
       timerForm: {
         startPaymentDate: "",
-        deadlinePaymentDate: "",
-      },
+        deadlinePaymentDate: ""
+      }
     };
   },
   //生命周期 - 创建完成(可以访问当前this实例)
@@ -657,7 +660,7 @@ export default {
     // 获取声部
     that = this;
     this.teamid = this.$route.query.id;
-    findSound({ musicGroupId: this.teamid }).then((res) => {
+    findSound({ musicGroupId: this.teamid }).then(res => {
       if (res.code == 200) {
         this.soundList = res.data;
       }
@@ -667,7 +670,7 @@ export default {
   },
   activated() {
     this.teamid = this.$route.query.id;
-    findSound({ musicGroupId: this.teamid }).then((res) => {
+    findSound({ musicGroupId: this.teamid }).then(res => {
       if (res.code == 200) {
         this.soundList = res.data;
       }
@@ -681,7 +684,7 @@ export default {
     getList() {
       this.id = this.$route.query.paymentId;
       // 获取缴费状态
-      getMusicGroupPaymentCalenderDetail({ id: this.id }).then((res) => {
+      getMusicGroupPaymentCalenderDetail({ id: this.id }).then(res => {
         if (res.code == 200) {
           this.info = {
             paymentStatus: res.data.calender.status,
@@ -689,7 +692,7 @@ export default {
             deadlinePaymentDate: res.data.calender.deadlinePaymentDate,
             expectNum: res.data.calender.expectNum,
             actualNum: res.data.calender.actualNum,
-            sumActualAmount: res.data.sumActualAmount,
+            sumActualAmount: res.data.sumActualAmount
           };
           this.titleForm = {
             paymentType: res.data.calender.paymentType,
@@ -702,7 +705,7 @@ export default {
             memberRankSettingName: res.data.calender.memberRankSettingName,
             originalMemberPaymentAmount:
               res.data.calender.originalMemberPaymentAmount,
-            memberValidDate: res.data.calender.memberValidDate,
+            memberValidDate: res.data.calender.memberValidDate
           };
           this.msgList = res.data.musicGroupPaymentCalenderCourseSettings;
           this.memberRankSettingId = res.data?.calender?.memberRankSettingId;
@@ -711,7 +714,7 @@ export default {
       this.searchForm.id = this.id;
       this.searchForm.page = this.rules.page;
       this.searchForm.rows = this.rules.limit;
-      getmusicGroupPaymentCalenderDetail(this.searchForm).then((payment) => {
+      getmusicGroupPaymentCalenderDetail(this.searchForm).then(payment => {
         if (payment.code == 200) {
           this.rules.total = payment.data.total;
           this.tableList = payment.data.rows;
@@ -726,7 +729,7 @@ export default {
       this.searchForm = {
         search: null,
         subjectId: null,
-        paymentStatus: null,
+        paymentStatus: null
       };
       this.search();
     },
@@ -739,7 +742,7 @@ export default {
         this.$message.error("请至少选择一名学员");
         return;
       }
-      let ids = this.activeChiose.map((item) => {
+      let ids = this.activeChiose.map(item => {
         return item.id;
       });
       this.ids = ids.join(",");
@@ -754,19 +757,23 @@ export default {
         this.$store.dispatch("delVisitedViews", this.$route);
         this.$router.push({
           path: "/business/resetTeaming",
-          query: { ...this.$route.query },
+          query: { ...this.$route.query }
         });
       } else if (query.type == "look") {
         this.$store.dispatch("delVisitedViews", this.$route);
         this.$router.push({
           path: "/business/resetTeaming",
-          query: { ...this.$route.query },
+          query: { ...this.$route.query }
         });
-      } else if (query.type == "teamDraft" || query.type == "teamAudit" || query.type=='FEE_AUDIT_FAILED') {
+      } else if (
+        query.type == "teamDraft" ||
+        query.type == "teamAudit" ||
+        query.type == "FEE_AUDIT_FAILED"
+      ) {
         this.$store.dispatch("delVisitedViews", this.$route);
         this.$router.push({
           path: "/business/resetTeaming",
-          query: { ...this.$route.query },
+          query: { ...this.$route.query }
         });
       }
     },
@@ -785,13 +792,13 @@ export default {
       // console.log(this.activeChiose)
     },
     submitReset() {
-      this.$refs.resetPayForm.validate((res) => {
+      this.$refs.resetPayForm.validate(res => {
         if (res) {
           let obj = {};
           obj.expectAmount = this.resetPayForm.momey;
           obj.expectMemberAmount = this.resetPayForm.expectMemberAmount;
           obj.ids = this.ids;
-          resetMusicGroupPaymentCalenderDetail(obj).then((res) => {
+          resetMusicGroupPaymentCalenderDetail(obj).then(res => {
             if (res.code == 200) {
               this.$message.success("修改成功");
               this.resetPayVisible = false;
@@ -811,8 +818,8 @@ export default {
       // 获取无缴费学员
       queryCanAddStudent({
         musicGroupId: this.teamid,
-        musicGroupPaymentCalenderId: this.id,
-      }).then((res) => {
+        musicGroupPaymentCalenderId: this.id
+      }).then(res => {
         if (res.code == 200) {
           this.studentList = res.data;
           this.studentVisible = true;
@@ -827,17 +834,17 @@ export default {
       this.$confirm(`是否删除此学员`, "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
           let musicGroupPaymentCalenderDetailIds = this.activeChiose
-            .map((stu) => {
+            .map(stu => {
               return stu.id;
             })
             .join(",");
           delMusicGroupPaymentCalenderStudent({
-            musicGroupPaymentCalenderDetailIds,
-          }).then((res) => {
+            musicGroupPaymentCalenderDetailIds
+          }).then(res => {
             if (res.code == 200) {
               this.$message.success(`删除成功`);
               this.$set(this.rules, "page", 1);
@@ -857,8 +864,8 @@ export default {
       }
       addMusicGroupPaymentCalenderStudent({
         musicGroupPaymentCalenderId: this.id,
-        userId: this.chioseStudent.userId,
-      }).then((res) => {
+        userId: this.chioseStudent.userId
+      }).then(res => {
         if (res.code == 200) {
           this.$message.success("添加成功");
           this.studentVisible = false;
@@ -872,7 +879,7 @@ export default {
       let url = "/api-web/export/musicGroupPaymentCalenderDetail";
       let data = {
         id: this.$route.query.paymentId,
-        musicGroupId: this.$route.query.id,
+        musicGroupId: this.$route.query.id
       };
       const options = {
         method: "POST",
@@ -882,33 +889,33 @@ export default {
         },
         data: qs.stringify(cleanDeep(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.ms-excel;charset=utf-8",
+                type: "application/vnd.ms-excel;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);
-                  if(json.code == 403) {
-                    this.$message.error(`登录过期,请重新登录!`)
+                  if (json.code == 403) {
+                    this.$message.error(`登录过期,请重新登录!`);
                     setTimeout(() => {
-                      this.$store.dispatch('user/resetToken').then(() => {
-                        location.reload()
-                      })
+                      this.$store.dispatch("user/resetToken").then(() => {
+                        location.reload();
+                      });
                     }, 1000);
-                    return
+                    return;
                   }
                   this.$message.error(json.msg);
                 } else {
@@ -924,7 +931,7 @@ export default {
 
               load.endLoading();
             })
-            .catch((error) => {
+            .catch(error => {
               this.$message.error("导出数据失败,请联系管理员");
               load.endLoading();
             });
@@ -943,7 +950,7 @@ export default {
       let submitArr = [];
       let msgArr = "";
       let str = "";
-      this.activeChiose.forEach((item) => {
+      this.activeChiose.forEach(item => {
         if (item.open) {
           submitArr.push(item.userId);
         } else {
@@ -960,13 +967,13 @@ export default {
       this.$confirm(str, "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(async () => {
           try {
             const res = await sendWaitRenewMessage({
               studentIds: submitArr.join(","),
-              calenderId: this.$route.query.paymentId,
+              calenderId: this.$route.query.paymentId
             });
             this.$message.success("提醒成功");
             this.getList();
@@ -978,17 +985,17 @@ export default {
       this.timerForm.deadlinePaymentDate = "";
     },
     async submitPayTimer() {
-      this.$refs.timerForm.validate((flag) => {
+      this.$refs.timerForm.validate(flag => {
         if (flag) {
-          let ids = this.activeChiose.map((item) => {
+          let ids = this.activeChiose.map(item => {
             return item.id;
           });
           ids = ids.join(",");
           // console.log(ids)
           openMusicGroupPaymentCalenderDetailPayment({
             ids,
-            ...this.timerForm,
-          }).then((res) => {
+            ...this.timerForm
+          }).then(res => {
             if (res.code == 200) {
               this.$message.success(res.msg);
               this.timerVisible = false;
@@ -998,13 +1005,13 @@ export default {
           });
         }
       });
-    },
+    }
   },
   watch: {
     payVisible(val) {
       if (!val) {
         this.payForm = {
-          startDate: null,
+          startDate: null
         };
         this.$refs["payForm"].resetFields();
       }
@@ -1012,7 +1019,7 @@ export default {
     resetPayVisible(val) {
       if (!val) {
         this.resetPayForm = {
-          momey: null,
+          momey: null
         };
       }
     },
@@ -1020,7 +1027,7 @@ export default {
       if (!val) {
         this.$refs.timerForm.resetFields();
       }
-    },
+    }
   },
   computed: {
     payendTimer: () => {
@@ -1035,13 +1042,13 @@ export default {
           } else {
             return time.getTime() + 86400000 <= new Date().getTime();
           }
-        },
+        }
       };
-    },
-  },
+    }
+  }
 };
 </script>
-<style lang='scss' scoped>
+<style lang="scss" scoped>
 .studenTable {
   height: 300px;
   overflow: auto;
@@ -1099,16 +1106,16 @@ export default {
 .inputStyle {
   width: 180px;
 }
-  .demo-table-expand {
-    font-size: 0;
-  }
-  .demo-table-expand label {
-    width: 90px;
-    color: #99a9bf;
-  }
-  .demo-table-expand .el-form-item {
-    margin-right: 0;
-    margin-bottom: 0;
-    width: 50%;
-  }
+.demo-table-expand {
+  font-size: 0;
+}
+.demo-table-expand label {
+  width: 90px;
+  color: #99a9bf;
+}
+.demo-table-expand .el-form-item {
+  margin-right: 0;
+  margin-bottom: 0;
+  width: 50%;
+}
 </style>

+ 39 - 27
src/views/resetTeaming/index.vue

@@ -5,22 +5,40 @@
         <template slot="content">
           <div class="page-headers">
             <span>{{ teamName }}</span>
-            <span class="musicGroupStatus"><img
-              :src="stepImgs[team_status]"
-              alt=""
-              v-if="stepImgs[team_status]"
-            />
-            {{ musicGroupType[team_status] }}</span>
+            <span class="musicGroupStatus"
+              ><img
+                :src="stepImgs[team_status]"
+                alt=""
+                v-if="stepImgs[team_status]"
+              />
+              {{ musicGroupType[team_status] }}</span
+            >
           </div>
         </template>
       </el-page-header>
       <div class="musicGroupOperation">
         <!-- 进行中才有乐团档案 -->
-        <span class="item" @click="gotoArchices" v-if="permission('/musicArchices') && team_status == 'PROGRESS'">
+        <span
+          class="item"
+          @click="gotoArchices"
+          v-if="permission('/musicArchices') && team_status == 'PROGRESS'"
+        >
           乐团档案
         </span>
-        <i class="line" v-if="permission('/musicArchices') && team_status == 'PROGRESS' && permission('recharge/findAll')"></i>
-        <span class="item" @click="journalVisible = true" v-if="permission('recharge/findAll')">操作日志</span>
+        <i
+          class="line"
+          v-if="
+            permission('/musicArchices') &&
+              team_status == 'PROGRESS' &&
+              permission('recharge/findAll')
+          "
+        ></i>
+        <span
+          class="item"
+          @click="journalVisible = true"
+          v-if="permission('recharge/findAll')"
+          >操作日志</span
+        >
         <!-- <div
           class="hearConcat"`
           @click="gotoArchices"
@@ -97,7 +115,7 @@
           name="2"
           :disabled="!teamid"
         >
-          <resetSound v-if="activeIndex == '2'"    @handleClick="handleClick"/>
+          <resetSound v-if="activeIndex == '2'" @handleClick="handleClick" />
         </el-tab-pane>
         <el-tab-pane
           label="缴费设置"
@@ -221,12 +239,7 @@
         </el-tab-pane>
 
         <!--   v-if="permission('/resetTeaming/coursePlan')" -->
-        <el-tab-pane
-          label="转换记录"
-          :disabled="!teamid"
-          name="14"
-
-        >
+        <el-tab-pane label="转换记录" :disabled="!teamid" name="14">
           <convertList :teamid="teamid" v-if="activeIndex == 14" />
         </el-tab-pane>
       </tab-router>
@@ -255,7 +268,7 @@ import forecastNameList from "@/views/teamBuild/forecastNameList";
 import musicOrder from "@/views/teamDetail/teamDetailedList";
 import teamJournal from "@/views/teamBuild/components/teamJournal";
 import teamRemainTime from "@/views/teamBuild/components/teamRemainTime";
-import convertList from '@/views/teamDetail/components/convertList'
+import convertList from "@/views/teamDetail/components/convertList";
 import merge from "webpack-merge";
 import { permission } from "@/utils/directivePage";
 import { getTeamBaseInfo } from "@/api/buildTeam";
@@ -316,8 +329,8 @@ export default {
         FEE_AUDIT_FAILED: require("./images/6.png"),
         APPLY: require("./images/4.png"),
         PAY: require("./images/12.png"),
-        PREPARE: require("./images/11.png"),
-      },
+        PREPARE: require("./images/11.png")
+      }
     };
   },
   created() {
@@ -358,7 +371,7 @@ export default {
       this.teamid = this.$route.query.id;
       this.team_status = this.$route.query.team_status;
       if (this.$route.query.tabrouter != 1 && this.teamid) {
-        getTeamBaseInfo({ musicGroupId: this.teamid }).then((res) => {
+        getTeamBaseInfo({ musicGroupId: this.teamid }).then(res => {
           if (res.code == 200) {
             this.getBaseInfo(res.data);
           }
@@ -385,8 +398,8 @@ export default {
         this.$router.push({
           query: merge(this.$route.query, {
             ...this.$route.query,
-            team_status: this.musicGroupInfo.status,
-          }),
+            team_status: this.musicGroupInfo.status
+          })
         });
         this.team_status = this.$route.query.team_status;
         // console.log(this.musicGroupInfo.status);
@@ -439,9 +452,9 @@ export default {
       console.log("跳转");
       this.$router.push({
         path: "/business/musicArchices",
-        query: { ...this.$route.query },
+        query: { ...this.$route.query }
       });
-    },
+    }
   },
   watch: {
     //  async activeIndex(val){
@@ -449,7 +462,7 @@ export default {
     //       await this.$refs.teamBaseInfo.setStore();
     //     }
     //   }
-  },
+  }
 };
 </script>
 <style lang="scss" scoped>
@@ -485,7 +498,7 @@ export default {
     display: inline-block;
     width: 1px;
     height: 16px;
-    background: #DDDFE6;
+    background: #dddfe6;
     margin: 0 10px;
     padding: 0;
   }
@@ -553,4 +566,3 @@ export default {
   align-items: center;
 }
 </style>
-

+ 4 - 2
src/views/resetTeaming/modals/courseModel.vue

@@ -15,7 +15,8 @@
     <h2
       class="titles"
       v-if="
-        (courseViewType == 0 || courseViewType == 2) && courseInfo.length > 0
+        (courseViewType == 0 || courseViewType == 2 || courseViewType == 3) &&
+          courseInfo.length > 0
       "
     >
       <img :src="trainSmallBg" />
@@ -27,7 +28,8 @@
       <div
         class="section"
         v-if="
-          (courseViewType == 0 || courseViewType == 2) && courseInfo.length > 0
+          (courseViewType == 0 || courseViewType == 2 || courseViewType == 3) &&
+            courseInfo.length > 0
         "
       >
         <el-row class="title-row">

+ 25 - 20
src/views/resetTeaming/modals/payTeamCourse.vue

@@ -10,8 +10,8 @@
           {
             required: true,
             message: '请选择加课方式',
-            trigger: 'change',
-          },
+            trigger: 'change'
+          }
         ]"
       >
         <!-- &&courseViewType != 2 -->
@@ -34,8 +34,8 @@
           {
             required: true,
             message: '请选择收费标准',
-            trigger: 'change',
-          },
+            trigger: 'change'
+          }
         ]"
       >
         <el-select
@@ -53,7 +53,12 @@
           </el-option>
         </el-select>
       </el-form-item>
-      <el-form-item label="是否展示" prop="isShowMusicCourseForPay" v-if="allCourseCurrentPrice==0"  class="titleFormItem">
+      <el-form-item
+        label="是否展示"
+        prop="isShowMusicCourseForPay"
+        v-if="allCourseCurrentPrice == 0"
+        class="titleFormItem"
+      >
         <el-select
           style="width: 100% !important"
           v-model="form.isShowMusicCourseForPay"
@@ -92,7 +97,7 @@
             :rules="{
               required: true,
               message: '请选择课程类型',
-              trigger: 'change',
+              trigger: 'change'
             }"
           >
             <el-select
@@ -127,8 +132,8 @@
               {
                 required: true,
                 message: '请输入课程时长',
-                trigger: 'blur',
-              },
+                trigger: 'blur'
+              }
             ]"
           >
             <el-input-number
@@ -174,7 +179,7 @@
             :rules="{
               required: true,
               message: '请输入售价',
-              trigger: 'blur',
+              trigger: 'blur'
             }"
           >
             <!-- $listeners.moneyChange -->
@@ -203,7 +208,7 @@
             :rules="{
               required: true,
               message: '请输入原价',
-              trigger: 'blur',
+              trigger: 'blur'
             }"
           >
             <el-input-number
@@ -248,7 +253,7 @@ export default {
       courseType,
       courseTypeOptions: this.courseUnitPriceSettingsByType,
       boolOptionsOptions: objectToOptions(boolOptions),
-      showisMusicGroupFee :false
+      showisMusicGroupFee: false
     };
   },
   mounted() {},
@@ -256,26 +261,26 @@ export default {
     courseItemChange(row, index) {},
     priceChange(row, index) {},
     isOptionDisabled(key) {
-      const selected = this.form.eclass.map((item) => item.courseType);
+      const selected = this.form.eclass.map(item => item.courseType);
       return selected.includes(key);
     },
-    change() {},
+    change() {}
   },
   computed: {
     isDisabled() {
       return this.form.leixing == 1;
     },
-    allCourseCurrentPrice(){
-      let price = 0
+    allCourseCurrentPrice() {
+      let price = 0;
       this.form.eclass.forEach(element => {
-        price+=element.courseCurrentPrice
+        price += element.courseCurrentPrice;
       });
-      if(price >0){
-        this.form.isShowMusicCourseForPay = true
+      if (price > 0) {
+        this.form.isShowMusicCourseForPay = true;
       }
-      return price
+      return price;
     }
-  },
+  }
 };
 </script>
 <style lang="scss" scoped>

+ 11 - 3
src/views/resetTeaming/modals/subject-preview.vue

@@ -213,14 +213,13 @@ export default {
       authStatus: false,
       ids: [],
       instrumentResultList: [],
-      chargeTypeId: null,
       paymentStatus: null,
       paymentPattern: null,
       serviceValidDate: null, // 服务时间
       courseShowStatus: false,
       chargeTypeList: [],
       chargeTypeName: null,
-      courseViewType: 0, // 收费模式,0 课程显示,1 AMR系统 2会员
+      courseViewType: 0, // 收费模式,0 课程显示,1 AMR系统 2会员 3免费
       leBaoStatus: false,
       buyMaintenance: false, // 是否开启乐保
       isClickStatus: false,
@@ -272,7 +271,6 @@ export default {
               isShowVipCourseForPay: true,
               isShowMusicCourseForPay: true
             };
-
       this.courseViewType = tempResult.musicGroup.courseViewType || 0;
       this.isGiveAccessories =
         (tempResult.musicGroup && tempResult.musicGroup.isGiveAccessories) ||
@@ -495,6 +493,16 @@ export default {
 
       // 初始化计算金额
       this.calcPrice();
+
+      console.log({
+        toolsPackage: this.toolsPackage,
+        instrumentRepair: this.instrumentRepair,
+        activityList: this.activityList,
+        courseInfo: this.courseInfo,
+        instrumentResult: this.instrumentResult,
+        accessOries: this.accessOries,
+        musicGroupSubject: this.musicGroupSubject
+      });
     },
     groupBy(array, f) {
       var groups = {};

+ 72 - 72
src/views/resetTeaming/modals/user-pay-form.vue

@@ -1,4 +1,5 @@
 <template>
+  <!-- 这个页面暂不用 -->
   <div v-show="isShow">
     <el-alert
       title="课程信息设置"
@@ -17,7 +18,7 @@
       :isCommon="isCommon"
       v-if="
         paymentTypeString !== 'SPAN_GROUP_CLASS_ADJUST' &&
-        paymentTypeString !== 'ADD_STUDENT'
+          paymentTypeString !== 'ADD_STUDENT'
       "
       :isUserType="isUserType"
       @getCharges="getCharges"
@@ -188,8 +189,8 @@
                 :isUserType="isUserType"
                 :isDisabled="
                   form.leixing === '1' ||
-                  form.leixing === '2' ||
-                  paymentType == '0'
+                    form.leixing === '2' ||
+                    paymentType == '0'
                 "
               />
             </el-collapse-item>
@@ -215,9 +216,9 @@
           "
           :isDisabled="
             form.leixing === '1' ||
-            form.leixing === '2' ||
-            paymentType === '0' ||
-            form.leixing === '3'
+              form.leixing === '2' ||
+              paymentType === '0' ||
+              form.leixing === '3'
           "
           :courseViewType="courseViewType"
           v-else
@@ -249,7 +250,7 @@
 <script>
 import {
   chargeTypeList,
-  musicGroupOrganizationCourseSettingsQueryPage,
+  musicGroupOrganizationCourseSettingsQueryPage
 } from "@/api/specialSetting";
 
 import { getType } from "@/api/buildTeam";
@@ -260,7 +261,7 @@ import {
   queryByMusicGroupOrganizationCourseSettingsId,
   musicGroupPaymentCalenderView,
   musicGroupPaymentAuditListDetail,
-  musicGroupresetCalender,
+  musicGroupresetCalender
 } from "../api";
 import { paymentPatternType } from "@/constant";
 import { getTimes, objectToOptions } from "@/utils";
@@ -281,7 +282,7 @@ const paymentTypeFormat = {
   1: "MUSIC_RENEW",
   2: "ADD_COURSE",
   3: "ADD_STUDENT",
-  4: "SPAN_GROUP_CLASS_ADJUST",
+  4: "SPAN_GROUP_CLASS_ADJUST"
 };
 
 export default {
@@ -291,7 +292,7 @@ export default {
     "baseInfo",
     "paymentType",
     "rowDetail",
-    "organizationCourseUnitPriceSettings",
+    "organizationCourseUnitPriceSettings"
   ],
   components: {
     userBaseinfo,
@@ -300,7 +301,7 @@ export default {
     extraClassUser,
     classrooms,
     otherform,
-    memberSetting,
+    memberSetting
   },
   data() {
     return {
@@ -308,7 +309,7 @@ export default {
       form: {
         payUserType: this.type === "user" ? "STUDENT" : "SCHOOL",
         leixing: "1",
-        musicGroupOrganizationCourseSettingId: null,
+        musicGroupOrganizationCourseSettingId: null
       },
       chargeTypeName: "",
       other: {},
@@ -322,7 +323,7 @@ export default {
       charges: [],
       studentIds: "",
       payment: {
-        paymentPattern: null,
+        paymentPattern: null
       },
       viewDetail: null,
       organizationCourseUnitPriceSettingsByType: {},
@@ -336,11 +337,11 @@ export default {
         originalMemberPaymentAmount: "",
         paymentDate: [],
         num: "",
-        period: "",
+        period: ""
       },
       money: "",
       isSetCourseSettingsId: false,
-      isShow: false,
+      isShow: false
     };
   },
   computed: {
@@ -418,7 +419,7 @@ export default {
           this.viewDetail?.auditDto?.paymentType;
       }
       return paymentType;
-    },
+    }
   },
   watch: {
     type() {
@@ -455,9 +456,9 @@ export default {
       if (val && !this.isSetCourseSettingsId) {
         try {
           const res = await queryByMusicGroupOrganizationCourseSettingsId({
-            id: val,
+            id: val
           });
-          this.eclass = res.data.filter((item) => {
+          this.eclass = res.data.filter(item => {
             return !item.isStudentOptional || this.paymentType !== undefined;
           }) || [{}];
 
@@ -471,7 +472,7 @@ export default {
     },
     "memberForm.memberPaymentAmount"() {
       this.syncAllMoney();
-    },
+    }
   },
   mounted() {
     // console.log('leixing',this.form.leixing,'paymentType',this.paymentType )
@@ -516,7 +517,7 @@ export default {
         if (this.rowDetail.paymentType == "ADD_STUDENT") {
           try {
             const res = await getMusicGroupPaymentCalenderDetail({
-              id: this.rowDetail.id,
+              id: this.rowDetail.id
             });
             this.viewDetail = res.data;
             this.eclass = res.data.course || [];
@@ -550,11 +551,11 @@ export default {
 
             this.$set(this.memberForm, "memberValidDate", [
               this.viewDetail.calender.startPaymentDate,
-              this.viewDetail.calender.deadlinePaymentDate,
+              this.viewDetail.calender.deadlinePaymentDate
             ]);
             this.$set(this.cycle, "paymentDate", [
               this.viewDetail.calender.startPaymentDate,
-              this.viewDetail.calender.deadlinePaymentDate,
+              this.viewDetail.calender.deadlinePaymentDate
             ]);
 
             this.$set(this.other, "memo", this.viewDetail.calender.memo);
@@ -566,26 +567,27 @@ export default {
           try {
             const res = await musicGroupPaymentAuditListDetail({
               musicGroupId: this.musicGroupId,
-              batchNo: this.rowDetail.batchNo,
+              batchNo: this.rowDetail.batchNo
             });
             this.viewDetail = res.data;
             // this.$set(this.other, "memo", this.viewDetail.auditDto.memo);
             const firstPayment = res.data.musicGroupPaymentCalenders[0] || {};
             this.eclass = (
               res.data.musicGroupPaymentCalenderCourseSettings || []
-            ).filter((item) => {
+            ).filter(item => {
               return !item.isStudentOptional || this.paymentType !== undefined;
             });
-            this.eclassuser =
-              res.data.musicGroupPaymentCalenderStudentDetails.map((item) => {
+            this.eclassuser = res.data.musicGroupPaymentCalenderStudentDetails.map(
+              item => {
                 if (this.paymentTypeString === "SPAN_GROUP_CLASS_ADJUST") {
                   return {
-                    ...item,
+                    ...item
                     // courseOriginalPrice: item.masterSubCoursePrice,
                   };
                 }
                 return item;
-              });
+              }
+            );
             this.$set(
               this.payment,
               "paymentPattern",
@@ -602,12 +604,12 @@ export default {
               );
               let arr = [
                 firstPayment.paymentValidStartDate,
-                firstPayment.paymentValidEndDate,
+                firstPayment.paymentValidEndDate
               ];
               // paymentDate startPaymentDate deadlinePaymentDate
               this.$set(this.cycle, "paymentDate", [
                 firstPayment.startPaymentDate,
-                firstPayment.deadlinePaymentDate,
+                firstPayment.deadlinePaymentDate
               ]);
               this.$set(this.cycle, "paymentValid", arr);
             }
@@ -625,7 +627,7 @@ export default {
 
               this.$set(this.memberForm, "paymentDate", [
                 dayjs(firstPayment.startPaymentDate).format("YYYY-MM-DD"),
-                dayjs(firstPayment.deadlinePaymentDate).format("YYYY-MM-DD"),
+                dayjs(firstPayment.deadlinePaymentDate).format("YYYY-MM-DD")
               ]);
             }
             this.syncAllMoney();
@@ -639,7 +641,7 @@ export default {
       const chargeTypeId = this.musicGroup?.chargeTypeId;
       const _ = {};
       const list = (this.organizationCourseUnitPriceSettings || []).filter(
-        (item) =>
+        item =>
           organId &&
           organId == item.organId &&
           chargeTypeId &&
@@ -668,8 +670,8 @@ export default {
     },
     syncAllMoney() {
       if (this.paymentTypeString === "SPAN_GROUP_CLASS_ADJUST") {
-        const money =
-          this.viewDetail?.musicGroupPaymentCalenders[0].paymentAmount;
+        const money = this.viewDetail?.musicGroupPaymentCalenders[0]
+          .paymentAmount;
         this.$set(this.cycle, "paymentAmount", money);
         return money;
       }
@@ -699,7 +701,7 @@ export default {
         this.cycles = this.cycles.map((item, index) => {
           return {
             ...item,
-            paymentAmount: index === 0 ? first : other,
+            paymentAmount: index === 0 ? first : other
           };
         });
       }
@@ -714,8 +716,7 @@ export default {
     },
     async getChargeTypeList() {
       try {
-        const res = await getType({
-        });
+        const res = await getType({});
         this.typeList = res.data;
       } catch (error) {}
     },
@@ -727,9 +728,9 @@ export default {
         const res = await musicGroupOrganizationCourseSettingsQueryPage({
           row: 9999,
           chargeTypeId,
-          organId,
+          organId
         });
-        const ids = res.data.rows.map((item) => item.id);
+        const ids = res.data.rows.map(item => item.id);
         if (!ids.includes(this.form.musicGroupOrganizationCourseSettingId)) {
           this.$set(this.form, "musicGroupOrganizationCourseSettingId", null);
         }
@@ -746,7 +747,7 @@ export default {
     },
     removeExtraClass(index) {
       this.eclass[index] = null;
-      this.eclass = this.eclass.filter((item) => !!item);
+      this.eclass = this.eclass.filter(item => !!item);
     },
     addCycle() {
       this.cycles.push({});
@@ -755,7 +756,7 @@ export default {
     },
     removeCycle(index) {
       this.cycles[index] = null;
-      this.cycles = this.cycles.filter((item) => !!item);
+      this.cycles = this.cycles.filter(item => !!item);
       if (this.collapse.includes(index)) {
         this.collapse.splice(index, 1);
         this.collapse = this.collapse.map((item, _index) =>
@@ -780,10 +781,10 @@ export default {
         ...(refs.cycles || []),
         refs.other,
         refs.payment,
-        refs.memberSetting,
+        refs.memberSetting
       ]
-        .filter((item) => !!item)
-        .map((item) => item.$refs.form || item);
+        .filter(item => !!item)
+        .map(item => item.$refs.form || item);
     },
     changeActive(val) {
       if (this.$listeners.changeActive) {
@@ -794,7 +795,7 @@ export default {
       const forms = this.getForms();
       const valided = [];
       for (const form of forms) {
-        form.validate((valid) => {
+        form.validate(valid => {
           if (valid) {
             valided.push(form);
           }
@@ -816,15 +817,15 @@ export default {
             calenderMember: {
               ...this.memberForm,
               actualAmount: this.memberForm.memberPaymentAmount,
-              originalAmount: this.memberForm.originalMemberPaymentAmount,
+              originalAmount: this.memberForm.originalMemberPaymentAmount
             },
             calenderAddStudent: {
               classGroupIds: this.viewDetail.calender.attribute1,
-              studentIds: this.viewDetail.calender.studentIds,
+              studentIds: this.viewDetail.calender.studentIds
             },
             ...getTimes(this.cycle.paymentDate, [
               "startPaymentDate",
-              "deadlinePaymentDate",
+              "deadlinePaymentDate"
             ]),
             // paymentPattern: this.payment.paymentPattern,
             musicGroupId: this.musicGroupId,
@@ -832,10 +833,10 @@ export default {
             payUserType: "STUDENT",
 
             musicGroupPaymentCalenderCourseSettingsList: this.eclass,
-            ...this.other,
+            ...this.other
           };
           try {
-          const res =  await musicGroupresetCalender(data);
+            const res = await musicGroupresetCalender(data);
 
             if (res.code == 200) {
               this.$message.success("提交成功");
@@ -847,12 +848,12 @@ export default {
                 res.msg || `当前乐团存在未排课的缴费项目,请再次确认操作`,
                 "提示",
                 {
-                  type: "warning",
+                  type: "warning"
                 }
               );
               data.confirmCreate = true;
               await musicGroupresetCalender(data);
-               this.$message.success("提交成功");
+              this.$message.success("提交成功");
               this.$listeners.submited();
               this.$listeners.close();
             }
@@ -867,24 +868,24 @@ export default {
 
             // paymentPattern: this.payment.paymentPattern,
             musicGroupPaymentDateRangeList: [
-              ...this.cycles.map((item) => {
+              ...this.cycles.map(item => {
                 const { paymentDate, paymentValid, ...other } = item;
                 return {
                   ...other,
                   ...getTimes(paymentDate, [
                     "startPaymentDate",
-                    "deadlinePaymentDate",
+                    "deadlinePaymentDate"
                   ]),
                   ...getTimes(paymentValid, [
                     "paymentValidStartDate",
-                    "paymentValidEndDate",
-                  ]),
+                    "paymentValidEndDate"
+                  ])
                 };
-              }),
+              })
             ],
 
             musicGroupPaymentCalenderCourseSettingsList: this.eclass,
-            musicGroupPaymentCalenderStudentDetails: this.eclassuser,
+            musicGroupPaymentCalenderStudentDetails: this.eclassuser
           };
           // 如果是会员团续费 则添加缴费开始时间 缴费结束时间
           const { paymentDate, ...some } = this.memberForm;
@@ -892,8 +893,8 @@ export default {
             rest.musicGroupPaymentDateRangeList[0] = {
               ...getTimes(paymentDate, [
                 "startPaymentDate",
-                "deadlinePaymentDate",
-              ]),
+                "deadlinePaymentDate"
+              ])
             };
           }
 
@@ -904,13 +905,13 @@ export default {
                 ...other,
                 ...getTimes(paymentDate, [
                   "startPaymentDate",
-                  "deadlinePaymentDate",
+                  "deadlinePaymentDate"
                 ]),
                 ...getTimes(paymentValid, [
                   "paymentValidStartDate",
-                  "paymentValidEndDate",
-                ]),
-              },
+                  "paymentValidEndDate"
+                ])
+              }
             ];
           }
 
@@ -923,7 +924,7 @@ export default {
               paymentTypeFormat[
                 this.paymentType == 0 ? this.paymentType : leixing
               ],
-            musicGroupId: this.musicGroupId,
+            musicGroupId: this.musicGroupId
           };
           const info = this.viewDetail?.musicGroupPaymentCalenders[0];
           if (info && this.viewDetail?.auditDto.paymentType === "ADD_STUDENT") {
@@ -958,7 +959,7 @@ export default {
                 this.$message.success("创建成功");
                 this.$store.dispatch("delVisitedViews", this.$route);
                 this.$router.push({
-                  path: "/teamList",
+                  path: "/teamList"
                 });
               }
 
@@ -971,8 +972,7 @@ export default {
             try {
               data.batchNo = this.rowDetail.batchNo;
               // 缴费类型无法修改,按照之前覆盖
-              data.paymentType =
-                this.viewDetail.musicGroupPaymentCalenders[0]?.paymentType;
+              data.paymentType = this.viewDetail.musicGroupPaymentCalenders[0]?.paymentType;
               const res = await musicGroupPaymentCalenderDetailBatchUpdate(
                 data
               );
@@ -980,15 +980,15 @@ export default {
               this.$listeners.submited(res.data);
               if (this.$route.query.type == "teamDraft") {
                 this.$router.push({
-                  query: merge(this.$route.query, { type: "feeAudit" }),
+                  query: merge(this.$route.query, { type: "feeAudit" })
                 });
               }
             } catch (error) {}
           }
         }
       }
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="less" scoped>
@@ -1019,7 +1019,7 @@ export default {
     margin-right: 10px;
   }
 }
-::v-deep  .el-collapse-item__wrap {
+::v-deep .el-collapse-item__wrap {
   padding-top: 20px;
 }
 </style>

+ 96 - 100
src/views/teamBuild/components/soundSetComponents/soundSetCore.vue

@@ -110,7 +110,7 @@ import {
   findMusicGroupSubjectInfo,
   updateSubjectInfo,
   getSubjectGoods,
-  getTeamBaseInfo,
+  getTeamBaseInfo
 } from "@/api/buildTeam";
 import { getMusicGroupPlanMakingDetail } from "@/views/baseRulesManager/api";
 import dayjs from "dayjs";
@@ -135,7 +135,7 @@ export default {
       basdisabled: false,
       teamid: "",
       isField: true,
-      dividend:0
+      dividend: 0
     };
   },
   mounted() {
@@ -143,12 +143,12 @@ export default {
       this.teamid = this.$route.query.id;
     }
     window.addEventListener("scroll", this.getScroll);
-    this.$nextTick((res) => {
+    this.$nextTick(res => {
       this.init();
     });
-    getTeamBaseInfo({ musicGroupId: this.teamid }).then((res) => {
+    getTeamBaseInfo({ musicGroupId: this.teamid }).then(res => {
       if (res.code == 200) {
-        this.dividend = res.data.maxMusicalInstrumentsProfits
+        this.dividend = res.data.maxMusicalInstrumentsProfits;
       }
     });
   },
@@ -176,7 +176,7 @@ export default {
       this.teamStatus == "teamAudit" ||
       this.teamStatus == "feeAudit" ||
       this.teamStatus == "teamCanceled" ||
-      this.teamStatus == 'FEE_AUDIT_FAILED'
+      this.teamStatus == "FEE_AUDIT_FAILED"
     ) {
       this.basdisabled = true;
     } else {
@@ -202,13 +202,14 @@ export default {
       this.topfor =
         JSON.parse(localStorage.getItem(`${this.$route.query.id}base`)) ||
         this.$store.getters.topinfo;
+
       this.teamStatus = this.$route.query.type;
       if (
         this.teamStatus == "look" ||
         this.teamStatus == "teamAudit" ||
         this.teamStatus == "feeAudit" ||
-        this.teamStatus == "teamCanceled"||
-        this.teamStatus == 'FEE_AUDIT_FAILED'
+        this.teamStatus == "teamCanceled" ||
+        this.teamStatus == "FEE_AUDIT_FAILED"
       ) {
         this.basdisabled = true;
       } else {
@@ -218,7 +219,7 @@ export default {
         localStorage.getItem(`${this.$route.query.id}sound`)
       );
 
-      getSoundTree({ tenantId: 1 }).then(async (res) => {
+      getSoundTree({ tenantId: 1 }).then(async res => {
         if (res.code == 200) {
           this.soundList = res.data.rows;
           if (sotrage && sotrage[0]?.id) {
@@ -226,7 +227,7 @@ export default {
             this.activeSoundList = sotrage;
             let activeSound = [];
 
-            this.activeSoundList.forEach((item) => {
+            this.activeSoundList.forEach(item => {
               activeSound.push(item.id);
             });
             this.chioseActiveSound = activeSound;
@@ -239,14 +240,14 @@ export default {
               this.teamid = this.$route.query.id;
               if (this.teamid) {
                 findMusicGroupSubjectInfo({ musicGroupId: this.teamid }).then(
-                  async (res) => {
+                  async res => {
                     if (res.code == 200) {
                       // 如果没有一个声部 则请求默认声部
 
                       if (res.data?.musicGroupSubjectPlans?.length > 0) {
                         let activeSound = [];
-                        this.activeSoundList =
-                          res.data?.musicGroupSubjectPlans.map((item) => {
+                        this.activeSoundList = res.data?.musicGroupSubjectPlans.map(
+                          item => {
                             activeSound.push(item.subjectId);
                             return {
                               id: parseInt(item.subjectId),
@@ -255,45 +256,44 @@ export default {
                               chioseMusic: [],
                               markChioseList: [],
                               goodsList: [],
-                              markList: [],
+                              markList: []
                             };
-                          });
+                          }
+                        );
                         this.activeSound = activeSound;
                         this.chioseActiveSound = activeSound;
                         // 格式化商品和教辅
-                        res.data.musicGroupSubjectGoodsGroups.forEach(
-                          (shop) => {
-                            let index = findIndex(this.activeSoundList, (o) => {
-                              return o.id == shop.subjectId;
-                            });
+                        res.data.musicGroupSubjectGoodsGroups.forEach(shop => {
+                          let index = findIndex(this.activeSoundList, o => {
+                            return o.id == shop.subjectId;
+                          });
 
-                            if (index != -1) {
-                              if (shop.type == "ACCESSORIES") {
-                                shop.goodsIdList.split(",").forEach((item) => {
-                                  this.activeSoundList[
-                                    index
-                                  ].markChioseList.push(parseInt(item));
-                                });
-                              } else if (shop.type == "INSTRUMENT") {
-                                // 商品
-                                let typeJson = Object.keys(
-                                  JSON.parse(shop.kitGroupPurchaseTypeJson)
+                          if (index != -1) {
+                            if (shop.type == "ACCESSORIES") {
+                              shop.goodsIdList.split(",").forEach(item => {
+                                this.activeSoundList[index].markChioseList.push(
+                                  parseInt(item)
                                 );
+                              });
+                            } else if (shop.type == "INSTRUMENT") {
+                              // 商品
+                              let typeJson = Object.keys(
+                                JSON.parse(shop.kitGroupPurchaseTypeJson)
+                              );
 
-                                this.activeSoundList[index].chioseMusic.push({
-                                  musical: parseInt(shop.goodsIdList),
-                                  type: typeJson,
-                                  groupPrice: shop.price,
-                                  borrowPrice: shop.depositFee,
-                                  groupRemissionCourseFee: Boolean(
-                                    shop.groupRemissionCourseFee
-                                  ),
-                                  organShareProfit:shop.organShareProfit
-                                });
-                              }
+                              this.activeSoundList[index].chioseMusic.push({
+                                musical: parseInt(shop.goodsIdList),
+                                type: typeJson,
+                                groupPrice: shop.price,
+                                borrowPrice: shop.depositFee,
+                                groupRemissionCourseFee: Boolean(
+                                  shop.groupRemissionCourseFee
+                                ),
+                                organShareProfit: shop.organShareProfit
+                              });
                             }
                           }
-                        );
+                        });
                         await this.changeActiveSound(activeSound.join(","));
                       } else {
                         this.getDefaultSubject();
@@ -308,7 +308,7 @@ export default {
           }
         }
       });
-      getSubject({ tenantId: 1 }).then((res) => {
+      getSubject({ tenantId: 1 }).then(res => {
         if (res.code == 200) {
           this.childSoundList = res.data;
         }
@@ -319,23 +319,23 @@ export default {
       let section = this.topfor.section;
       let musicGroupPlanMakingId = this.topfor.musicGroupPlanMakingId;
       getMusicGroupPlanMakingDetail({
-        id: musicGroupPlanMakingId,
-      }).then(async (res) => {
+        id: musicGroupPlanMakingId
+      }).then(async res => {
         if (res.code == 200) {
           let activeSound = [];
           this.activeSoundList = [];
-          if(res.data?.subjectMap){
-          for (let key in res.data.subjectMap) {
-            console.log(key, "key", res.data.subjectMap[key], "name");
-            activeSound.push(key * 1);
-            this.activeSoundList.push(
-              this.initSound({
-                id: key * 1,
-                name: res.data.subjectMap[key],
-              })
-            );
+          if (res.data?.subjectMap) {
+            for (let key in res.data.subjectMap) {
+              console.log(key, "key", res.data.subjectMap[key], "name");
+              activeSound.push(key * 1);
+              this.activeSoundList.push(
+                this.initSound({
+                  id: key * 1,
+                  name: res.data.subjectMap[key]
+                })
+              );
+            }
           }
-        }
           // this.activeSoundList = res.data.map((item) => {
           //   activeSound.push(item.id);
           //   return this.initSound(item);
@@ -359,7 +359,7 @@ export default {
           newSoundList.push(this.initSound(this.childSoundList[i]));
         }
       }
-      let idList = this.activeSoundList.map((item) => {
+      let idList = this.activeSoundList.map(item => {
         return item.id;
       });
       for (let x in newSoundList) {
@@ -370,7 +370,7 @@ export default {
       }
       this.activeSoundList = newSoundList;
       let newActiveSound = [];
-      this.activeSoundList.forEach((item) => {
+      this.activeSoundList.forEach(item => {
         newActiveSound.push(item.id);
       });
       this.activeSound = newActiveSound;
@@ -389,12 +389,12 @@ export default {
             type: [],
             groupPrice: 0,
             borrowPrice: 1500,
-            groupRemissionCourseFee: Boolean(item.groupRemissionCourseFee),
-          },
+            groupRemissionCourseFee: Boolean(item.groupRemissionCourseFee)
+          }
         ],
         markChioseList: [],
         goodsList: [],
-        markList: [],
+        markList: []
       };
       return obj;
     },
@@ -404,16 +404,16 @@ export default {
         subjectIds: val,
         chargeTypeId: this.topfor.type,
         musicGroupId: this.teamid,
-        courseViewType: this.topfor.courseViewType,
-      }).then((res) => {
+        courseViewType: this.topfor.courseViewType
+      }).then(res => {
         if (res.code == 200) {
           if (res.data) {
             let keys = Object.keys(res.data);
-            this.activeSoundList.forEach((item) => {
+            this.activeSoundList.forEach(item => {
               if (keys.indexOf(item.id + "") != -1) {
                 let goodList = [];
                 let markList = [];
-                res.data[item.id].forEach((shop) => {
+                res.data[item.id].forEach(shop => {
                   if (shop.type == "INSTRUMENT") {
                     goodList.push(shop);
                   } else if (shop.type == "ACCESSORIES") {
@@ -434,12 +434,12 @@ export default {
       let loadash = this.$helpers.lodash;
       let errorShop = [];
       let flag = false;
-      this.activeSoundList.forEach((item) => {
+      this.activeSoundList.forEach(item => {
         // 格式化教辅
-        let markIdList = item.markList.map((mark) => {
+        let markIdList = item.markList.map(mark => {
           return mark.id;
         });
-        let goodsIdList = item.goodsList.map((good) => {
+        let goodsIdList = item.goodsList.map(good => {
           return good.id;
         });
         for (let i = 0; i < item.markChioseList.length; i++) {
@@ -482,7 +482,7 @@ export default {
         return;
       }
 
-      this.activeSoundList.forEach((item) => {
+      this.activeSoundList.forEach(item => {
         if (!item.expectedStudentNum) {
           this.$message.error(`请填写${item.sound}的预计招生人数`);
           flag = false;
@@ -493,7 +493,7 @@ export default {
         //   flag = false;
         //   return;
         // }
-        item.chioseMusic.forEach((music) => {
+        item.chioseMusic.forEach(music => {
           if (music.type.indexOf("LEASE") != -1) {
             if (!music.borrowPrice || parseFloat(music.borrowPrice) <= 0) {
               this.$message.error(`请填写正确的${item.sound}租赁押金`);
@@ -520,7 +520,7 @@ export default {
       obj.musicGroupSubjectGoodsGroups = [];
       obj.musicGroupSubjectPlans = [];
       let noMusic = [];
-      this.activeSoundList.forEach((active) => {
+      this.activeSoundList.forEach(active => {
         if (!active.chioseMusic[0]?.musical) {
           noMusic.push(active.sound);
         }
@@ -528,13 +528,12 @@ export default {
         let item = {
           expectedStudentNum: active.expectedStudentNum,
           subName: active.sound,
-          subjectId: active.id,
-
+          subjectId: active.id
         };
         obj.musicGroupSubjectPlans.push(item);
         // 格式化商品数据 chioseMusic: [{ musical: '', type: ["GROUP"], groupPrice: 0, borrowPrice: 1500 }],
 
-        active.chioseMusic.forEach((music) => {
+        active.chioseMusic.forEach(music => {
           let goodsItem = null;
           let depositFee = music.borrowPrice;
           let price = music.groupPrice;
@@ -546,14 +545,14 @@ export default {
             groupRemissionCourseFee = 0;
           }
 
-          let index = findIndex(active.goodsList, (o) => {
+          let index = findIndex(active.goodsList, o => {
             return o.id == music.musical;
           });
           if (index != -1) {
             goodsItem = active.goodsList[index];
           }
           let kitGroupPurchaseTypeJson = {};
-          music.type.forEach((type) => {
+          music.type.forEach(type => {
             kitGroupPurchaseTypeJson[type] = 0;
           });
           // if (Array.isArray(music.type)) {
@@ -587,8 +586,8 @@ export default {
         //  markChioseList: [],
         // goodsList: [],
         // markList: [],
-        active.markChioseList.forEach((ass) => {
-          let index = findIndex(active.markList, (o) => {
+        active.markChioseList.forEach(ass => {
+          let index = findIndex(active.markList, o => {
             return o.id == ass;
           });
           let goodsItem = null;
@@ -601,7 +600,7 @@ export default {
               type: "ACCESSORIES",
               goodsIdList: ass,
               name: goodsItem.name,
-              price: goodsItem.groupPurchasePrice,
+              price: goodsItem.groupPurchasePrice
             };
             obj.musicGroupSubjectGoodsGroups.push(some);
           }
@@ -629,23 +628,21 @@ export default {
           this.$confirm(str, "提示", {
             confirmButtonText: "确定",
             cancelButtonText: "取消",
-            type: "warning",
+            type: "warning"
           })
             .then(() => {
-              updateSubjectInfo(obj).then((res) => {
+              updateSubjectInfo(obj).then(res => {
                 if (res.code == 200) {
                   this.$message.success("提交成功");
 
-                  if(type== 3){
-
-                    this.$emit('chiosetab',type)
-                  }else{
+                  if (type == 3) {
+                    this.$emit("chiosetab", type);
+                  } else {
                     this.$store.dispatch("delVisitedViews", this.$route);
                     this.$router.push({
-                    path: "/teamList",
-                  });
+                      path: "/teamList"
+                    });
                   }
-
                 }
               });
             })
@@ -662,9 +659,9 @@ export default {
           this.$confirm(str, "提示", {
             confirmButtonText: "确定",
             cancelButtonText: "取消",
-            type: "warning",
+            type: "warning"
           }).then(() => {
-            updateSubjectInfo(obj).then((res) => {
+            updateSubjectInfo(obj).then(res => {
               if (res.code == 200) {
                 this.setStore();
                 if (type == 1) {
@@ -674,8 +671,8 @@ export default {
                   this.$router.push({
                     path: "/teamList",
                     query: {
-                      ...query,
-                    },
+                      ...query
+                    }
                   });
                 } else {
                   this.$message.success("保存成功");
@@ -696,7 +693,7 @@ export default {
       this.$confirm("确定删除选中声部?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
           for (let i = 0; i < this.activeSoundList.length; i++) {
@@ -727,7 +724,6 @@ export default {
     //   obj.musicGroup = {
     //     settlementType: this.topfor.salary,
     //     applyExpireDate: dayjs(this.topfor.time).format("YYYY-MM-DD HH:mm:ss"),
-    //     chargeTypeId: this.topfor.type,
     //     cooperationOrganId: this.topfor.school,
     //     courseViewType: this.topfor.courseViewType,
     //     teamTeacherId: this.topfor.boss,
@@ -764,7 +760,7 @@ export default {
       } else {
         this.isField = true;
       }
-    },
+    }
   },
   watch: {
     activeSoundList: {
@@ -786,9 +782,9 @@ export default {
           PlannedCount = Count;
           this.$emit("getNumber", chioseSoundNum, PlannedCount);
         }
-      },
-    },
-  },
+      }
+    }
+  }
 };
 </script>
 <style lang="scss" scoped>
@@ -805,7 +801,7 @@ export default {
 }
 .soundBtnFixed {
   top: 105px;
-  left: 245px; // 205
+  left: 235px; // 205
   width: 100%;
   position: fixed;
   background-color: #fff;

+ 166 - 155
src/views/teamBuild/components/teamBaseInfo.vue

@@ -43,26 +43,6 @@
             ></el-option>
           </el-select>
         </el-form-item>
-        <el-form-item
-          label="乐团收费类型"
-          prop="type"
-          :rules="[{ required: true, message: '乐团收费类型不能为空' }]"
-        >
-          <el-select
-            v-model.trim="topFrom.type"
-            filterable
-            :disabled="basdisabled"
-            clearable
-            @change="changeType"
-          >
-            <el-option
-              v-for="(item, index) in typeList"
-              :key="index"
-              :label="item.name"
-              :value="item.id"
-            ></el-option>
-          </el-select>
-        </el-form-item>
 
         <el-form-item
           label="收费模式"
@@ -116,8 +96,13 @@
             <p style="position: relative; display: inline-block">
               教学地点
               <el-tooltip placement="top" popper-class="mTooltip">
-                <div slot="content">如果已生成课表,则会修改未上课时的教学点</div>
-                <i class="el-icon-question" style="font-size: 18px; color: #f56c6c"></i>
+                <div slot="content">
+                  如果已生成课表,则会修改未上课时的教学点
+                </div>
+                <i
+                  class="el-icon-question"
+                  style="font-size: 18px; color: #f56c6c"
+                ></i>
               </el-tooltip>
             </p>
           </template>
@@ -219,8 +204,15 @@
 
           </el-select>
         </el-form-item> -->
-        <el-form-item label="机构类型" prop="ownershipType" v-if="tenantId == 1">
-          <el-select v-model.trim="topFrom.ownershipType" :disabled="basdisabled">
+        <el-form-item
+          label="机构类型"
+          prop="ownershipType"
+          v-if="tenantId == 1"
+        >
+          <el-select
+            v-model.trim="topFrom.ownershipType"
+            :disabled="basdisabled"
+          >
             <el-option label="自有" value="OWN"></el-option>
             <el-option label="三方" value="COOPERATION"></el-option>
             <!-- <el-option label="租赁"
@@ -250,7 +242,12 @@
           prop="teacher"
           :rules="[{ required: true, message: '乐团主管不能为空' }]"
         >
-          <el-select v-model.trim="topFrom.teacher" :disabled="true" filterable clearable>
+          <el-select
+            v-model.trim="topFrom.teacher"
+            :disabled="true"
+            filterable
+            clearable
+          >
             <el-option
               v-for="(item, key) in educationList"
               :key="key"
@@ -375,8 +372,8 @@
               {
                 pattern: /(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/,
                 message: '请输入正确的金额',
-                trigger: 'blur',
-              },
+                trigger: 'blur'
+              }
             ]"
           >
             <el-input
@@ -384,7 +381,9 @@
               placeholder="请输入收费标准"
               :disabled="basdisabled"
             >
-              <i slot="suffix" class="el-input__icon" style="padding-right: 5px">元</i>
+              <i slot="suffix" class="el-input__icon" style="padding-right: 5px"
+                >元</i
+              >
             </el-input>
           </el-form-item>
           <el-form-item
@@ -394,8 +393,8 @@
               { required: true, message: '请输入单次训练时长' },
               {
                 pattern: /(^[0-9+]*$)/,
-                message: '请输入正确的时长',
-              },
+                message: '请输入正确的时长'
+              }
             ]"
           >
             <el-select
@@ -467,16 +466,22 @@
               filterable
               :disabled="basdisabled"
               clearable
-              @change="()=>{
-                topFrom.chargeMode =''
-              }"
+              @change="
+                () => {
+                  topFrom.chargeMode = '';
+                }
+              "
             >
               <el-option label="学校" value="SCHOOL"></el-option>
               <el-option label="学员" value="STUDENT"></el-option>
               <el-option label="第三方" value="THIRDPARTY"></el-option>
             </el-select>
           </el-form-item>
-          <el-form-item label="计费方式" prop="chargeMode" v-if="topFrom.paymentUserType != 'STUDENT'">
+          <el-form-item
+            label="计费方式"
+            prop="chargeMode"
+            v-if="topFrom.paymentUserType != 'STUDENT'"
+          >
             <el-select
               v-model.trim="topFrom.chargeMode"
               filterable
@@ -515,7 +520,10 @@
                 <div slot="content">
                   学员提交乐团课后作业时,群聊中是否发送作业提交消息
                 </div>
-                <i class="el-icon-question" style="font-size: 18px; color: #f56c6c"></i>
+                <i
+                  class="el-icon-question"
+                  style="font-size: 18px; color: #f56c6c"
+                ></i>
               </el-tooltip>
             </p>
           </template>
@@ -538,7 +546,10 @@
               是否赠送辅件
               <el-tooltip placement="top" popper-class="mTooltip">
                 <div slot="content">购买团练宝是否赠送辅件</div>
-                <i class="el-icon-question" style="font-size: 18px; color: #f56c6c"></i>
+                <i
+                  class="el-icon-question"
+                  style="font-size: 18px; color: #f56c6c"
+                ></i>
               </el-tooltip>
             </p>
           </template>
@@ -581,12 +592,12 @@
             >课堂课乐团</el-checkbox
           >
         </el-form-item> -->
-        <br />
-        <el-form-item label="" v-if="teamStatus == 'teamDraft'">
+        <!-- <br /> -->
+        <!-- <el-form-item label="" v-if="teamStatus == 'teamDraft'">
           <p style="color: red; padding-left: 50px">
             修改【收费类型】会重置乐团声部与缴费信息
           </p>
-        </el-form-item>
+        </el-form-item> -->
       </el-form>
       <div class="btnWrap">
         <!-- <div
@@ -604,7 +615,11 @@
         <div class="nextBtn" @click="gotoNext()" v-if="!basdisabled">
           {{ this.teamStatus == "teamDraft" ? "下一步" : "保存" }}
         </div>
-        <div class="nextBtn" v-if="this.teamStatus == 'teamAudit'" @click="gotoNext()">
+        <div
+          class="nextBtn"
+          v-if="this.teamStatus == 'teamAudit'"
+          @click="gotoNext()"
+        >
           下一步
         </div>
       </div>
@@ -624,7 +639,7 @@ import {
   getOrganRole,
   getTeacher,
   createTeam,
-  getGradeList,
+  getGradeList
 } from "@/api/buildTeam";
 import dayjs from "dayjs";
 import merge from "webpack-merge";
@@ -636,7 +651,7 @@ import { getMusicGroupPlanMakingList } from "@/views/baseRulesManager/api";
 import mergeMusic from "../components/merge-music";
 const singleTrainMinutesList = [
   { name: "90+90", id: "90+90" },
-  { name: "90+90+45", id: "90+90+45" },
+  { name: "90+90+45", id: "90+90+45" }
 ];
 const coursePlanList = [
   { name: "PlanS", id: "PlanS" },
@@ -644,12 +659,12 @@ const coursePlanList = [
   { name: "PlanB", id: "PlanB" },
   { name: "PlanC", id: "PlanC" },
   { name: "PlanD", id: "PlanD" },
-  { name: "PlanE", id: "PlanE" },
+  { name: "PlanE", id: "PlanE" }
 ];
 export default {
   components: {
     mergeMusic,
-    qrCode,
+    qrCode
   },
   name: "teamBaseInfo",
   props: ["getTeamList"],
@@ -694,16 +709,15 @@ export default {
         saleActivityDesc: "", // 销售活动描述
         basicStudentNum: "", // 学生基数
         paymentUserType: "", // 缴费方
-        chargeMode: "", // 计费方式
+        chargeMode: "" // 计费方式
       },
       baseInfo: {},
       money: 580,
       orderInfo: {
         marketPrice: 0, // 原价总金额
-        referencePrice: 0, // 现价总金额
+        referencePrice: 0 // 现价总金额
       }, // 金额列表,金额计算
       sectionList: [], // 分部列表
-      typeList: [], // 收费类型列表
       cooperationList: [], // 教学点列表
       teacherList: [], // 获取老师列表
       educationList: [], // 乐团主管
@@ -727,19 +741,21 @@ export default {
       paymentStatus: false,
 
       paymentForm: {
-        paymentExpireDate: null,
+        paymentExpireDate: null
         // feeType: null
       },
       paymentRules: {
         paymentExpireDate: [
-          { required: true, message: "请设置缴费截止日期", trigger: "blur" },
-        ],
+          { required: true, message: "请设置缴费截止日期", trigger: "blur" }
+        ]
       },
       extendForm: {
-        expireDate: null,
+        expireDate: null
       },
       extendRule: {
-        expireDate: [{ required: true, message: "请选择延长时间", trigger: "change" }],
+        expireDate: [
+          { required: true, message: "请选择延长时间", trigger: "change" }
+        ]
       },
       isPay: false,
       extendPaymentStatus: false, // 延长缴费
@@ -749,7 +765,7 @@ export default {
       tenantId: "",
       coursePlanList: coursePlanList,
       musicGroupPlanMakingList: [],
-      singleTrainMinutesList: singleTrainMinutesList,
+      singleTrainMinutesList: singleTrainMinutesList
     };
   },
   created() {},
@@ -817,7 +833,7 @@ export default {
             cancelButtonText: "否",
             type: "warning",
             closeOnClickModal: false,
-            distinguishCancelAndClose: true,
+            distinguishCancelAndClose: true
           })
             .then(async () => {
               // localStorage.setItem(
@@ -828,7 +844,7 @@ export default {
               console.log(b);
               return b;
             })
-            .catch((e) => {
+            .catch(e => {
               console.log(e);
               if (e == "close") {
                 return false;
@@ -849,7 +865,7 @@ export default {
       }
     },
     //|| this.teamStatus === 'teamAudit'
-    isNotEditing: function () {
+    isNotEditing: function() {
       return !(
         this.teamStatus === "teamDraft" ||
         this.teamStatus === "newTeam" ||
@@ -878,7 +894,7 @@ export default {
             return time.getTime() + 86400000 < Date.now();
             //开始时间不选时,结束时间最大值小于等于当天
           }
-        },
+        }
       };
     },
     init() {
@@ -898,7 +914,7 @@ export default {
       // }
 
       // 获取建团编制
-      getMusicGroupPlanMakingList().then((res) => {
+      getMusicGroupPlanMakingList().then(res => {
         if (res.code == 200) {
           this.musicGroupPlanMakingList = res.data;
         }
@@ -921,10 +937,12 @@ export default {
         // 单团修改
         this.teamid = this.$route.query.id;
 
-        let sotrage = JSON.parse(localStorage.getItem(`${this.$route.query.id}base`));
+        let sotrage = JSON.parse(
+          localStorage.getItem(`${this.$route.query.id}base`)
+        );
 
         if (!sotrage?.section) {
-          getTeamBaseInfo({ musicGroupId: this.teamid }).then((res) => {
+          getTeamBaseInfo({ musicGroupId: this.teamid }).then(res => {
             if (res.code == 200) {
               // if (this.$listeners.getBaseInfo) {
               //   this.$listeners.getBaseInfo(res.data);
@@ -963,25 +981,10 @@ export default {
       this.getStudentStatus();
       this.$emit("getName", this.topFrom?.name);
 
-      // getEmployeeOrgan().then((res) => {
-      //   if (res.code == 200) {
-      //     this.sectionList = res.data;
-      //   }
-      // });
-      // // 2.获取收费类型选项卡
-      // getType({ rows: 1000 }).then((res) => {
-      //   if (res.code == 200) {
-      //     this.typeList = res.data.rows;
-      //   }
-      // });
-      Promise.all([getType({ rows: 1000 }), getEmployeeOrgan()]).then((values) => {
+      Promise.all([getEmployeeOrgan()]).then(values => {
+        console.log(values, "--------");
         if (values[0].code == 200) {
-          this.typeList = values[0].data;
-          // this.typeList = [];
-        }
-        if (values[1].code == 200) {
-          this.sectionList = values[1].data;
-          // this.sectionList = [];
+          this.sectionList = values[0].data;
         }
         let arr = [];
         if (this.sectionList.length <= 0) {
@@ -990,12 +993,8 @@ export default {
           if (!this.topFrom.section) {
             this.$set(this.topFrom, "section", this.sectionList[0].id);
             this.changeSection(this.sectionList[0].id);
-            // diao
           }
         }
-        if (this.typeList.length <= 0) {
-          arr.push("teamPayType");
-        }
         this.$bus.$emit("showguide", arr);
       });
       // console.log('到这里来',getEmployeeOrgan())
@@ -1032,7 +1031,7 @@ export default {
       // 获取乐团主管
       try {
         const ruselt = await getOrganRole({
-          id: val,
+          id: val
         });
         // 乐团主管
         this.educationList = ruselt?.data?.EDUCATION;
@@ -1045,52 +1044,53 @@ export default {
         console.log(e);
       }
       // 获取指导老师
-      getTeacher({ organId: val }).then((res) => {
+      getTeacher({ organId: val }).then(res => {
         if (res.code == 200) {
           this.teacherList = res.data;
         }
       });
       // 获取年级
-      getGradeList({ id: val }).then((res) => {
+      getGradeList({ id: val }).then(res => {
         let result = res.data;
         this.gradeListObj = res.data;
         if (res.code == 200 && result) {
           for (let i in result) {
             this.gradeList.push({
               value: i,
-              label: result[i],
+              label: result[i]
             });
           }
         }
       });
-      Promise.all([queryByOrganId({ organId: val }), getSchool({ organId: val })]).then(
-        (values) => {
-          if (values[0].code == 200) {
-            this.cooperationList = values[0].data;
-          }
-          if (values[1].code == 200) {
-            this.addList = values[1].data;
-          }
-          let arr = [];
-          if (this.cooperationList.length <= 0) {
-            arr.push("cooperationOrgan");
-          }
-          if (this.addList.length <= 0) {
-            arr.push("school");
-          }
-          if (arr.length > 0) {
-            this.$bus.$emit("showguide", arr);
-            return;
-          }
+      Promise.all([
+        queryByOrganId({ organId: val }),
+        getSchool({ organId: val })
+      ]).then(values => {
+        if (values[0].code == 200) {
+          this.cooperationList = values[0].data;
         }
-      );
+        if (values[1].code == 200) {
+          this.addList = values[1].data;
+        }
+        let arr = [];
+        if (this.cooperationList.length <= 0) {
+          arr.push("cooperationOrgan");
+        }
+        if (this.addList.length <= 0) {
+          arr.push("school");
+        }
+        if (arr.length > 0) {
+          this.$bus.$emit("showguide", arr);
+          return;
+        }
+      });
     },
     chioseSchool(val) {
       // 清除教学点
       this.topFrom.teacher = null;
       if (val) {
         console.log(this.cooperationList);
-        this.cooperationList.forEach((item) => {
+        this.cooperationList.forEach(item => {
           if (item.id == val) {
             console.log(item);
             this.$set(this.topFrom, "teacher", item.educationUserId);
@@ -1164,7 +1164,6 @@ export default {
               applyExpireDate: this.topFrom.time
                 ? dayjs(this.topFrom.time).format("YYYY-MM-DD HH:mm:ss")
                 : null,
-              chargeTypeId: this.topFrom.type,
               cooperationOrganId: this.topFrom.school,
               courseViewType: this.topFrom.courseViewType,
               teamTeacherId: this.topFrom.boss,
@@ -1204,12 +1203,12 @@ export default {
               saleActivityDesc: this.topFrom.saleActivityDesc,
               basicStudentNum: this.topFrom.basicStudentNum,
               paymentUserType: this.topFrom.paymentUserType,
-              chargeMode: this.topFrom.chargeMode,
+              chargeMode: this.topFrom.chargeMode
             };
             // obj.musicGroupPaymentEntities = [];
             // createTeam
             if (this.teamStatus != "newTeam") {
-              return await resetTeamBaseInfo(obj).then(async (res) => {
+              return await resetTeamBaseInfo(obj).then(async res => {
                 if (res.code == 200) {
                   localStorage.setItem(
                     `${this.teamid}base`,
@@ -1233,7 +1232,7 @@ export default {
               });
             } else {
               // 发送建团申请 成功后跳到第二页
-              createTeam(obj).then((res) => {
+              createTeam(obj).then(res => {
                 if (res.code == 200) {
                   // this.$message.success('建团成功,请设置声部信息')
                   // this.$emit("chiosetab", 1);
@@ -1242,13 +1241,13 @@ export default {
                     title: "提示",
                     message: h("p", null, [
                       h("p", null, "新乐团基础信息创建完成"),
-                      h("p", null, "请设置声部信息"),
+                      h("p", null, "请设置声部信息")
                     ]),
                     type: "warning",
                     confirmButtonText: "是",
                     cancelButtonText: "否",
                     showCancelButton: true,
-                    customClass: "messageBox-prompt-test",
+                    customClass: "messageBox-prompt-test"
                   })
                     .then(() => {
                       this.$router.push(
@@ -1256,10 +1255,10 @@ export default {
                           query: merge(this.$route.query, {
                             type: "teamDraft",
                             id: res.data,
-                            team_status: "DRAFT",
-                          }),
+                            team_status: "DRAFT"
+                          })
                         },
-                        (router) => {
+                        router => {
                           console.log(router);
                           router.meta.title = "乐团编辑中";
                         }
@@ -1275,10 +1274,10 @@ export default {
                           query: merge(this.$route.query, {
                             type: "teamDraft",
                             id: res.data,
-                            team_status: "DRAFT",
-                          }),
+                            team_status: "DRAFT"
+                          })
                         },
-                        (router) => {
+                        router => {
                           console.log(router);
                           router.meta.title = "乐团编辑中";
                         }
@@ -1334,7 +1333,7 @@ export default {
         saleActivityDesc: "",
         paymentUserType: "",
         chargeMode: "",
-        basicStudentNum: "",
+        basicStudentNum: ""
       };
       this.$refs["topinfo"].resetFields();
     },
@@ -1346,12 +1345,12 @@ export default {
       this.$confirm(`是否确认开团?`, "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
           musicGroupFound({
-            musicGroupId: this.$route.query.id,
-          }).then((res) => {
+            musicGroupId: this.$route.query.id
+          }).then(res => {
             if (res.code == 200) {
               // let query = this.$route.query;
               // this.$message.success("开启成功");
@@ -1374,12 +1373,12 @@ export default {
       let obj = {
         musicGroupId: this.teamid,
         page: 1,
-        rows: 9999,
+        rows: 9999
       };
       if (!this.teamid) return;
-      getStudentList(obj).then((res) => {
+      getStudentList(obj).then(res => {
         if (res.code == 200) {
-          res.data.rows.forEach((item) => {
+          res.data.rows.forEach(item => {
             // '未开启缴费', '开启缴费', '已缴费'
             if (item.paymentStatus == 2) {
               this.paymentNum += 1;
@@ -1404,18 +1403,18 @@ export default {
           } else {
             return false;
           }
-        },
+        }
       };
     },
     onStartPayment(formName) {
       // 开启缴费
-      this.$refs[formName].validate((valid) => {
+      this.$refs[formName].validate(valid => {
         if (valid) {
           musicGroupOpenPay({
             musicGroupId: this.teamid,
-            expireDate: this.paymentForm.paymentExpireDate,
+            expireDate: this.paymentForm.paymentExpireDate
             // feeType: this.paymentForm.feeType
-          }).then((res) => {
+          }).then(res => {
             if (res.code == 200) {
               this.$message.success("开启成功");
               this.paymentStatus = false;
@@ -1452,7 +1451,7 @@ export default {
           } else {
             return false;
           }
-        },
+        }
       };
     },
     extendTime(isPay) {
@@ -1468,17 +1467,17 @@ export default {
       this.extendPaymentStatus = true;
     },
     onExtendPayment(formName, isPay) {
-      this.$refs[formName].validate((valid) => {
+      this.$refs[formName].validate(valid => {
         if (valid) {
           if (!isPay) {
             extensionApplyExpire({
               musicGroupId: this.teamid,
-              expireDate: this.extendForm.expireDate,
-            }).then((res) => {
+              expireDate: this.extendForm.expireDate
+            }).then(res => {
               if (res.code == 200) {
                 this.$message.success("延长报名成功");
                 this.extendPaymentStatus = false;
-                getTeamBaseInfo({ musicGroupId: this.teamid }).then((res) => {
+                getTeamBaseInfo({ musicGroupId: this.teamid }).then(res => {
                   if (res.code == 200) {
                     this.applyExpireDate = res.data.musicGroup.applyExpireDate;
                     this.setBase(res);
@@ -1491,14 +1490,15 @@ export default {
           } else {
             extensionPayment({
               musicGroupId: this.teamid,
-              expireDate: this.extendForm.expireDate,
-            }).then((res) => {
+              expireDate: this.extendForm.expireDate
+            }).then(res => {
               if (res.code == 200) {
                 this.$message.success("延长缴费成功");
                 this.extendPaymentStatus = false;
-                getTeamBaseInfo({ musicGroupId: this.teamid }).then((res) => {
+                getTeamBaseInfo({ musicGroupId: this.teamid }).then(res => {
                   if (res.code == 200) {
-                    this.paymentExpireDate = res.data.musicGroup.paymentExpireDate;
+                    this.paymentExpireDate =
+                      res.data.musicGroup.paymentExpireDate;
                   }
                 });
               } else {
@@ -1533,7 +1533,7 @@ export default {
     },
     gotoStudentList() {
       this.$router.push({
-        query: merge(this.$route.query, { tabrouter: 7 }),
+        query: merge(this.$route.query, { tabrouter: 7 })
       });
       //  this.$router.replace({query:{...this.$route.query,tabrouter:7}})
     },
@@ -1541,11 +1541,12 @@ export default {
       this.topFrom.name = res.data.musicGroup.name;
       this.$emit("getName", this.topFrom.name);
       this.topFrom.time = res.data.musicGroup.applyExpireDate;
-      this.topFrom.type = res.data.musicGroup.chargeTypeId;
       this.topFrom.startClass = res.data.musicGroup.enrollClasses.split(",");
       this.topFrom.paymentPattern = res.data.musicGroup.paymentPattern;
-      this.topFrom.paymentValidStartDate = res.data.musicGroup.paymentValidStartDate;
-      this.topFrom.paymentValidEndDate = res.data.musicGroup.paymentValidEndDate;
+      this.topFrom.paymentValidStartDate =
+        res.data.musicGroup.paymentValidStartDate;
+      this.topFrom.paymentValidEndDate =
+        res.data.musicGroup.paymentValidEndDate;
       this.topFrom.section = res.data.musicGroup.organId;
       this.topFrom.courseViewType = res.data.musicGroup.courseViewType;
       this.topFrom.school = res.data.musicGroup.cooperationOrganId;
@@ -1567,18 +1568,25 @@ export default {
         : null;
       this.paymentExpireDate = res.data.musicGroup.paymentExpireDate;
       this.applyExpireDate = res.data.musicGroup.applyExpireDate;
-      this.topFrom.transactionTeacherId = res.data.musicGroup.transactionTeacherId || "";
+      this.topFrom.transactionTeacherId =
+        res.data.musicGroup.transactionTeacherId || "";
       this.topFrom.homeworkPushFlag = res.data.musicGroup.homeworkPushFlag;
-      this.topFrom.isGiveAccessories = res.data.musicGroup.isGiveAccessories + "";
+      this.topFrom.isGiveAccessories =
+        res.data.musicGroup.isGiveAccessories + "";
       console.log(this.topFrom.isGiveAccessories, "isGiveAccessories");
-      this.topFrom.memberCourseShowFlag = res.data.musicGroup.memberCourseShowFlag
+      this.topFrom.memberCourseShowFlag = res.data.musicGroup
+        .memberCourseShowFlag
         ? 1
         : 0;
-      this.topFrom.extracurricularTeacher = res.data.musicGroup.extracurricularTeacher;
+      this.topFrom.extracurricularTeacher =
+        res.data.musicGroup.extracurricularTeacher;
 
-      this.topFrom.musicGroupPlanMakingId = res.data.musicGroup.musicGroupPlanMakingId;
-      this.topFrom.firstRecruitGrade = res.data.musicGroup.firstRecruitGrade + "";
-      this.topFrom.defaultChargeStandard = res.data.musicGroup.defaultChargeStandard;
+      this.topFrom.musicGroupPlanMakingId =
+        res.data.musicGroup.musicGroupPlanMakingId;
+      this.topFrom.firstRecruitGrade =
+        res.data.musicGroup.firstRecruitGrade + "";
+      this.topFrom.defaultChargeStandard =
+        res.data.musicGroup.defaultChargeStandard;
       this.topFrom.singleTrainMinutes = res.data.musicGroup.singleTrainMinutes;
       this.topFrom.coursePlan = res.data.musicGroup.coursePlan;
       this.topFrom.graduateGrade = res.data.musicGroup.graduateGrade + "";
@@ -1598,19 +1606,22 @@ export default {
       if (this.teamStatus == "newTeam" || this.teamStatus == "teamDraft") {
         return false;
       } else {
-        if (this.topFrom.courseViewType == 0 || this.topFrom.courseViewType == 1) {
+        if (
+          this.topFrom.courseViewType == 0 ||
+          this.topFrom.courseViewType == 1
+        ) {
           // val ==2
           return false;
         } else {
           return val == 0 || val == 1;
         }
       }
-    },
+    }
   },
   computed: {
     startClassString() {
       return this.topFrom.startClass
-        .map((item) => {
+        .map(item => {
           for (let i in this.classStatus) {
             if (item == this.classStatus[i].value) {
               return this.classStatus[i].label;
@@ -1628,8 +1639,8 @@ export default {
         teamStatus == "teamAudit" ||
         teamStatus == "feeAudit"
       );
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss">

+ 268 - 215
src/views/teamBuild/components/teamResetSound.vue

@@ -1,17 +1,15 @@
 <template>
   <div>
     <div class="listWrap">
-      <el-table :data='activeSoundList'
-                ref="multipleTable"
-                @selection-change="handleSelectionChange"
-                :header-cell-style="{background:'#EDEEF0',color:'#444'}"
-                highlight-current-row>
-        <el-table-column type="selection"
-                         width="55">
-        </el-table-column>
-        <el-table-column label="声部"
-                         width="150"
-                         prop="sound">
+      <el-table
+        :data="activeSoundList"
+        ref="multipleTable"
+        @selection-change="handleSelectionChange"
+        :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
+        highlight-current-row
+      >
+        <el-table-column type="selection" width="55"> </el-table-column>
+        <el-table-column label="声部" width="150" prop="sound">
         </el-table-column>
         <!-- <el-table-column label="乐团课程费用"
                          width="150"
@@ -28,187 +26,220 @@
         <el-table-column label="声部学员">
           <template slot-scope="scope">
             <div>
-              <el-button type="text"
-                         @click="resetStudent(scope.row)">添加</el-button>
+              <el-button type="text" @click="resetStudent(scope.row)"
+                >添加</el-button
+              >
               <!-- <el-button type="text">删除</el-button> -->
             </div>
           </template>
         </el-table-column>
       </el-table>
       <div class="floor">
-        <div class="remove"
-             @click="removeListItem">删除</div>
-        <div class='add'
-             @click="addListItem">添加</div>
+        <div class="remove" @click="removeListItem">删除</div>
+        <div class="add" @click="addListItem">添加</div>
       </div>
     </div>
-    <el-dialog title="声部选择"
-               :visible.sync="dialogTableVisible"
-               :modal-append-to-body="false">
+    <el-dialog
+      title="声部选择"
+      :visible.sync="dialogTableVisible"
+      :modal-append-to-body="false"
+    >
       <div class="soundWrap">
         <div class="itemList">
-          <div class="categroy"
-               v-for="(item,index) in soundList"
-               :key="index">
-            <p>{{item.name }}</p>
-            <el-checkbox-group v-model.trim="soundLists[index]"
-                               @change='changeList'>
-              <el-checkbox :label="sound.id"
-                           @change="checkinlist({'id':sound.id,'sound':sound.name,'yuji':0,studentList:[]})"
-                           v-for="(sound,indexs) in item.subjects"
-                           :key="indexs">{{sound.name }}</el-checkbox>
+          <div class="categroy" v-for="(item, index) in soundList" :key="index">
+            <p>{{ item.name }}</p>
+            <el-checkbox-group
+              v-model.trim="soundLists[index]"
+              @change="changeList"
+            >
+              <el-checkbox
+                :label="sound.id"
+                @change="
+                  checkinlist({
+                    id: sound.id,
+                    sound: sound.name,
+                    yuji: 0,
+                    studentList: []
+                  })
+                "
+                v-for="(sound, indexs) in item.subjects"
+                :key="indexs"
+                >{{ sound.name }}</el-checkbox
+              >
             </el-checkbox-group>
           </div>
         </div>
       </div>
-      <p class='soundSubP'>当前选择声部数:{{chioseSoundNum}}</p>
+      <p class="soundSubP">当前选择声部数:{{ chioseSoundNum }}</p>
       <div class="btnWraps">
-        <div class="dialogBtn"
-             @click="generates">确定</div>
+        <div class="dialogBtn" @click="generates">确定</div>
       </div>
     </el-dialog>
-    <el-dialog title="学员选择"
-               width="800px"
-               :visible.sync="studentVisible"
-               :modal-append-to-body="false">
+    <el-dialog
+      title="学员选择"
+      width="800px"
+      :visible.sync="studentVisible"
+      :modal-append-to-body="false"
+    >
       <div class="studentMask">
         <div class="left">
           <h4>当前已选学员</h4>
           <div class="chioseStudentList">
-            <div class="studentItem"
-                 v-for="(item,index) in activeListStudent"
-                 :key="index">
+            <div
+              class="studentItem"
+              v-for="(item, index) in activeListStudent"
+              :key="index"
+            >
               {{ item.name }}
-              <el-button type="text"
-                         @click="removeStudent(item)">删除</el-button>
+              <el-button type="text" @click="removeStudent(item)"
+                >删除</el-button
+              >
             </div>
           </div>
         </div>
         <div class="right">
-          <el-select v-model.trim="activeTeam"
-                     filterable
-                     style="width:180px"
-                     clearable
-                     @change="chioseTeam"
-                     placeholder="乐团选择">
-            <el-option v-for='(item,index) in teamList'
-                       :key="index"
-                       :label="item.name"
-                       :value="item.id"></el-option>
+          <el-select
+            v-model.trim="activeTeam"
+            filterable
+            style="width:180px"
+            clearable
+            @change="chioseTeam"
+            placeholder="乐团选择"
+          >
+            <el-option
+              v-for="(item, index) in teamList"
+              :key="index"
+              :label="item.name"
+              :value="item.id"
+            ></el-option>
           </el-select>
           <!--  multiple
                      collapse-tags -->
-          <el-select v-model.trim="activeChioseSound"
-                     style="width:180px"
-                     :disabled="!activeTeam"
-                     filterable
-                     clearable
-                     placeholder="声部选择">
-            <el-option v-for='(item,index) in chioseSoundList'
-                       :key='index'
-                       :label="item.name"
-                       :value="item.id"></el-option>
+          <el-select
+            v-model.trim="activeChioseSound"
+            style="width:180px"
+            :disabled="!activeTeam"
+            filterable
+            clearable
+            placeholder="声部选择"
+          >
+            <el-option
+              v-for="(item, index) in chioseSoundList"
+              :key="index"
+              :label="item.name"
+              :value="item.id"
+            ></el-option>
           </el-select>
-          <el-button type="danger"
-                     style="margin-left:20px;"
-                     @click="searchStudent">搜索</el-button>
+          <el-button
+            type="danger"
+            style="margin-left:20px;"
+            @click="searchStudent"
+            >搜索</el-button
+          >
 
           <!--   列表开始  -->
           <div class="tableList">
-            <el-table tooltip-effect="dark"
-                      style="width: 100%; margin-top:10px;"
-                      :data='studentList'
-                      ref='studentList'
-                      @selection-change="SelectionStudent">
-              <el-table-column type="selection"
-                               align='center'
-                               width="55">
+            <el-table
+              tooltip-effect="dark"
+              style="width: 100%; margin-top:10px;"
+              :data="studentList"
+              ref="studentList"
+              @selection-change="SelectionStudent"
+            >
+              <el-table-column type="selection" align="center" width="55">
               </el-table-column>
-              <el-table-column prop="name"
-                               align='center'
-                               width="80"
-                               label="姓名">
+              <el-table-column
+                prop="name"
+                align="center"
+                width="80"
+                label="姓名"
+              >
               </el-table-column>
-              <el-table-column prop="gender"
-                               align='center'
-                               width="55"
-                               label="性别">
+              <el-table-column
+                prop="gender"
+                align="center"
+                width="55"
+                label="性别"
+              >
               </el-table-column>
-              <el-table-column prop="musicGroupName"
-                               align='center'
-                               label="所在乐团">
+              <el-table-column
+                prop="musicGroupName"
+                align="center"
+                label="所在乐团"
+              >
               </el-table-column>
-              <el-table-column prop="soundName"
-                               align='center'
-                               label="学员声部">
+              <el-table-column prop="soundName" align="center" label="学员声部">
               </el-table-column>
             </el-table>
           </div>
-
         </div>
       </div>
-      <div slot="footer"
-           class="dialog-footer">
+      <div slot="footer" class="dialog-footer">
         <el-button @click="studentVisible = false">取 消</el-button>
-        <el-button type="primary"
-                   @click="studentVisible = false">确 定</el-button>
+        <el-button type="primary" @click="studentVisible = false"
+          >确 定</el-button
+        >
       </div>
     </el-dialog>
     <!--   @click="goback1"  @click="submitInfo1" -->
     <div class="btnWrap">
-      <div class="PrevBtn"
-           @click="goback">上一步</div>
-      <div class="submitBtn"
-           @click="submitInfo">提交</div>
+      <div class="PrevBtn" @click="goback">上一步</div>
+      <div class="submitBtn" @click="submitInfo">提交</div>
     </div>
   </div>
 </template>
 <script>
-import store from '@/store'
-import { getSubject, getDefaultSubject, getGoods, createTeam, getSoundTree, findSound, teamSoundStudent } from '@/api/buildTeam'
+import store from "@/store";
+import {
+  getSubject,
+  getDefaultSubject,
+  getGoods,
+  createTeam,
+  getSoundTree,
+  findSound,
+  teamSoundStudent
+} from "@/api/buildTeam";
 export default {
-  name: 'teamResetSound',
-  props: ['getTeamList'],
-  data () {
+  name: "teamResetSound",
+  props: ["getTeamList"],
+  data() {
     return {
       dialogTableVisible: false,
       studentVisible: false,
       checkList: [],
-      isLoop: '',
+      isLoop: "",
       activeSoundList: [],
       soundList: [],
       soundLists: [],
       changeList: [],
       multipleSelection: [], // 列表选择的集合 声部
       teamList: [], // 选择的乐团集合
-      activeTeam: '', // 选中的乐团
-      chioseSoundList: [],//根据选中的乐团id获取的声部集合
-      activeChioseSound: '', // 选中声部的集合
+      activeTeam: "", // 选中的乐团
+      chioseSoundList: [], //根据选中的乐团id获取的声部集合
+      activeChioseSound: "", // 选中声部的集合
       studentList: [], // 选择列表中的学生  展示中的列表
       activeListStudent: [], // 列表中选中的学生,
       allActiveStudent: [], // 所有选中的学生  全局
-      activeSoundId: '', //
+      activeSoundId: "", //
       Fsearch: null,
       Frules: null
-    }
+    };
   },
-  created () {
+  created() {
     this.init();
   },
-  activated () {
+  activated() {
     this.init();
   },
-  mounted () {
-
-  },
+  mounted() {},
   methods: {
-    init () {
+    init() {
       // 判断是否带缓存参数
       if (this.$route.query.search) {
         this.Fsearch = this.$route.query.search;
       }
       if (this.$route.query.rules) {
-        this.Frules = this.$route.query.rules
+        this.Frules = this.$route.query.rules;
       }
       this.teamList = this.getTeamList;
 
@@ -219,70 +250,80 @@ export default {
           this.soundList = res.data.rows;
           // // 生成动态的checkList
           for (let key in this.soundList) {
-            this.$set(this.soundLists, key, [])
+            this.$set(this.soundLists, key, []);
           }
         }
-      })
+      });
 
       this.payfor = this.$store.getters.payList;
       this.topfor = this.$store.getters.topinfo;
       this.checkfor = this.$store.getters.checkinfo;
       this.newStudentfor = this.$store.getters.newStudentinfo;
       let type = this.topfor.type;
-
     },
     // 删除声部
-    removeListItem () {
-      this.$confirm(`是否删除该声部?`, '提示', {
-        confirmButtonText: '确定',
-        cancelButtonText: '取消',
-        type: 'warning'
-      }).then(() => {
-        // 先获取选择的声部 从全局把 this.allActiveStudent
-        for (let i = 0; i < this.activeSoundList.length; i++) {
-          for (let j = 0; j < this.multipleSelection.length; j++) {
-            if (this.activeSoundList[i].id == this.multipleSelection[j].id) {
-              // 在这里把(this.activeSoundList[i]的学生释放出来
-              // console.log(this.activeSoundList[i].studentList)
-              for (let x in this.allActiveStudent) {
-                for (let y in this.activeSoundList[i].studentList) {
-                  if (this.allActiveStudent[x].userId == this.activeSoundList[i].studentList[y].userId) {
-                    this.allActiveStudent.splice(x, 1);
+    removeListItem() {
+      this.$confirm(`是否删除该声部?`, "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      })
+        .then(() => {
+          // 先获取选择的声部 从全局把 this.allActiveStudent
+          for (let i = 0; i < this.activeSoundList.length; i++) {
+            for (let j = 0; j < this.multipleSelection.length; j++) {
+              if (this.activeSoundList[i].id == this.multipleSelection[j].id) {
+                // 在这里把(this.activeSoundList[i]的学生释放出来
+                // console.log(this.activeSoundList[i].studentList)
+                for (let x in this.allActiveStudent) {
+                  for (let y in this.activeSoundList[i].studentList) {
+                    if (
+                      this.allActiveStudent[x].userId ==
+                      this.activeSoundList[i].studentList[y].userId
+                    ) {
+                      this.allActiveStudent.splice(x, 1);
+                    }
                   }
-
                 }
-              }
-              this.activeSoundList.splice(i, 1);
-              // 遍历循环所有的group 删除所选id
-              for (let key in this.soundLists) {
-                if (this.soundLists[key].indexOf(this.multipleSelection[j].id) != -1) {
-                  // console.log(this.soundLists[key], this.multipleSelection[j].id, this.soundLists[key].indexOf(this.multipleSelection[j].id));
-                  this.soundLists[key].splice(this.soundLists[key].indexOf(this.multipleSelection[j].id), 1)
+                this.activeSoundList.splice(i, 1);
+                // 遍历循环所有的group 删除所选id
+                for (let key in this.soundLists) {
+                  if (
+                    this.soundLists[key].indexOf(
+                      this.multipleSelection[j].id
+                    ) != -1
+                  ) {
+                    // console.log(this.soundLists[key], this.multipleSelection[j].id, this.soundLists[key].indexOf(this.multipleSelection[j].id));
+                    this.soundLists[key].splice(
+                      this.soundLists[key].indexOf(
+                        this.multipleSelection[j].id
+                      ),
+                      1
+                    );
+                  }
                 }
               }
             }
-
           }
-        }
-      }).catch(() => { })
-
+        })
+        .catch(() => {});
     },
-    addListItem () {
+    addListItem() {
       this.dialogTableVisible = true;
     },
     // 点击确认按钮生成表单
-    generates () {
+    generates() {
       this.dialogTableVisible = false;
     },
-    checkinlist (obj) {
+    checkinlist(obj) {
       let flag = false;
       this.activeSoundList.map(item => {
         if (item.id == obj.id) {
-          flag = true
+          flag = true;
         }
-      })
+      });
       if (!flag) {
-        this.activeSoundList.push(obj)
+        this.activeSoundList.push(obj);
       } else {
         for (let i = 0; i < this.activeSoundList.length; i++) {
           if (this.activeSoundList[i].id == obj.id) {
@@ -291,13 +332,13 @@ export default {
         }
       }
     },
-    handleSelectionChange (e) {
+    handleSelectionChange(e) {
       console.log(e);
       // 点击改变勾选
       this.multipleSelection = e;
     },
     // 点击添加学生
-    resetStudent (row) {
+    resetStudent(row) {
       // 乐团id 声部id
       this.studentVisible = true;
       this.activeSoundId = row.id;
@@ -308,22 +349,22 @@ export default {
         }
       }
     },
-    chioseTeam () {
+    chioseTeam() {
       // console.log(this.activeTeam)
       // 发请求 获取乐团下的所有声部
       findSound({ musicGroupId: this.activeTeam }).then(res => {
         if (res.code == 200) {
           this.chioseSoundList = res.data;
         }
-      })
+      });
     },
-    searchStudent () {
+    searchStudent() {
       // activeTeam activeChioseSound
       if (!this.activeTeam || !this.activeChioseSound) {
-        this.$message.error('请先选择乐团以及声部进行搜索')
+        this.$message.error("请先选择乐团以及声部进行搜索");
         return;
       }
-      console.log('开始搜素学生')
+      console.log("开始搜素学生");
       // activeSoundId 这个id里面的  studentList
       // 在这里要同步当前已选学员的的状态=>  chioseStudentList里赋值
       // 筛选学生1
@@ -334,21 +375,24 @@ export default {
           this.activeListStudent = this.activeSoundList[i].studentList;
         }
       }
-      teamSoundStudent({ musicGroupId: this.activeTeam, actualSubjectId: this.activeChioseSound }).then(res => {
+      teamSoundStudent({
+        musicGroupId: this.activeTeam,
+        actualSubjectId: this.activeChioseSound
+      }).then(res => {
         if (res.code == 200) {
           this.studentList = res.data.map(item => {
             let teamName;
             let soundName;
             this.teamList.map(team => {
               if (team.id == this.activeTeam) {
-                teamName = team.name
+                teamName = team.name;
               }
-            })
+            });
             item.soundName = this.chioseSoundList.map(sound => {
               if (sound.id == this.activeChioseSound) {
-                soundName = sound.name
+                soundName = sound.name;
               }
-            })
+            });
             item.soundName = soundName;
             item.musicGroupName = teamName;
             return item;
@@ -363,20 +407,25 @@ export default {
             }
           }
         }
-      })
+      });
     },
-    SelectionStudent (e) {
+    SelectionStudent(e) {
       // 先找到外面是哪一行的
       for (let i in this.activeSoundList) {
         if (this.activeSoundList[i].id == this.activeSoundId) {
           if (this.activeSoundList[i].studentList.length > 0) {
-            this.activeSoundList[i].studentList = this.activeSoundList[i].studentList.concat(e);
+            this.activeSoundList[i].studentList = this.activeSoundList[
+              i
+            ].studentList.concat(e);
           } else {
             this.activeSoundList[i].studentList = e;
           }
 
           // 去重
-          let result = this.objArrayRemoval(this.activeSoundList[i].studentList, 'id')
+          let result = this.objArrayRemoval(
+            this.activeSoundList[i].studentList,
+            "id"
+          );
           // console.log(result);
 
           // 不对
@@ -390,13 +439,15 @@ export default {
           } else {
             this.allActiveStudent = this.allActiveStudent.concat(result);
           }
-          this.allActiveStudent = this.objArrayRemoval(this.allActiveStudent, 'id');
+          this.allActiveStudent = this.objArrayRemoval(
+            this.allActiveStudent,
+            "id"
+          );
         }
       }
-
     },
     // 点击删除按钮 重学生集合里删除
-    removeStudent (item) {
+    removeStudent(item) {
       // 删除全局
       for (let i in this.allActiveStudent) {
         if (this.allActiveStudent[i].id == item.id) {
@@ -422,26 +473,24 @@ export default {
                 this.toggleSelection(item, this.studentList);
               } else {
                 if (item.actualSubjectId == this.activeChioseSound) {
-                  this.studentList.unshift(item)
+                  this.studentList.unshift(item);
                 }
               }
               this.activeListStudent = this.activeSoundList[i].studentList;
             }
-
           }
-
         }
       }
     },
-    toggleSelection (item, table) {
+    toggleSelection(item, table) {
       table.forEach(row => {
         if (row.id == item.id) {
-          this.$refs['studentList'].toggleRowSelection(row, false);
+          this.$refs["studentList"].toggleRowSelection(row, false);
         }
-      })
+      });
     },
     // 对象数组去重
-    objArrayRemoval (arr, attr) {
+    objArrayRemoval(arr, attr) {
       let obj = {};
       let result = [];
       // console.log(this.allActiveStudent.length);
@@ -453,65 +502,66 @@ export default {
       }
       return result;
     },
-    submitInfo () {
+    submitInfo() {
       let obj = {};
-      this.payfor.student.chiose == 'loop' ? obj.months = this.payfor.chioseMonth : obj.months = [];
+      this.payfor.student.chiose == "loop"
+        ? (obj.months = this.payfor.chioseMonth)
+        : (obj.months = []);
       // 解析数据
       let courseJson = {};
       for (let i in this.checkfor) {
         if (this.checkfor[i].ischeck) {
-          courseJson[i] = this.checkfor[i]
+          courseJson[i] = this.checkfor[i];
         }
       }
       for (let j in this.newStudentfor) {
         if (this.newStudentfor[j].ischeck) {
-          courseJson[j] = this.newStudentfor[j]
+          courseJson[j] = this.newStudentfor[j];
         }
       }
 
       obj.musicGroup = {
-        status: 'DRAFT',
+        status: "DRAFT",
         settlementType: this.topfor.salary,
-        applyExpireDate: this.topfor.time + ' 00:00:01',
+        applyExpireDate: this.topfor.time + " 00:00:01",
         chargeTypeId: this.topfor.type,
         cooperationOrganId: this.topfor.school,
         teamTeacherId: this.topfor.boss,
         educationalTeacherId: this.topfor.teacher,
-        enrollClasses: this.topfor.startClass.join(','),
+        enrollClasses: this.topfor.startClass.join(","),
         name: this.topfor.name,
         organId: this.topfor.section,
         // paymentMonths:obj.months  有待确认
         schoolId: this.topfor.address,
         courseForm: JSON.stringify(courseJson),
         ownershipType: this.topfor.ownershipType
-      }
-      obj.musicGroupPaymentEntities = []
+      };
+      obj.musicGroupPaymentEntities = [];
       // 添加学校主体付费方式
       // console.log(this.payfor.company.ischeck)
       if (this.payfor.school.ischeck) {
-
         obj.musicGroupPaymentEntities.push({
-          'amount': this.payfor.school.price,
-          'memo': this.payfor.school.value,
-          'paymentMethod': this.payfor.school.chiose,
-          'name': '学校'
-        })
+          amount: this.payfor.school.price,
+          memo: this.payfor.school.value,
+          paymentMethod: this.payfor.school.chiose,
+          name: "学校"
+        });
       }
       // 添加公司主体付费方式
       if (this.payfor.company.ischeck) {
         obj.musicGroupPaymentEntities.push({
-          'amount': this.payfor.company.price,
-          'memo': this.payfor.company.value,
-          'paymentMethod': this.payfor.company.chiose,
-          'name': '公司'
-        })
+          amount: this.payfor.company.price,
+          memo: this.payfor.company.value,
+          paymentMethod: this.payfor.company.chiose,
+          name: "公司"
+        });
       }
       // 添加商品以及教辅
       // 添加声部
       obj.musicGroupSubjectPlans = [];
       if (this.activeSoundList.length <= 0) {
-        this.$message.error('乐团至少有一个声部')
-        return
+        this.$message.error("乐团至少有一个声部");
+        return;
       }
       for (let i in this.activeSoundList) {
         let item = {};
@@ -527,14 +577,16 @@ export default {
         let item = {};
         // expectedStudentNum
         item.subjectId = this.activeSoundList[i].id;
-        item.registerIdList = []
+        item.registerIdList = [];
 
         if (this.activeSoundList[i].studentList.length <= 0) {
-          this.$message.error(`${this.activeSoundList[i].sound}声部至少有一个学生`)
-          return
+          this.$message.error(
+            `${this.activeSoundList[i].sound}声部至少有一个学生`
+          );
+          return;
         }
         for (let j in this.activeSoundList[i].studentList) {
-          item.registerIdList.push(this.activeSoundList[i].studentList[j].id)
+          item.registerIdList.push(this.activeSoundList[i].studentList[j].id);
         }
         obj.subjectRegisters.push(item);
       }
@@ -543,40 +595,41 @@ export default {
         if (res.code == 200) {
           // 成功 跳转到筹备中
           let id = res.data;
-          this.$router.push({ path: '/teamList', query: { search: this.Fsearch, rules: this.Frules } })
+          this.$router.push({
+            path: "/teamList",
+            query: { search: this.Fsearch, rules: this.Frules }
+          });
         }
-      })
+      });
     },
-    goback () {
-      this.$emit('chiosetab', 0);
+    goback() {
+      this.$emit("chiosetab", 0);
     }
   },
   computed: {
     // 返回当前选中声部数量
-    chioseSoundNum () {
+    chioseSoundNum() {
       let num = 0;
       for (let key in this.soundList) {
         // console.log(this.soundLists[key])
         num += this.soundLists[key].length;
       }
       return num;
-    },
-
-
+    }
   },
   watch: {
-    studentVisible (val) {
+    studentVisible(val) {
       if (!val) {
         // 1.选择的团
-        this.activeTeam = ''
+        this.activeTeam = "";
         // 2.选择的声部
-        this.activeChioseSound = ''
+        this.activeChioseSound = "";
         // 3.选择的选中的列表
         this.studentList = [];
       }
     }
   }
-}
+};
 </script>
 <style lang="scss" scoped>
 .chioseWrap {

+ 17 - 19
src/views/teamBuild/components/teamSoundSet.vue

@@ -21,7 +21,7 @@
         @click="submitInfo(2)"
         v-permission="{
           child: 'musicGroup/createGroup',
-          parent: '/teamBuild/soundMoney',
+          parent: '/teamBuild/soundMoney'
         }"
         >提交</el-button
       >
@@ -100,7 +100,7 @@ export default {
       chioseSoundNum: 0,
       PlannedCount: 0,
       teamStatus: null,
-      teamid: null,
+      teamid: null
     };
   },
   mounted() {
@@ -157,16 +157,16 @@ export default {
       this.$confirm(`是否审核通过?`, "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
-          auditSuccess({ musicGroupId: this.teamid }).then((res) => {
+          auditSuccess({ musicGroupId: this.teamid }).then(res => {
             if (res.code == 200) {
               this.$message.success("审核通过");
               this.$store.dispatch("delVisitedViews", this.$route);
               this.$router.push({
                 path: "/teamList",
-                query: { search: this.Fsearch, rules: this.Frules },
+                query: { search: this.Fsearch, rules: this.Frules }
               });
             }
           });
@@ -177,34 +177,32 @@ export default {
       // auditFailed
       this.$prompt("请输入拒绝原因", "提示", {
         confirmButtonText: "确定",
-        cancelButtonText: "取消",
+        cancelButtonText: "取消"
       }).then(({ value }) => {
         //   点击确认  值是value
         if (!value) {
           this.$message.error("请输入驳回原因");
           return;
         } else {
-          auditFailed({ musicGroupId: this.teamid, memo: value }).then(
-            (res) => {
-              if (res.code == 200) {
-                this.$message.success("已拒绝");
-                this.$store.dispatch("delVisitedViews", this.$route);
-                this.$router.push({
-                  path: "/teamList",
-                  query: { search: this.Fsearch, rules: this.Frules },
-                });
-              }
+          auditFailed({ musicGroupId: this.teamid, memo: value }).then(res => {
+            if (res.code == 200) {
+              this.$message.success("已拒绝");
+              this.$store.dispatch("delVisitedViews", this.$route);
+              this.$router.push({
+                path: "/teamList",
+                query: { search: this.Fsearch, rules: this.Frules }
+              });
             }
-          );
+          });
         }
       });
     },
     gotoNext() {
       this.$emit("handleClick", { name: "3" });
-    },
+    }
   },
 
-  computed: {},
+  computed: {}
 };
 </script>
 <style lang="scss" scoped>

+ 111 - 94
src/views/teamBuild/teamSeting/index.vue

@@ -1,96 +1,113 @@
 <template>
-  <div class='set-container'>
+  <div class="set-container">
     <div class="topWrap">
       <h2>
         <!-- <div class="squrt"></div> -->
-        <el-page-header @back="goBack"
-                        :content="name">
-        </el-page-header>
+        <el-page-header @back="goBack" :content="name"> </el-page-header>
       </h2>
-      <div class="stepbox"
-           v-if="isOld">
-        <span class='stepspan'
-              @click="activeIndex=0">
-          <div class="step1 sptep"
-               :class="activeIndex >= 0?'activestep':''">
+      <div class="stepbox" v-if="isOld">
+        <span class="stepspan" @click="activeIndex = 0">
+          <div
+            class="step1 sptep"
+            :class="activeIndex >= 0 ? 'activestep' : ''"
+          >
             班级设置
           </div>
-          <img :src="activeIndex >= 0?stepImgs.nol:stepImgs.active"
-               alt=""
-               class="arrow">
+          <img
+            :src="activeIndex >= 0 ? stepImgs.nol : stepImgs.active"
+            alt=""
+            class="arrow"
+          />
         </span>
-        <span class='stepspan  stepspan2'
-              @click="activeIndex=2">
-          <div class="step2 sptep"
-               :class="activeIndex >= 2?'activestep':''">
+        <span class="stepspan  stepspan2" @click="activeIndex = 2">
+          <div
+            class="step2 sptep"
+            :class="activeIndex >= 2 ? 'activestep' : ''"
+          >
             课表
           </div>
-          <img :src="activeIndex >= 2?stepImgs.nol:stepImgs.active"
-               alt=""
-               class="
-               arrow">
+          <img
+            :src="activeIndex >= 2 ? stepImgs.nol : stepImgs.active"
+            alt=""
+            class="
+               arrow"
+          />
         </span>
-        <span class='stepspan  stepspan2'
-              v-permission="'/teamSetting/salarySet'"
-              @click="activeIndex=4">
-          <div class="step2 sptep"
-               :class="activeIndex >= 4?'activestep':''">
+        <span
+          class="stepspan  stepspan2"
+          v-permission="'/teamSetting/salarySet'"
+          @click="activeIndex = 4"
+        >
+          <div
+            class="step2 sptep"
+            :class="activeIndex >= 4 ? 'activestep' : ''"
+          >
             课酬
           </div>
-          <img :src="activeIndex >= 4?stepImgs.nol:stepImgs.active"
-               alt=""
-               class="
-               arrow">
+          <img
+            :src="activeIndex >= 4 ? stepImgs.nol : stepImgs.active"
+            alt=""
+            class="
+               arrow"
+          />
         </span>
       </div>
     </div>
 
     <!-- 下面显示的内容 -->
-    <div class="stepcontent"
-         v-if="isOld">
-      <div v-if='activeIndex==0'>
-        <classSeting :teamid='id'
-                     :isSetSalary='isSetSalary'
-                     @gotoNav='gotoNav' />
+    <div class="stepcontent" v-if="isOld">
+      <div v-if="activeIndex == 0">
+        <classSeting
+          :teamid="id"
+          :isSetSalary="isSetSalary"
+          @gotoNav="gotoNav"
+        />
       </div>
-      <div v-if='activeIndex==1'>
-        <teacherSeting :teamid='id'
-                       :isSetSalary='isSetSalary'
-                       @gotoNav='gotoNav' />
+      <div v-if="activeIndex == 1">
+        <teacherSeting
+          :teamid="id"
+          :isSetSalary="isSetSalary"
+          @gotoNav="gotoNav"
+        />
       </div>
-      <div v-if='activeIndex==2'>
+      <div v-if="activeIndex == 2">
         <div class="m-container">
-          <lookCourse :isSetSalary='isSetSalary'
-                      @gotoNav='gotoNav' />
+          <lookCourse :isSetSalary="isSetSalary" @gotoNav="gotoNav" />
         </div>
       </div>
-      <div v-if='activeIndex==3'>
-        <improvement :teamid='id'
-                     :isSetSalary='isSetSalary'
-                     @gotoNav='gotoNav' />
+      <div v-if="activeIndex == 3">
+        <improvement
+          :teamid="id"
+          :isSetSalary="isSetSalary"
+          @gotoNav="gotoNav"
+        />
       </div>
-      <div v-if='activeIndex==4'
-           v-permission="'/teamSetting/salarySet'">
-        <salarySet :teamid='id'
-                   :isSetSalary='isSetSalary' />
+      <div v-if="activeIndex == 4" v-permission="'/teamSetting/salarySet'">
+        <salarySet :teamid="id" :isSetSalary="isSetSalary" />
       </div>
     </div>
-    <classSeting v-if="!isOld"
-                 :teamid='id'
-                 :isSetSalary='isSetSalary'
-                 @gotoNav='gotoNav' />
+    <classSeting
+      v-if="!isOld"
+      :teamid="id"
+      :isSetSalary="isSetSalary"
+      @gotoNav="gotoNav"
+    />
   </div>
 </template>
 <script>
-import classSeting from '@/views/teamBuild/teamSeting/components/setClassV2'
-import teacherSeting from '@/views/teamBuild/teamSeting/components/setTeacher'
-import coursePlan from '@/views/teamBuild/teamSeting/components/coursePlan'
-import salarySet from '@/views/teamBuild/teamSeting/components/salarySet'
-import improvement from '@/views/teamBuild/teamSeting/components/improvementClass'
-import lookCourse from '@/views/teamBuild/teamSeting/components/lookCourse'
-import { getTeamBaseInfo, checkSetSalary, getCourseSchedule } from '@/api/buildTeam'
+import classSeting from "@/views/teamBuild/teamSeting/components/setClassV2";
+import teacherSeting from "@/views/teamBuild/teamSeting/components/setTeacher";
+import coursePlan from "@/views/teamBuild/teamSeting/components/coursePlan";
+import salarySet from "@/views/teamBuild/teamSeting/components/salarySet";
+import improvement from "@/views/teamBuild/teamSeting/components/improvementClass";
+import lookCourse from "@/views/teamBuild/teamSeting/components/lookCourse";
+import {
+  getTeamBaseInfo,
+  checkSetSalary,
+  getCourseSchedule
+} from "@/api/buildTeam";
 export default {
-  name: 'teamSeting',
+  name: "teamSeting",
   components: {
     classSeting,
     teacherSeting,
@@ -99,46 +116,46 @@ export default {
     improvement,
     lookCourse
   },
-  data () {
+  data() {
     return {
       activeIndex: 0,
       stepImgs: {
-        nol: require('@/assets/images/base/step-arrow-active.png'),
-        active: require('@/assets/images/base/step-arrow.png')
+        nol: require("@/assets/images/base/step-arrow-active.png"),
+        active: require("@/assets/images/base/step-arrow.png")
       },
-      id: '',
-      chargeTypeId: '',
-      name: '',
+      id: "",
+      chargeTypeId: "",
+      name: "",
       isSetSalary: false,
       Fsearch: null,
       Frules: null,
       isOld: false
-    }
+    };
   },
-  created () {
-    this.init()
+  created() {
+    this.init();
   },
-  activated () {
-    this.init()
+  activated() {
+    this.init();
   },
-  beforeDestroy () {
-    localStorage.setItem('setStep', 0)
-    localStorage.setItem('resetCode', 1)
+  beforeDestroy() {
+    localStorage.setItem("setStep", 0);
+    localStorage.setItem("resetCode", 1);
   },
 
-  mounted () {
+  mounted() {
     // 根据乐团id 获取乐团信息
-    this.init()
+    this.init();
   },
   methods: {
-    init () {
+    init() {
       this.id = this.$route.query.id;
       // 判断是否带缓存参数
       if (this.$route.query.search) {
         this.Fsearch = this.$route.query.search;
       }
       if (this.$route.query.rules) {
-        this.Frules = this.$route.query.rules
+        this.Frules = this.$route.query.rules;
       }
       //localStorage.getItem('setStep') ||
       this.activeIndex = 0;
@@ -146,38 +163,38 @@ export default {
         if (res.code == 200) {
           this.chargeTypeId = res.data.musicGroup.chargeTypeId;
           this.name = res.data.musicGroup.name;
-          localStorage.setItem('chargeTypeId', this.chargeTypeId);
-          localStorage.setItem('createTeamOrgnId', res.data.musicGroup.organId)
+          localStorage.setItem("chargeTypeId", this.chargeTypeId);
+          localStorage.setItem("createTeamOrgnId", res.data.musicGroup.organId);
         }
-      })
+      });
 
       // 获取是否设置课酬
       checkSetSalary({ musicGroupId: this.id }).then(res => {
         if (res.code == 200) {
           this.isSetSalary = res.data;
         }
-      })
+      });
 
       // 查询有没有课
       getCourseSchedule({ musicGroupId: this.id }).then(res => {
         if (res.code == 200) {
           if (res.data && res.data.rows.length > 0) {
-            this.isOld = true
+            this.isOld = true;
           } else {
-            this.isOld = false
+            this.isOld = false;
           }
         }
-      })
+      });
     },
-    gotoNav (val) {
+    gotoNav(val) {
       this.activeIndex = val;
     },
-    goBack () {
-       this.$store.dispatch('delVisitedViews', this.$route)
-      this.$router.push({ path: '/teamList'})
+    goBack() {
+      this.$store.dispatch("delVisitedViews", this.$route);
+      this.$router.push({ path: "/teamList" });
     }
-  },
-}
+  }
+};
 </script>
 <style lang="scss" scoped>
 .set-container {

+ 39 - 38
src/views/teamDetail/components/modals/create-user-pay.vue

@@ -9,7 +9,7 @@
             <el-select v-model.trim="form.signClass" filterable clearable>
               <el-option
                 v-for="(item, index) in signList.filter(
-                  (item) => item.lockFlag != 1
+                  item => item.lockFlag != 1
                 )"
                 :key="index"
                 :value="item.id"
@@ -23,7 +23,7 @@
             <el-select v-model.trim="form.mixClass" filterable clearable>
               <el-option
                 v-for="(item, index) in mixList.filter(
-                  (item) => item.lockFlag != 1
+                  item => item.lockFlag != 1
                 )"
                 :key="index"
                 :value="item.id"
@@ -37,7 +37,7 @@
             <el-select v-model.trim="form.highClass" filterable clearable>
               <el-option
                 v-for="(item, index) in highList.filter(
-                  (item) => item.lockFlag != 1
+                  item => item.lockFlag != 1
                 )"
                 :key="index"
                 :value="item.id"
@@ -57,7 +57,7 @@
             >
               <el-option
                 v-for="(item, index) in snapList.filter(
-                  (item) => item.lockFlag != 1
+                  item => item.lockFlag != 1
                 )"
                 :key="index"
                 :value="item.id"
@@ -71,7 +71,7 @@
             <el-select v-model.trim="form.highonline" filterable clearable>
               <el-option
                 v-for="(item, index) in highonlineList.filter(
-                  (item) => item.lockFlag != 1
+                  item => item.lockFlag != 1
                 )"
                 :key="index"
                 :value="item.id"
@@ -181,13 +181,13 @@ export default {
     "createdUserId",
     "organizationCourseUnitPriceSettings",
     "musicGroupId",
-    "baseInfo",
+    "baseInfo"
   ],
   components: {
     paymentCycle,
     otherform,
     extraClass,
-    memberSetting,
+    memberSetting
   },
   data() {
     return {
@@ -198,10 +198,10 @@ export default {
         mixClass: "",
         highClass: "",
         snapClass: "",
-        highonline: "",
+        highonline: ""
       },
       payment: {
-        paymentPattern: null,
+        paymentPattern: null
       },
       other: {},
       cycle: {},
@@ -216,10 +216,10 @@ export default {
         memberValidDate: "",
         memberPaymentAmount: "",
         originalMemberPaymentAmount: "",
-        paymentDate: [],
+        paymentDate: []
       },
       money: "",
-      courseViewType: "",
+      courseViewType: ""
     };
   },
   watch: {
@@ -250,7 +250,7 @@ export default {
       // if (val.courseViewType == 2) {
       //   this.payment.paymentPattern = "1";
       // }
-    },
+    }
   },
   mounted() {
     this.courseViewType = this.baseInfo.courseViewType;
@@ -303,7 +303,7 @@ export default {
         this.cycles = this.cycles.map((item, index) => {
           return {
             ...item,
-            paymentAmount: index === 0 ? first : other,
+            paymentAmount: index === 0 ? first : other
           };
         });
       }
@@ -316,18 +316,19 @@ export default {
     },
     removeExtraClass(index) {
       this.eclass[index] = null;
-      this.eclass = this.eclass.filter((item) => !!item);
+      this.eclass = this.eclass.filter(item => !!item);
     },
     formatCourse() {
       const organId = this.baseInfo?.organId;
-      const chargeTypeId = this.baseInfo?.chargeTypeId;
+      console.log(this.baseInfo, "baseInfo");
+      const courseViewType = this.baseInfo?.courseViewType;
       const _ = {};
       const list = (this.organizationCourseUnitPriceSettings || []).filter(
-        (item) =>
+        item =>
           organId &&
           organId == item.organId &&
-          chargeTypeId &&
-          chargeTypeId == item.chargeTypeId
+          courseViewType != null &&
+          courseViewType == item.courseViewType
       );
       for (const item of list) {
         _[item.courseType] = item;
@@ -341,18 +342,18 @@ export default {
         this.form.mixClass,
         this.form.highClass,
         this.form.highonline,
-        ...this.form.snapClass,
-      ].filter((item) => !!item);
+        ...this.form.snapClass
+      ].filter(item => !!item);
     },
     async classChange() {
       try {
         const ids = this.getAllIds().join(",");
         if (ids) {
           const res = await queryRemainCourseTypeDuration({
-            classGroupIdList: ids,
+            classGroupIdList: ids
           });
           this.ids = ids;
-          const _ = res.data.map((item) => {
+          const _ = res.data.map(item => {
             const active =
               this.organizationCourseUnitPriceSettingsByType[item.courseType] ||
               {};
@@ -365,7 +366,7 @@ export default {
               courseType: item.courseType,
               courseTotalMinuties: item.remainMinutes,
               courseOriginalPrice: money,
-              courseCurrentPrice: money,
+              courseCurrentPrice: money
             };
           });
           this.eclass = [..._];
@@ -385,10 +386,10 @@ export default {
         refs.payment,
         refs.other,
         refs.memberForm,
-        ...(refs.cycles || []),
+        ...(refs.cycles || [])
       ]
-        .filter((item) => !!item)
-        .map((item) => item.$refs.form || item);
+        .filter(item => !!item)
+        .map(item => item.$refs.form || item);
     },
     addCycle() {
       this.cycles.push({});
@@ -397,7 +398,7 @@ export default {
     },
     removeCycle(index) {
       this.cycles[index] = null;
-      this.cycles = this.cycles.filter((item) => !!item);
+      this.cycles = this.cycles.filter(item => !!item);
       if (this.collapse.includes(index)) {
         this.collapse.splice(index, 1);
         this.collapse = this.collapse.map((item, _index) =>
@@ -413,7 +414,7 @@ export default {
       const forms = this.getForms();
       const valided = [];
       for (const form of forms) {
-        form.validate((valid) => {
+        form.validate(valid => {
           if (valid) {
             valided.push(form);
           }
@@ -428,15 +429,15 @@ export default {
           calenderMember: {
             ...this.memberForm,
             actualAmount: this.memberForm.memberPaymentAmount,
-            originalAmount: this.memberForm.originalMemberPaymentAmount,
+            originalAmount: this.memberForm.originalMemberPaymentAmount
           },
           calenderAddStudent: {
             classGroupIds: this.ids,
-            studentIds: this.createdUserId,
+            studentIds: this.createdUserId
           },
           ...getTimes(this.cycle.paymentDate, [
             "startPaymentDate",
-            "deadlinePaymentDate",
+            "deadlinePaymentDate"
           ]),
           // paymentPattern: this.payment.paymentPattern,
           musicGroupId: this.musicGroupId,
@@ -444,10 +445,10 @@ export default {
           payUserType: "STUDENT",
 
           musicGroupPaymentCalenderCourseSettingsList: this.eclass,
-          ...this.other,
+          ...this.other
         };
         try {
-         const res =  await musicGroupcreateCalender(data);
+          const res = await musicGroupcreateCalender(data);
 
           if (res.code == 200) {
             this.$message.success("提交成功");
@@ -459,11 +460,11 @@ export default {
               res.msg || `当前乐团存在未排课的缴费项目,请再次确认操作`,
               "提示",
               {
-                type: "warning",
+                type: "warning"
               }
             );
             data.confirmCreate = true;
-           await musicGroupcreateCalender(data);
+            await musicGroupcreateCalender(data);
             this.$message.success("提交成功");
             this.$listeners.submited();
             this.$listeners.close();
@@ -472,8 +473,8 @@ export default {
           console.log(error);
         }
       }
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="less" scoped>
@@ -504,7 +505,7 @@ export default {
     margin-right: 10px;
   }
 }
-::v-deep  .el-collapse-item__wrap {
+::v-deep .el-collapse-item__wrap {
   padding-top: 20px;
 }
 </style>

+ 102 - 102
src/views/teamDetail/components/resetClass.vue

@@ -189,8 +189,8 @@
                     (permission('classGroup/classGroupUpdate') ||
                       permission('classGroup/revisionClassGroup') ||
                       permission('classGroup/revisionAddClassGroup')) &&
-                    scope.row.studentNum > 0 &&
-                    team_status == 'PROGRESS'
+                      scope.row.studentNum > 0 &&
+                      team_status == 'PROGRESS'
                   "
                   @click="classAdjustment(scope.row)"
                   >排课</el-button
@@ -200,7 +200,7 @@
                   v-if="
                     (scope.row.studentNum == '0' ||
                       scope.row.totalClassTimes == '0') &&
-                    permission('classGroup/delSingle')
+                      permission('classGroup/delSingle')
                   "
                   @click="removeClass(scope)"
                   >删除</el-button
@@ -209,8 +209,8 @@
                   type="text"
                   v-if="
                     team_status == 'PROGRESS' &&
-                    permission('courseSchedule/coursePostpone') &&
-                    checkSignPostpone(scope.row)
+                      permission('courseSchedule/coursePostpone') &&
+                      checkSignPostpone(scope.row)
                   "
                   @click="signPostpone(scope.row)"
                   >顺延课程</el-button
@@ -234,7 +234,7 @@
               @click="studentResetVisiable = true"
               v-if="
                 permission('classGroup/mergeClassSplitClassAffirm') &&
-                team_status == 'PROGRESS'
+                  team_status == 'PROGRESS'
               "
             >
               拆分班级
@@ -456,7 +456,7 @@
         <el-form-item
           label="班级名称"
           :rules="[
-            { required: true, message: '请输入班级姓名', trigger: 'blur' },
+            { required: true, message: '请输入班级姓名', trigger: 'blur' }
           ]"
           prop="className"
         >
@@ -468,7 +468,7 @@
         <el-form-item
           label="班级类型"
           :rules="[
-            { required: true, message: '请选择班级类型', trigger: 'blur' },
+            { required: true, message: '请选择班级类型', trigger: 'blur' }
           ]"
           prop="type"
         >
@@ -505,7 +505,7 @@
           label="主教老师"
           prop="bishop"
           :rules="[
-            { required: true, message: '请选择主教老师', trigger: 'blur' },
+            { required: true, message: '请选择主教老师', trigger: 'blur' }
           ]"
         >
           <el-select
@@ -536,7 +536,7 @@
           prop="expectStudentNum"
           type="number"
           :rules="[
-            { required: true, message: '请输入预计招生数', trigger: 'blur' },
+            { required: true, message: '请输入预计招生数', trigger: 'blur' }
           ]"
           @mousewheel.native.prevent
         >
@@ -550,8 +550,8 @@
           label="助教老师"
           v-if="
             newClassForm.type != 'HIGH_ONLINE' &&
-            newClassForm.type != 'HIGH' &&
-            newClassForm.type
+              newClassForm.type != 'HIGH' &&
+              newClassForm.type
           "
           prop="teaching"
         >
@@ -603,7 +603,7 @@
           label="可报名声部"
           prop="memo"
           :rules="[
-            { required: true, message: '请选择可报名声部', trigger: 'blur' },
+            { required: true, message: '请选择可报名声部', trigger: 'blur' }
           ]"
           v-if="newClassForm.type == 'HIGH'"
         >
@@ -626,7 +626,7 @@
           label="网络教室声部"
           prop="subjectId"
           :rules="[
-            { required: true, message: '请选择线上声部', trigger: 'blur' },
+            { required: true, message: '请选择线上声部', trigger: 'blur' }
           ]"
           v-if="newClassForm.type == 'HIGH_ONLINE'"
           class="higheSelect"
@@ -761,12 +761,12 @@ import {
   createClass,
   pushMessage,
   coursePostpone,
-  musicGroupSchoolTermCourseDetail,
+  musicGroupSchoolTermCourseDetail
 } from "@/api/buildTeam";
 import {
   getClassAllStudent,
   removeStudents,
-  addStudents,
+  addStudents
 } from "@/api/studentManager";
 import { getOrganizationCourseUnitPriceSettings } from "@/api/specialSetting";
 import { queryEmployByOrganId } from "@/api/systemManage";
@@ -808,7 +808,7 @@ export default {
     classroomSetting,
     studentResetView,
     changeTeacher,
-    changeClassName,
+    changeClassName
   },
   data() {
     return {
@@ -819,13 +819,13 @@ export default {
         firstDayOfWeek: 1,
         disabledDate(time) {
           return time.getTime() + 86400000 <= new Date().getTime();
-        },
+        }
       },
       step: "00:05",
       teamid: "",
       topForm: {
         type: "",
-        hasCourse: "",
+        hasCourse: ""
       },
       studentSubmitedData: null,
       infoDetail: null,
@@ -864,7 +864,7 @@ export default {
         courseNum: "",
         mixClassGroupId: "",
         sound: "",
-        expectStudentNum: "",
+        expectStudentNum: ""
       },
       teacherRules: {
         isAdd: [{ required: true, message: "请选择调整类型" }],
@@ -874,7 +874,7 @@ export default {
         courseNum: [{ required: true, message: "请输入排课次数" }],
         mixClassGroupId: [{ required: true, message: "请选择合奏班" }],
         sound: [{ required: true, message: "请选择合声部" }],
-        expectStudentNum: [{ required: true, message: "请填写预计招生人数" }],
+        expectStudentNum: [{ required: true, message: "请填写预计招生人数" }]
       },
       weekList: [],
       teacherList: [], // 存储的老师列表
@@ -886,7 +886,7 @@ export default {
         { value: "4", label: "星期四" },
         { value: "5", label: "星期五" },
         { value: "6", label: "星期六" },
-        { value: "7", label: "星期日" },
+        { value: "7", label: "星期日" }
       ],
       // 班级类型
       classTypeList: [
@@ -895,13 +895,13 @@ export default {
         { value: "HIGH", label: "基础技能班" },
         { value: "SNAP", label: "临时班" },
         { value: "HIGH_ONLINE", label: "线上基础技能班" },
-        { value: "MUSIC_NETWORK", label: "乐团网管课" },
+        { value: "MUSIC_NETWORK", label: "乐团网管课" }
       ],
       musicClassTypeList,
       // 基础技能班类型
       highTypeList: [
         { value: "HIGH", label: "基础技能班" },
-        { value: "HIGH_ONLINE", label: "线上基础技能班" },
+        { value: "HIGH_ONLINE", label: "线上基础技能班" }
       ],
       highTypeList1: [{ value: "HIGH", label: "基础技能班" }],
       cooperationList: [],
@@ -913,13 +913,13 @@ export default {
         startTime: "",
         endTime: "",
         assistant: [],
-        coreTeacher: "",
+        coreTeacher: ""
       },
       recourseForm: {
         courseType: "",
         checked: false,
         courseTime: "",
-        courseNum: "",
+        courseNum: ""
       },
       teacherDetail: null,
       organId: "",
@@ -932,7 +932,7 @@ export default {
         bishop: null,
         teaching: [],
         memo: [],
-        subjectId: null,
+        subjectId: null
       },
       classGroupIds: null,
       maxMun: 16,
@@ -945,16 +945,16 @@ export default {
       postponeForm: {
         stopTime: "",
         resetTime: "",
-        holiday: false,
+        holiday: false
       },
       postponeVisible: false,
       postponeRules: {
         stopTime: [
-          { required: true, message: "请选择开始日期", trigger: "blur" },
+          { required: true, message: "请选择开始日期", trigger: "blur" }
         ],
         resetTime: [
-          { required: true, message: "请选择顺延日期", trigger: "blur" },
-        ],
+          { required: true, message: "请选择顺延日期", trigger: "blur" }
+        ]
       },
       bigin: this.beginDate(),
       options: this.processDate(),
@@ -964,7 +964,7 @@ export default {
       tenantId: null,
       isFirst: false,
       classDetail: null,
-      classNameVisible: false,
+      classNameVisible: false
     };
   },
   created() {
@@ -986,7 +986,7 @@ export default {
     reset() {
       this.topForm = {
         classType: "",
-        hasCourse: "",
+        hasCourse: ""
       };
       this.$nextTick(() => {
         this.getList();
@@ -1011,25 +1011,25 @@ export default {
       this.team_status = this.$route.query.team_status;
       if (this.musicGroupInfo) {
         this.organId = this.musicGroupInfos.organId;
-        this.chargeTypeId = this.musicGroupInfos.chargeTypeId;
+        this.courseViewType = this.musicGroupInfos.courseViewType;
         this.courseViewType = this.musicGroupInfos.courseViewType;
       } else {
-        getTeamBaseInfo({ musicGroupId: this.teamid }).then((res) => {
+        getTeamBaseInfo({ musicGroupId: this.teamid }).then(res => {
           if (res.code == 200) {
             this.musicGroupInfos = res.data.musicGroup;
             this.organId = this.musicGroupInfos.organId;
-            this.chargeTypeId = this.musicGroupInfos.chargeTypeId;
+            this.courseViewType = this.musicGroupInfos.courseViewType;
             this.courseViewType = this.musicGroupInfos.courseViewType;
           }
         });
       }
-      this.$nextTick(async (res) => {
+      this.$nextTick(async res => {
         try {
-          if (this.organId && this.chargeTypeId) {
+          if (this.organId && this.courseViewType != null) {
             const res = await getOrganizationCourseUnitPriceSettings({
-              chargeTypeId: this.chargeTypeId,
+              courseViewType: this.courseViewType,
               organId: this.organId,
-              rows: 9999,
+              rows: 9999
             });
             const d = {};
             this.courseTypes = res.data.rows;
@@ -1041,7 +1041,7 @@ export default {
           }
         } catch (error) {}
         // 根据乐团id获取乐团所属分部
-        getTeacher({ organId: this.organId }).then((res) => {
+        getTeacher({ organId: this.organId }).then(res => {
           if (res.code == 200) {
             this.cooperationList = res.data;
             this.teacherList = res.data;
@@ -1060,7 +1060,7 @@ export default {
         // 获取默认乐团内的所有班
         this.changeMixClass();
         // 根据乐团id获取乐团的所有声部
-        findSound({ musicGroupId: this.teamid }).then((res) => {
+        findSound({ musicGroupId: this.teamid }).then(res => {
           if (res.code == 200) {
             this.soundList = res.data;
           }
@@ -1075,9 +1075,9 @@ export default {
     teacherSubmited(data) {
       const obj = this.getSubmitData(data, {
         classGroupId: this.teacherDetail?.id,
-        courseAddType: "onlyUpdateTeacher",
+        courseAddType: "onlyUpdateTeacher"
       });
-      classGroupUpdate(obj).then((res) => {
+      classGroupUpdate(obj).then(res => {
         if (res.code == 200) {
           this.$message.success("修改成功");
           this.teacherVisible = false;
@@ -1096,8 +1096,8 @@ export default {
             data.assistant
           ),
           students: data?.seleched,
-          ...more,
-        },
+          ...more
+        }
       ];
     },
     getClassDate(data) {
@@ -1110,7 +1110,7 @@ export default {
           data.coreTeacher,
           data.assistant
         ),
-        groupType: "MUSIC",
+        groupType: "MUSIC"
       };
     },
     async submitClass(data) {
@@ -1126,7 +1126,7 @@ export default {
           console.log(error);
         }
       } else {
-        createClass(obj).then((res) => {
+        createClass(obj).then(res => {
           if (res.code == 200) {
             this.studentVisible = false;
             this.$message.success("提交成功");
@@ -1175,8 +1175,8 @@ export default {
           week: "",
           startTime: "",
           endTime: "",
-          id: new Date(),
-        },
+          id: new Date()
+        }
       ]),
         (this.resetCourseVisible = true);
     },
@@ -1202,12 +1202,12 @@ export default {
     getList(val) {
       getAllSignClassandTeacher({
         musicGroupId: this.teamid,
-        ...this.topForm,
-      }).then((res) => {
+        ...this.topForm
+      }).then(res => {
         if (res.code == 200) {
           this.activeSingleList = res.data;
           if (res.data?.length > 0) {
-            this.mergeList = res.data.filter((item) => {
+            this.mergeList = res.data.filter(item => {
               return item.type != "MUSIC_NETWORK";
             });
           }
@@ -1240,7 +1240,7 @@ export default {
     addNewClass(type) {
       const types = {
         NORMAL: 2,
-        MUSIC_NETWORK: 4,
+        MUSIC_NETWORK: 4
       };
       this.isOnlyChangeUser = false;
       this.classType = types[type] || 3;
@@ -1264,8 +1264,8 @@ export default {
       if (this.activeType == "SNAP") {
         teamSoundStudent({
           musicGroupId: this.teamid,
-          actualSubjectId: this.activeChioseSound,
-        }).then((res) => {
+          actualSubjectId: this.activeChioseSound
+        }).then(res => {
           if (res.code == 200) {
             this.studentList = res.data;
           }
@@ -1306,7 +1306,7 @@ export default {
     },
     clearCourse(scope) {
       clearClassCourse({ classGroupId: scope.row.id })
-        .then((res) => {
+        .then(res => {
           if (res.code == 200) {
             this.$message.success("清除成功");
             scope._self.$refs[scope.$index].doClose();
@@ -1317,7 +1317,7 @@ export default {
             scope._self.$refs[scope.$index].doClose();
           }
         })
-        .catch((res) => {
+        .catch(res => {
           scope._self.$refs[scope.$index].doClose();
         });
       // 清空课表
@@ -1327,18 +1327,18 @@ export default {
       this.$confirm("是否确定删除该班级?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
           removeSingleClass({ classGroupId: scope.row.id })
-            .then((res) => {
+            .then(res => {
               if (res.code == 200) {
                 this.$message.success("删除成功");
                 // 重新请求列表
                 this.getList(this.activeMixClass);
               }
             })
-            .catch((res) => {});
+            .catch(res => {});
         })
         .catch(() => {});
     },
@@ -1355,9 +1355,9 @@ export default {
       this.isStudentRemove =
         row.currentClassTimes == row.totalClassTimes ? true : false; // 上课时长是否没有
       // 根据单机班id 查询声部班内的所有学生
-      getClassAllStudent({ classGroupId: row.id }).then((res) => {
+      getClassAllStudent({ classGroupId: row.id }).then(res => {
         if (res.code == 200) {
-          this.activeListStudent = res.data.map((item) => {
+          this.activeListStudent = res.data.map(item => {
             item.isVisible = false;
             return item;
           });
@@ -1406,9 +1406,9 @@ export default {
         musicGroupId: this.teamid,
         type,
         actualSubjectId,
-        classGroupId,
+        classGroupId
       };
-      await getMusicGroupStuNoClassType(params).then((res) => {
+      await getMusicGroupStuNoClassType(params).then(res => {
         if (res.code == 200) {
           this.studentList = res.data;
           // }
@@ -1427,14 +1427,14 @@ export default {
       }
       removeStudents({
         classGroupId: this.activeClass,
-        userId: item.userId,
-      }).then((res) => {
+        userId: item.userId
+      }).then(res => {
         if (res.code == 200) {
           this.$message.success("删除成功");
           item.isVisible = false;
           // 这里刷新 this.studentList this.activeListStudent
           this.getList(this.activeMixClass);
-          getClassAllStudent({ classGroupId: this.activeClass }).then((res) => {
+          getClassAllStudent({ classGroupId: this.activeClass }).then(res => {
             if (res.code == 200) {
               this.activeListStudent = res.data;
             }
@@ -1455,7 +1455,7 @@ export default {
     // 批量添加学生
     addSomeStudent() {
       // 获取勾选的学生
-      let arr = this.chioseStudent.map((item) => {
+      let arr = this.chioseStudent.map(item => {
         return item.userId;
       });
       if (arr.length <= 0) {
@@ -1468,7 +1468,7 @@ export default {
         }
       }
       if (this.activeType == "HIGH_ONLINE") {
-        superFindClassGroups({ classGroupId: this.activeClass }).then((res) => {
+        superFindClassGroups({ classGroupId: this.activeClass }).then(res => {
           if (res.code == 200) {
             if (
               this.activeListStudent.length + this.chioseStudent.length > 6 ||
@@ -1479,8 +1479,8 @@ export default {
             } else {
               addStudents({
                 classGroupId: this.activeClass,
-                userIdsStr: arr.join(","),
-              }).then((res) => {
+                userIdsStr: arr.join(",")
+              }).then(res => {
                 if (res.code == 200) {
                   this.studentVisible = false;
                   this.$message.success("添加成功");
@@ -1494,8 +1494,8 @@ export default {
       } else {
         addStudents({
           classGroupId: this.activeClass,
-          userIdsStr: arr.join(","),
-        }).then((res) => {
+          userIdsStr: arr.join(",")
+        }).then(res => {
           if (res.code == 200) {
             this.studentVisible = false;
             this.$message.success("添加成功");
@@ -1573,7 +1573,7 @@ export default {
         startClassTime: "",
         endClassTime: "",
         time: this.courseTime,
-        id: new Date().getTime(),
+        id: new Date().getTime()
       });
     },
     // 删除循环周
@@ -1586,7 +1586,7 @@ export default {
     },
     // 新建基础技能班
     newClassHight() {
-      this.$refs["newClassForm"].validate((res) => {
+      this.$refs["newClassForm"].validate(res => {
         if (res) {
           let obj = {};
           obj.musicGroupId = this.teamid;
@@ -1598,7 +1598,7 @@ export default {
           obj.teacherMapperList = [];
           obj.teacherMapperList.push({
             userId: this.newClassForm.bishop,
-            teacherRole: "BISHOP",
+            teacherRole: "BISHOP"
           });
 
           let subjectIdList;
@@ -1615,13 +1615,13 @@ export default {
             for (let i in this.newClassForm.teaching) {
               obj.teacherMapperList.push({
                 userId: this.newClassForm.teaching[i],
-                teacherRole: "TEACHING",
+                teacherRole: "TEACHING"
               });
             }
             obj.memo = subjectIdList;
           }
           obj.subjectIdList = subjectIdList;
-          createClass(obj).then((res) => {
+          createClass(obj).then(res => {
             if (res.code == 200) {
               this.$message.success("创建成功");
               this.getList();
@@ -1641,7 +1641,7 @@ export default {
         expectStudentNum: null,
         bishop: null,
         teaching: [],
-        memo: [],
+        memo: []
       };
       this.changeMemo([]);
     },
@@ -1656,7 +1656,7 @@ export default {
     },
     handleSelectionChange(val) {
       this.activeList = val;
-      let arr = val.map((item) => {
+      let arr = val.map(item => {
         return item.id;
       });
       this.activeClass = arr.join(",");
@@ -1675,13 +1675,13 @@ export default {
       this.$confirm("是否开启报名?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
           pushMessage({
             classGroupIds: this.classGroupIds,
-            musicGroupId: this.teamid,
-          }).then((res) => {
+            musicGroupId: this.teamid
+          }).then(res => {
             if (res.code == 200) {
               this.$message.success(`开启成功,已推送${res.data}名学生`);
               this.getList();
@@ -1692,7 +1692,7 @@ export default {
     },
     toggleSelection(rows) {
       if (rows) {
-        rows.forEach((row) => {
+        rows.forEach(row => {
           this.$refs.multipleTable.toggleRowSelection(row);
         });
       } else {
@@ -1718,7 +1718,7 @@ export default {
     changeCourseType(val) {
       console.log(val);
       if (val) {
-        this.classTimeList.forEach((item) => {
+        this.classTimeList.forEach(item => {
           if (item.value == val) {
             this.courseTime = item.label;
           }
@@ -1730,8 +1730,8 @@ export default {
             startTime: "",
             endTime: "",
             time: this.courseTime,
-            id: new Date().getTime(),
-          },
+            id: new Date().getTime()
+          }
         ];
       } else {
         this.courseTime = null;
@@ -1772,7 +1772,7 @@ export default {
     },
     changeMemo(val) {},
     submitInfo() {
-      this.$refs["postponeForm"].validate((res) => {
+      this.$refs["postponeForm"].validate(res => {
         if (res) {
           let classGroupIds = this.activeClass;
           let pauseDate = this.postponeForm.stopTime;
@@ -1782,9 +1782,9 @@ export default {
             classGroupIds,
             pauseDate,
             recoveryDate,
-            skipHoliday,
+            skipHoliday
           };
-          coursePostpone(obj).then((res) => {
+          coursePostpone(obj).then(res => {
             if (res.code == 200) {
               this.$message.success("修改成功");
               this.postponeVisible = false;
@@ -1814,7 +1814,7 @@ export default {
         firstDayOfWeek: 1,
         disabledDate(time) {
           return time.getTime() + 86400000 <= new Date().getTime(); //开始时间不选时,结束时间最大值小于等于当天
-        },
+        }
       };
     },
     processDate() {
@@ -1831,7 +1831,7 @@ export default {
             return time.getTime() > Date.now();
             //开始时间不选时,结束时间最大值小于等于当天
           }
-        },
+        }
       };
     },
     signPostpone(row) {
@@ -1842,11 +1842,11 @@ export default {
       // 这里跳转到课表
       try {
         const res = await musicGroupSchoolTermCourseDetail({
-          musicGroupId: this.teamid,
+          musicGroupId: this.teamid
         });
         this.$router.push({
           path: "/business/memberClassList",
-          query: { ...this.$route.query },
+          query: { ...this.$route.query }
         });
       } catch (e) {
         console.log(e);
@@ -1858,14 +1858,14 @@ export default {
     },
     async submitedResetClassName(data) {
       const obj = { ...data };
-      resetClassName(obj).then((res) => {
+      resetClassName(obj).then(res => {
         if (res.code == 200) {
           this.$message.success("修改成功");
           this.classNameVisible = false;
           this.getList();
         }
       });
-    },
+    }
   },
 
   watch: {
@@ -1886,7 +1886,7 @@ export default {
           courseNum: "",
           mixClassGroupId: "",
           sound: "",
-          expectStudentNum: "",
+          expectStudentNum: ""
         };
         this.infoDetail = null;
         // this.$refs["teacherForm"].resetFields();
@@ -1902,12 +1902,12 @@ export default {
           expectStudentNum: null,
           bishop: null,
           teaching: null,
-          memo: [],
+          memo: []
         };
         this.resetClassFrom();
       }
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss" scoped>
@@ -2022,7 +2022,7 @@ export default {
     height: 40px !important;
   }
 }
-::v-deep  .el-alert__content {
+::v-deep .el-alert__content {
   display: block;
   width: 100%;
 }

+ 117 - 107
src/views/teamDetail/components/studentList.vue

@@ -16,18 +16,22 @@
       >
         增加会员试用期
       </div> -->
-      <el-button  style="margin-bottom: 20px;" type="primary"
+      <el-button
+        style="margin-bottom: 20px;"
+        type="primary"
         v-if="team_status == 'PROGRESS'"
         v-permission="'studentRegistration/insertStudent'"
-        @click="createStudentFrom" icon="el-icon-plus">新增学员</el-button>
-
+        @click="createStudentFrom"
+        icon="el-icon-plus"
+        >新增学员</el-button
+      >
     </div>
 
     <!-- 搜索类型 -->
     <save-form
       ref="searchForm"
       :inline="true"
-      :save-key="saveKey" 
+      :save-key="saveKey"
       class="searchForm"
       @submit="search"
       @reset="onReSet"
@@ -38,13 +42,13 @@
           v-model.trim="searchForm.search"
           clearable
           placeholder="学生姓名或电话"
-            @keyup.enter.native="
-              (e) => {
-                e.target.blur();
-                $refs.searchForm.save();
-                search();
-              }
-            "
+          @keyup.enter.native="
+            e => {
+              e.target.blur();
+              $refs.searchForm.save();
+              search();
+            }
+          "
         ></el-input>
       </el-form-item>
       <el-form-item prop="studentStatus">
@@ -534,7 +538,7 @@
                 type="text"
                 v-if="
                   permission('studentManage/queryStudentClassGroup') &&
-                  scope.row.studentStatus != 'QUIT'
+                    scope.row.studentStatus != 'QUIT'
                 "
                 @click="lookClass(scope.row)"
                 >查看班级</el-button
@@ -543,9 +547,9 @@
                 type="text"
                 v-if="
                   permission('musicGroupPaymentCalender/add') &&
-                  scope.row.studentStatus == 'APPLY' &&
-                  scope.row.paymentStatus != '2' &&
-                  team_status == 'PROGRESS'
+                    scope.row.studentStatus == 'APPLY' &&
+                    scope.row.paymentStatus != '2' &&
+                    team_status == 'PROGRESS'
                 "
                 @click="addPay(scope.row)"
                 >添加缴费</el-button
@@ -555,7 +559,8 @@
                 type="text"
                 v-if="
                   permission('musicGroupQuit/apply/3852') &&
-                  scope.row.studentStatus != 'QUIT'&&isManage
+                    scope.row.studentStatus != 'QUIT' &&
+                    isManage
                 "
                 @click="quieTeamMask(scope.row)"
                 >退团</el-button
@@ -625,8 +630,8 @@
             {
               pattern: /^1[3456789]\d{9}$/,
               message: '请输入正确的手机号',
-              trigger: 'blur',
-            },
+              trigger: 'blur'
+            }
           ]"
         >
           <el-input
@@ -734,7 +739,6 @@
             <el-option label="38班" value="38班"></el-option>
             <el-option label="39班" value="39班"></el-option>
             <el-option label="40班" value="40班"></el-option>
-
           </el-select>
           <!-- <el-input
             v-model.trim="maskForm.course"
@@ -769,7 +773,7 @@
               value-format="yyyy-MM-dd"
               type="date"
               :picker-options="{
-                firstDayOfWeek: 1,
+                firstDayOfWeek: 1
               }"
               placeholder="选择日期"
             ></el-date-picker>
@@ -801,7 +805,7 @@
     <!-- 退团弹窗 -->
     <el-dialog title="退团信息确认" width="700px" :visible.sync="quitVisible">
       <quiteTeam :quitForm="quitForm" ref="quitForm" />
-       <p style="color:red;paddingLeft:150px">退费金额暂不进入账户余额</p>
+      <p style="color:red;paddingLeft:150px">退费金额暂不进入账户余额</p>
       <span slot="footer" class="dialog-footer question">
         <div>
           <el-popover placement="right" width="500" trigger="click">
@@ -811,7 +815,9 @@
               <p>退还课程费用:缴费总额-已结束课时单价之和</p>
               <p>退还乐器费用:报名缴费时缴纳的乐器费用(团购、租金)</p>
               <p>退还教辅费用:报名缴费时缴费的教辅费用</p>
-              <p v-if="$helpers.tenantId ==1">退还乐保费用:报名缴费时缴费的乐保费用</p>
+              <p v-if="$helpers.tenantId == 1">
+                退还乐保费用:报名缴费时缴费的乐保费用
+              </p>
             </div>
             <el-button
               type="text"
@@ -1004,7 +1010,7 @@ import {
 import {
   addStudent,
   getStudentClass,
-  getStudentInfoByPhone,
+  getStudentInfoByPhone
 } from "@/api/studentManager";
 import { getAllmemberRank } from "@/views/resetTeaming/api";
 import qrCode from "@/components/QrCode/index";
@@ -1049,7 +1055,7 @@ export default {
         studing: "5", // 在读人数
         allmoney: "100", //实收总额
         students: "5", // 实际招生人数
-        signout: "10", // 退团总数
+        signout: "10" // 退团总数
       },
       searchForm: {
         studentStatus: "", // 学生状态
@@ -1063,7 +1069,7 @@ export default {
         classGroupId: null,
         hasCourse: null,
         carePackage: null,
-        comeOnPackage: null,
+        comeOnPackage: null
       },
       organizationCourseUnitPriceSettings: [],
       quitForm: {
@@ -1077,10 +1083,10 @@ export default {
         musicGroupName: null,
         isVisit: false,
         reason: "",
-        userComment: null,
+        userComment: null
       },
       classMask: {
-        studentName: "",
+        studentName: ""
       },
       baseInfo: {},
       searchLsit: [],
@@ -1090,13 +1096,13 @@ export default {
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50], // 选择限制显示条数
+        page_size: [10, 20, 40, 50] // 选择限制显示条数
       },
       studentListInfo: {
         add: "",
         quit: "",
         studying: "",
-        courseRate: "",
+        courseRate: ""
       },
       signList: [],
       mixList: [],
@@ -1133,7 +1139,7 @@ export default {
         kitGroupPurchaseType: "GROUP", // 乐器购买方式
         musicPrice: null, // 乐器购买金额
         instrGoodsIdList: [], // 辅件商品编号
-        instrPrice: null, // 辅件购买金额
+        instrPrice: null // 辅件购买金额
       },
       remark: "", // 退团原因
       classList: [],
@@ -1153,11 +1159,11 @@ export default {
         // courseFee: [{ required: true, message: "请输入声部费用" }],
         temporaryCourseFee: [{ required: true, message: "请输课程费用" }],
         musicGoodsIdList: [
-          { required: true, message: "请选择乐器", trigger: "change" },
+          { required: true, message: "请选择乐器", trigger: "change" }
         ],
         musicPrice: [{ required: true, message: "请输入乐器购买金额" }],
         instrGoodsIdList: [{ required: true, message: "请选择辅件" }],
-        instrPrice: [{ required: true, message: "请输入辅件金额" }],
+        instrPrice: [{ required: true, message: "请输入辅件金额" }]
       },
       INSTRUMENTLIST: [], // 乐器列表
       ACCESSORIESLIST: [], // 辅件列表
@@ -1167,7 +1173,7 @@ export default {
       payForm: {
         studentName: "",
         payMoney: "",
-        payMonth: [],
+        payMonth: []
       },
       kitStatus: false, // 乐器提供方式
       // 新增回访记录弹窗
@@ -1181,7 +1187,7 @@ export default {
         visitTime: "",
         visitType: "",
         feedback: "",
-        studentName: "",
+        studentName: ""
       },
       cycles: [{}],
       collapse: [0],
@@ -1190,7 +1196,7 @@ export default {
         overview: [{ required: true, message: "请输入学生近况" }],
         feedback: [{ required: true, message: "请输入家长反馈" }],
         visitTime: [{ required: true, message: "请输入回访时间" }],
-        visitType: [{ required: true, message: "请选择回访类型" }],
+        visitType: [{ required: true, message: "请选择回访类型" }]
       },
       pickerOptions: null,
       classLists: null,
@@ -1208,10 +1214,10 @@ export default {
         axe: "",
         axePrice: "",
         others: "",
-        othersPrice: "",
+        othersPrice: ""
       },
       maskSoundForm: {
-        subject: "",
+        subject: ""
       },
       subjectVisible: false,
       isCanReg: false,
@@ -1220,7 +1226,7 @@ export default {
       // memberRankList: [],
       isManage: false,
       gradeListObj: {},
-      submitList:[]
+      submitList: []
     };
   },
   components: {
@@ -1242,10 +1248,10 @@ export default {
     studentPays(val) {
       let template = {
         0: "未缴费",
-        1: "已缴费",
+        1: "已缴费"
       };
       return template[val];
-    },
+    }
   },
   // activated() {
   //   this.init();
@@ -1268,7 +1274,7 @@ export default {
     }
     try {
       const res = await getOrganizationCourseUnitPriceSettings({
-        rows: 9999,
+        rows: 9999
       });
       this.organizationCourseUnitPriceSettings = res.data.rows;
     } catch (error) {}
@@ -1279,7 +1285,7 @@ export default {
     //   console.log(e);
     // }
     this.init();
-    this.getAgreement()
+    this.getAgreement();
   },
   methods: {
     onPaymentDetail(row) {
@@ -1304,14 +1310,14 @@ export default {
       // } catch (e) {
       //   console.log(e);
       // }
-      getMusicGroupGradeList({ musicGroupId: this.teamid }).then((res) => {
+      getMusicGroupGradeList({ musicGroupId: this.teamid }).then(res => {
         let result = res.data;
         this.gradeListObj = res.data;
         if (res.code == 200 && result) {
           for (let i in result) {
             this.gradeList.push({
               value: i,
-              label: result[i],
+              label: result[i]
             });
           }
         }
@@ -1330,20 +1336,20 @@ export default {
       this.pickerOptions = this.beginDate();
       this.getList();
       // 获取乐团内所有声部
-      findSound({ musicGroupId: this.teamid }).then((res) => {
+      findSound({ musicGroupId: this.teamid }).then(res => {
         if (res.code == 200) {
           this.soundList = res.data;
         }
       });
-      this.getMusicClass() // 修改问题
+      this.getMusicClass(); // 修改问题
       // 获取乐团基本信息
       getMusicGroup({ musicGroupId: this.teamid }).then(
-        (res) => (this.baseInfo = res.data)
+        res => (this.baseInfo = res.data)
       );
       // 获取乐团所有合奏课
     },
     getMusicClass() {
-      getMusicGroupAllClass({ musicGroupId: this.teamid }).then((res) => {
+      getMusicGroupAllClass({ musicGroupId: this.teamid }).then(res => {
         if (res.code == 200) {
           this.classList = res.data;
           this.signList = [];
@@ -1351,7 +1357,7 @@ export default {
           this.highList = [];
           this.snapList = [];
           this.highonlineList = [];
-          this.classList.forEach((item) => {
+          this.classList.forEach(item => {
             if (item.type == "NORMAL") {
               this.signList.push(item);
             } else if (item.type == "MIX") {
@@ -1370,7 +1376,7 @@ export default {
       });
     },
     getTeamStudent() {
-      getTeamStudentInfo({ musicGroupId: this.teamid }).then((res) => {
+      getTeamStudentInfo({ musicGroupId: this.teamid }).then(res => {
         if (res.code == 200) {
           this.studentListInfo = res.data;
         }
@@ -1415,7 +1421,7 @@ export default {
         createYear: this.searchForm.createYear || null,
         hasCourse: this.searchForm.hasCourse || null,
         comeOnPackage: this.searchForm.comeOnPackage,
-        carePackage: this.searchForm.carePackage,
+        carePackage: this.searchForm.carePackage
       };
       const options = {
         method: "get",
@@ -1425,19 +1431,19 @@ export default {
         },
         url,
         params: data,
-        responseType: "blob",
+        responseType: "blob"
       };
 
       this.$confirm("您确定导出学员列表?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
-          axios(options).then((res) => {
+          axios(options).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 objectUrl = URL.createObjectURL(blob);
@@ -1484,9 +1490,9 @@ export default {
         oweFlag: this.searchForm.oweFlag || null,
         comeOnPackage: this.searchForm.comeOnPackage,
         carePackage: this.searchForm.carePackage,
-        hasMember: this.searchForm.hasMember,
+        hasMember: this.searchForm.hasMember
       };
-      return getTeamStudentList(obj).then((res) => {
+      return getTeamStudentList(obj).then(res => {
         if (res.code == 200) {
           this.tableList = res.data.rows;
           this.rules.total = res.data.total;
@@ -1504,7 +1510,7 @@ export default {
     },
     removeCycle(index) {
       this.cycles[index] = null;
-      this.cycles = this.cycles.filter((item) => !!item);
+      this.cycles = this.cycles.filter(item => !!item);
       this.collapse.pop();
     },
     collapseChange(val) {
@@ -1518,18 +1524,18 @@ export default {
           status: this.$route.query.status,
           name: this.$route.query.name,
           rules: this.Frules,
-          search: this.Fsearch,
-        },
+          search: this.Fsearch
+        }
       });
     },
     chioseType() {
       // 父级验证子集表单
-      this.$refs["quitForm"].$refs["quitForm"].validate((res) => {
+      this.$refs["quitForm"].$refs["quitForm"].validate(res => {
         if (res) {
           this.$confirm("确定退团?", "提示", {
             confirmButtonText: "确定",
             cancelButtonText: "取消",
-            type: "warning",
+            type: "warning"
           })
             .then(() => {
               let row = this.activeRow;
@@ -1540,10 +1546,10 @@ export default {
                 reason: this.quitForm.reason,
                 isRefundCourseFee: this.quitForm.isRefundCourseFee,
                 isRefundInstrumentFee: this.quitForm.isRefundInstrumentFee,
-                isRefundTeachingAssistantsFee:
-                  this.quitForm.isRefundTeachingAssistantsFee,
+                isRefundTeachingAssistantsFee: this.quitForm
+                  .isRefundTeachingAssistantsFee,
                 maintenanceFee: this.quitForm.maintenanceFee,
-                isRefundMemberFee: this.quitForm.isRefundMemberFee,
+                isRefundMemberFee: this.quitForm.isRefundMemberFee
               };
               params.returnFeeDto = {
                 accessoriesFee: params.accessoriesFee,
@@ -1555,9 +1561,9 @@ export default {
                 isReturnMusicalFee: params.isReturnMusicalFee,
                 maintenanceFee: params.maintenanceFee,
                 memberFee: params.memberFee,
-                musicalFee: params.musicalFee,
+                musicalFee: params.musicalFee
               };
-              if (this.isManage!='staff') {
+              if (this.isManage != "staff") {
                 params.status = "APPROVED";
               } else {
                 params.status = "PROCESSING";
@@ -1565,7 +1571,7 @@ export default {
               // 退还云教练费用
 
               // 发请求 退团
-              applyMusicGroupQuit(params).then((res) => {
+              applyMusicGroupQuit(params).then(res => {
                 if (res.code == 200) {
                   this.quitForm = {
                     // 退团信息确认
@@ -1578,7 +1584,7 @@ export default {
                     musicGroupName: null,
                     isVisit: false,
                     reason: "",
-                    userComment: null,
+                    userComment: null
                   };
                   if (this.isManage == "super") {
                     this.$message.success("退团成功");
@@ -1600,7 +1606,7 @@ export default {
     //
     addStudent() {
       // 发请求添加学员
-      this.$refs["maskForm"].validate((res) => {
+      this.$refs["maskForm"].validate(res => {
         if (res) {
           // this.maskForm.parentName.timer  少个生日的字段
           // classGroupId: maskForm.signClass
@@ -1665,8 +1671,8 @@ export default {
               currentGradeNum: maskForm.currentGradeNum,
               currentClass: maskForm.course,
               subjectId: maskForm.sound,
-              musicGroupId: this.teamid,
-            },
+              musicGroupId: this.teamid
+            }
           };
           params.studentPaymentOrderDetails = [];
           if (maskForm.musicGoodsIdList) {
@@ -1674,7 +1680,7 @@ export default {
               goodsIdList: maskForm.musicGoodsIdList,
               kitGroupPurchaseType: maskForm.kitGroupPurchaseType,
               type: "MUSICAL",
-              price: maskForm.musicPrice,
+              price: maskForm.musicPrice
             });
           }
 
@@ -1682,11 +1688,11 @@ export default {
             params.studentPaymentOrderDetails.push({
               goodsIdList: maskForm.instrGoodsIdList.join(","),
               type: "ACCESSORIES",
-              price: maskForm.instrPrice,
+              price: maskForm.instrPrice
             });
           }
 
-          addStudent(params).then((res) => {
+          addStudent(params).then(res => {
             if (res.code == 200) {
               this.$message.success("添加学生成功");
               this.getList();
@@ -1715,8 +1721,8 @@ export default {
     findSubjectPlan(subjectId) {
       findSubjectPlan({
         musicGroupId: this.teamid,
-        subjectId: subjectId,
-      }).then((res) => {
+        subjectId: subjectId
+      }).then(res => {
         let result = res.data;
         if (res.code == 200) {
           this.maskForm.musicMode = this.getBranchType(
@@ -1729,16 +1735,16 @@ export default {
       getGoods({
         subjectId: subjectId,
         type: type,
-        organId: this.organId,
-      }).then((res) => {
+        organId: this.organId
+      }).then(res => {
         let result = res.data;
         if (res.code == 200) {
           let tempArr = [];
-          result.forEach((item) => {
+          result.forEach(item => {
             tempArr.push({
               label: item.name,
               value: item.id,
-              marketPrice: item.marketPrice,
+              marketPrice: item.marketPrice
             });
           });
           if (type == "ACCESSORIES") {
@@ -1754,7 +1760,7 @@ export default {
       let common = {
         FREE: "免费",
         GROUP: "团购",
-        LEASE: "租赁",
+        LEASE: "租赁"
       };
       return common[status];
     },
@@ -1762,8 +1768,8 @@ export default {
       this.classMask.studentName = row.realName;
       getStudentClass({
         musicGroupId: this.teamid,
-        teacherId: row.userId,
-      }).then((res) => {
+        teacherId: row.userId
+      }).then(res => {
         if (res.code == 200) {
           this.classLists = res.data;
           this.studentClassVisible = true;
@@ -1777,7 +1783,7 @@ export default {
       try {
         const res = await getRefundsDetail({
           musicGroupId: this.$route.query.id,
-          userId: row.userId,
+          userId: row.userId
         });
         this.quitForm = {
           ...this.quitForm,
@@ -1785,7 +1791,7 @@ export default {
           courseViewType: this.baseInfo.courseViewType,
           studentName: row.realName,
           musicGroupName: this.baseInfo.name,
-          hasMaintenance: row.hasMaintenance,
+          hasMaintenance: row.hasMaintenance
         };
         this.activeRow = { ...row, ...res.data };
         this.quitVisible = true;
@@ -1836,7 +1842,7 @@ export default {
       var regu = /^1[3456789]\d{9}$/;
       var re = new RegExp(regu);
       if (re.test(val)) {
-        getStudentInfoByPhone({ mobile: this.maskForm.phone }).then((res) => {
+        getStudentInfoByPhone({ mobile: this.maskForm.phone }).then(res => {
           if (res.code == 200) {
             if (res.data) {
               this.maskForm.studentName = res.data.name;
@@ -1858,7 +1864,7 @@ export default {
       this.$confirm("是否锁定/解锁学生缴费周期?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
           let musicGroupId = this.teamid;
@@ -1866,7 +1872,7 @@ export default {
           let isLock;
           row.isLock == 0 ? (isLock = 1) : (isLock = 0);
 
-          StudentFeeIsLock({ musicGroupId, studentId, isLock }).then((res) => {
+          StudentFeeIsLock({ musicGroupId, studentId, isLock }).then(res => {
             if (res.code == 200) {
               this.$message.success("修改成功");
               this.getList();
@@ -1894,9 +1900,9 @@ export default {
         studentId,
         musicGroupId,
         month,
-        amount,
+        amount
       };
-      updateStudentFee(obj).then((res) => {
+      updateStudentFee(obj).then(res => {
         if (res.code == 200) {
           this.$message.success("修改成功");
           this.payVisible = false;
@@ -1921,9 +1927,9 @@ export default {
       this.visitForm.purpose = val[1];
     },
     submitAddVisit() {
-      this.$refs.visitForm.validate((res) => {
+      this.$refs.visitForm.validate(res => {
         if (res) {
-          addVisit(cleanDeep(this.visitForm)).then((res) => {
+          addVisit(cleanDeep(this.visitForm)).then(res => {
             if (res.code === 200) {
               this.$message.success("新增成功");
               this.visitVisiable = false;
@@ -1938,7 +1944,7 @@ export default {
         firstDayOfWeek: 1,
         disabledDate(time) {
           return time.getTime() >= new Date().getTime(); //开始时间不选时,结束时间最大值小于等于当天
-        },
+        }
       };
     },
     createStudentFrom() {
@@ -1958,7 +1964,7 @@ export default {
           } else {
             return false;
           }
-        },
+        }
       };
     },
     applyDate() {
@@ -1974,7 +1980,7 @@ export default {
           } else {
             return false;
           }
-        },
+        }
       };
     },
     handleSelectionChange(val) {
@@ -1982,7 +1988,11 @@ export default {
     },
     checkboxSelect(row) {
       // 没有会员时间,未购买会员的
-      return row.studentStatus == "NORMAL" && !row.membershipEndTime && !row.hasNoStartCloudTeacher;
+      return (
+        row.studentStatus == "NORMAL" &&
+        !row.membershipEndTime &&
+        !row.hasNoStartCloudTeacher
+      );
     },
     gotoStudent(search) {
       // this.$router.push({
@@ -1992,10 +2002,10 @@ export default {
 
       this.$router.push({
         name: "studentList",
-        params: { search: search },
+        params: { search: search }
       });
     },
-        async getAgreement() {
+    async getAgreement() {
       try {
         const res = await getAgreement();
         if (!res.data) {
@@ -2005,7 +2015,7 @@ export default {
       if (this.submitList.length > 0) {
         this.$bus.$emit("showguide", this.submitList);
       }
-    },
+    }
     // addTryTime() {
     //   if (this.multipleSelection.length > 0) {
     //     this.addTryVisible = true;
@@ -2036,11 +2046,11 @@ export default {
           musicGroupName: null,
           isVisit: false,
           reason: "",
-          userComment: null,
+          userComment: null
         };
         this.$refs["quitForm"].$refs["quitForm"].resetFields();
       }
-    },
+    }
     // visitVisiable(val) {
     //   if (!val) {
     //     this.$refs["visitForm"].resetFields();
@@ -2051,8 +2061,8 @@ export default {
     saveKey() {
       // return 'teamDetails-'+this.$route.query.id
       return "teamDetails-studentList|id|" + this.$route.query.id;
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss" scoped>
@@ -2166,14 +2176,14 @@ export default {
     margin-right: 10px;
   }
 }
-::v-deep  .el-collapse-item__wrap {
+::v-deep .el-collapse-item__wrap {
   padding-top: 20px;
 }
 .cycleForm {
-  ::v-deep  .el-form-item {
+  ::v-deep .el-form-item {
     display: flex;
     width: 100%;
-    ::v-deep  .el-form-item__content {
+    ::v-deep .el-form-item__content {
       margin-left: 0 !important;
       flex: 1;
     }

+ 148 - 131
src/views/teamDetail/teamList.vue

@@ -32,7 +32,7 @@
             v-model.trim="topForm.search"
             clearable
             @keyup.enter.native="
-              (e) => {
+              e => {
                 e.target.blur();
                 $refs.topForm.save();
                 search();
@@ -93,22 +93,7 @@
             ></el-option>
           </el-select>
         </el-form-item>
-        <!-- 收费类型 -->
-        <el-form-item prop="payType">
-          <el-select
-            v-model.trim="topForm.payType"
-            filterable
-            placeholder="请选择收费类型"
-            clearable
-          >
-            <el-option
-              v-for="(item, index) in typeList"
-              :key="index"
-              :label="item.name"
-              :value="item.id"
-            ></el-option>
-          </el-select>
-        </el-form-item>
+
         <el-form-item prop="isStartedCourse">
           <el-select
             v-model.trim="topForm.isStartedCourse"
@@ -145,7 +130,7 @@
             start-placeholder="申请开始日期"
             end-placeholder="申请结束日期"
             :picker-options="{
-              firstDayOfWeek: 1,
+              firstDayOfWeek: 1
             }"
           ></el-date-picker>
         </el-form-item>
@@ -159,7 +144,7 @@
             start-placeholder="成团开始日期"
             end-placeholder="成团结束日期"
             :picker-options="{
-              firstDayOfWeek: 1,
+              firstDayOfWeek: 1
             }"
           ></el-date-picker>
         </el-form-item>
@@ -170,7 +155,10 @@
           <el-button type="primary" native-type="reset">重置</el-button>
         </el-form-item>
         <el-form-item>
-          <el-button type="primary" v-permission="'export/musicGroup'" @click="onExport"
+          <el-button
+            type="primary"
+            v-permission="'export/musicGroup'"
+            @click="onExport"
             >导出</el-button
           >
         </el-form-item>
@@ -191,14 +179,24 @@
             align="center"
             label="所属分部"
           ></el-table-column>
-          <el-table-column prop="id" width="100" align="center" label="乐团编号">
+          <el-table-column
+            prop="id"
+            width="100"
+            align="center"
+            label="乐团编号"
+          >
             <template slot-scope="scope">
               <copy-text>
                 {{ scope.row.id }}
               </copy-text>
             </template>
           </el-table-column>
-          <el-table-column prop="name" width="200px" align="center" label="乐团名称">
+          <el-table-column
+            prop="name"
+            width="200px"
+            align="center"
+            label="乐团名称"
+          >
             <template slot-scope="scope">
               <p>
                 {{ scope.row.name }}
@@ -227,12 +225,18 @@
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center" prop="chargeTypeName" label="收费类型">
-          </el-table-column>
-          <el-table-column prop="educationalTeacherName" align="center" label="乐团主管">
+          <el-table-column
+            prop="educationalTeacherName"
+            align="center"
+            label="乐团主管"
+          >
           </el-table-column>
 
-          <el-table-column prop="groupMemberNum" align="center" label="成团人数">
+          <el-table-column
+            prop="groupMemberNum"
+            align="center"
+            label="成团人数"
+          >
           </el-table-column>
           <el-table-column prop="payNum" align="center" label="在读人数">
           </el-table-column>
@@ -276,21 +280,30 @@
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center" width="220px" fixed="right" label="操作">
+          <el-table-column
+            align="center"
+            width="220px"
+            fixed="right"
+            label="操作"
+          >
             <template slot-scope="scope">
               <div>
                 <!-- 审核中 编辑 -->
                 <el-button
                   type="text"
                   v-if="
-                    scope.row.status == 'AUDIT' && permission('musicGroup/auditSuccess')
+                    scope.row.status == 'AUDIT' &&
+                      permission('musicGroup/auditSuccess')
                   "
                   @click="lookTeamDetail(scope.row)"
                   >审核</el-button
                 >
                 <el-button
                   type="text"
-                  v-if="scope.row.status == 'DRAFT' && permission('musicGroup/update')"
+                  v-if="
+                    scope.row.status == 'DRAFT' &&
+                      permission('musicGroup/update')
+                  "
                   @click="lookTeamDetail(scope.row)"
                   >编辑</el-button
                 >
@@ -298,7 +311,8 @@
                 <el-button
                   type="text"
                   v-if="
-                    scope.row.status == 'AUDIT_FAILED' && permission('musicGroup/update')
+                    scope.row.status == 'AUDIT_FAILED' &&
+                      permission('musicGroup/update')
                   "
                   @click="lookTeamDetail(scope.row)"
                   >编辑</el-button
@@ -307,7 +321,7 @@
                   type="text"
                   v-if="
                     scope.row.status == 'FEE_AUDIT_FAILED' &&
-                    permission('musicGroup/update')
+                      permission('musicGroup/update')
                   "
                   @click="lookTeamDetail(scope.row)"
                   >编辑</el-button
@@ -325,7 +339,7 @@
                       scope.row.status == 'PREPARE' ||
                       scope.row.status == 'CLOSE' ||
                       scope.row.status == 'FEE_AUDIT') &&
-                    permission('/resetTeaming')
+                      permission('/resetTeaming')
                   "
                   @click="lookTeamDetail(scope.row)"
                   >详情</el-button
@@ -341,7 +355,7 @@
                   type="text"
                   v-if="
                     scope.row.status == 'PROGRESS' &&
-                    permission('musicGroup/closeMusicGroup')
+                      permission('musicGroup/closeMusicGroup')
                   "
                   @click="closeTeamDetail(scope.row)"
                   >关闭</el-button
@@ -366,14 +380,17 @@
                       scope.row.status == 'PAY' ||
                       scope.row.status == 'PRE_APPLY' ||
                       scope.row.status == 'DRAFT') &&
-                    permission('musicGroup/cancelMusicGroup')
+                      permission('musicGroup/cancelMusicGroup')
                   "
                   @click="stopTeam(scope.row)"
                   >取消乐团</el-button
                 >
 
                 <el-button
-                  v-if="scope.row.status == 'PREPARE' && permission('musicGroup/action')"
+                  v-if="
+                    scope.row.status == 'PREPARE' &&
+                      permission('musicGroup/action')
+                  "
                   @click="startTeam(scope.row)"
                   type="text"
                   >确认成团</el-button
@@ -383,8 +400,9 @@
                            @click="stopTeam(scope.row)">取消乐团</el-button> -->
                 <el-button
                   v-if="
-                    (scope.row.status == 'PAUSE' || scope.row.status == 'CLOSE') &&
-                    permission('musicGroup/resumeMusicGroup')
+                    (scope.row.status == 'PAUSE' ||
+                      scope.row.status == 'CLOSE') &&
+                      permission('musicGroup/resumeMusicGroup')
                   "
                   @click="onTeamOpeation('start', scope.row)"
                   type="text"
@@ -393,7 +411,7 @@
                 <el-button
                   v-if="
                     scope.row.status == 'PROGRESS' &&
-                    permission('musicGroup/pauseMusicGroup')
+                      permission('musicGroup/pauseMusicGroup')
                   "
                   @click="onTeamOpeation('pause', scope.row)"
                   type="text"
@@ -403,7 +421,7 @@
                 <el-button
                   v-if="
                     scope.row.status == 'CANCELED' &&
-                    permission('musicGroup/deleteMusicGroup')
+                      permission('musicGroup/deleteMusicGroup')
                   "
                   @click="deteleTeaming(scope.row)"
                   type="text"
@@ -443,7 +461,7 @@
 </template>
 <script>
 import pagination from "@/components/Pagination/index";
-import { getTeamList, getPayType } from "@/api/teamServer";
+import { getTeamList } from "@/api/teamServer";
 import qs from "qs";
 import cleanDeep from "clean-deep";
 import {
@@ -453,7 +471,7 @@ import {
   getEmployeeOrgan,
   pauseMusicGroup,
   resumeMusicGroup,
-  deleteMusicGroup,
+  deleteMusicGroup
 } from "@/api/buildTeam";
 import { musicGroupStatus, courseViewTypeList } from "@/utils/searchArray";
 import { isObject } from "util";
@@ -474,17 +492,15 @@ export default {
       topForm: {
         search: "",
         status: "",
-        payType: "",
         word: "",
         orgin: [],
         courseViewType: "",
         billTimer: [],
         createTimer: [],
         cooperationOrganId: null,
-        isStartedCourse: null,
+        isStartedCourse: null
       },
       organList: [],
-      typeList: [], // 收费类型
       nowStatus: musicGroupStatus,
       searchLsit: [], // 存储选择后的数组
       tableData: [], // table数据
@@ -493,19 +509,19 @@ export default {
         limit: 10, // 限制显示条数
         page: 1, // 当前页
         total: 0, // 总条数
-        page_size: [10, 20, 40, 50], // 选择限制显示条数
+        page_size: [10, 20, 40, 50] // 选择限制显示条数
       },
       passed: [], // 传递的参数
       showSteam: false,
       activeId: null,
-      cooperationList: [],
+      cooperationList: []
     };
   },
   components: {
     pagination,
     teamSteam,
     closeStudens,
-    Tooltip,
+    Tooltip
   },
   mounted() {
     const { query } = this.$route;
@@ -534,17 +550,11 @@ export default {
     init() {
       localStorage.setItem("resetCode", "1");
 
-      getEmployeeOrgan().then((res) => {
+      getEmployeeOrgan().then(res => {
         if (res.code == 200) {
           this.organList = res.data;
         }
       });
-      // 获取乐团收费类型
-      getPayType().then((res) => {
-        if (res.code == 200) {
-          this.typeList = res.data;
-        }
-      });
       // 获取乐团合作单位(学校)
       // getCooperation().then(res => {
       // })
@@ -568,16 +578,19 @@ export default {
         rows: this.rules.limit,
         page: this.rules.page,
         organId: this.topForm.orgin.join(","),
-        chargeTypeId: this.topForm.payType || null,
         search: this.topForm.search || null,
         musicGroupStatus: this.topForm.status || null,
         courseViewType: this.topForm.courseViewType || null,
         cooperationOrganId: this.topForm.cooperationOrganId || null,
         searchType: this.$route.query.searchType,
         isStartedCourse: this.topForm.isStartedCourse,
-        ...getTimes(createTimer, ["createStartDate", "createEndDate"], "YYYY-MM-DD"),
-        ...getTimes(billTimer, ["billStartDate", "billEndDate"], "YYYY-MM-DD"),
-      }).then((res) => {
+        ...getTimes(
+          createTimer,
+          ["createStartDate", "createEndDate"],
+          "YYYY-MM-DD"
+        ),
+        ...getTimes(billTimer, ["billStartDate", "billEndDate"], "YYYY-MM-DD")
+      }).then(res => {
         if (res.code == 200) {
           this.tableData = res.data.rows;
           this.rules.total = res.data.total;
@@ -591,9 +604,9 @@ export default {
       this.$router.push(
         {
           path: "/business/resetTeaming",
-          query: { type: "newTeam", team_status: "newTeam" },
+          query: { type: "newTeam", team_status: "newTeam" }
         },
-        (router) => {
+        router => {
           router.meta.title = "新建乐团";
         }
       );
@@ -607,17 +620,17 @@ export default {
       }
       this.$router.push({
         path: "/business/teamDraft",
-        query: { type: "teamList", teamList: this.passed },
+        query: { type: "teamList", teamList: this.passed }
       });
     },
     resetTeaming(row) {
       // 修改进行中的乐团
       localStorage.removeItem(`${row.id}base`);
       localStorage.removeItem(`${row.id}sound`);
-      this.$nextTick((res) => {
+      this.$nextTick(res => {
         this.$router.push({
           path: "/business/resetTeaming",
-          query: { type: "resetTeam", id: row.id },
+          query: { type: "resetTeam", id: row.id }
         });
       });
     },
@@ -627,7 +640,7 @@ export default {
       // 有相同的key => 替换这个对象
       if (obj.type == 1) {
         let flag = false;
-        this.searchLsit = this.searchLsit.map((item) => {
+        this.searchLsit = this.searchLsit.map(item => {
           if (item.id == obj.id) {
             item = obj;
             flag = true;
@@ -639,7 +652,7 @@ export default {
         }
       } else {
         let flag = false;
-        this.searchLsit = this.searchLsit.map((item) => {
+        this.searchLsit = this.searchLsit.map(item => {
           if (item.key == obj.key) {
             // 多选框的再次点击=> 等于 就是删除
             item = obj;
@@ -689,10 +702,10 @@ export default {
         this.$confirm("是否确定开启乐团?", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
-          type: "warning",
+          type: "warning"
         })
           .then(() => {
-            resumeMusicGroup({ musicGroupId: row.id }).then((res) => {
+            resumeMusicGroup({ musicGroupId: row.id }).then(res => {
               if (res.code == 200) {
                 this.$message.success("开启成功");
                 this.getList();
@@ -706,10 +719,10 @@ export default {
         this.$confirm("是否确定暂停乐团?", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
-          type: "warning",
+          type: "warning"
         })
           .then(() => {
-            pauseMusicGroup({ musicGroupId: row.id }).then((res) => {
+            pauseMusicGroup({ musicGroupId: row.id }).then(res => {
               if (res.code == 200) {
                 this.$message.success("暂停成功");
                 this.getList();
@@ -729,7 +742,7 @@ export default {
       // 查看课表
       this.$router.push({
         path: "/teamListCourse",
-        query: { id: row.id, name: row.name },
+        query: { id: row.id, name: row.name }
       });
     },
     lookTeamDetail(row) {
@@ -753,9 +766,9 @@ export default {
           this.$router.push(
             {
               path: "/business/resetTeaming",
-              query: { type: "teamDraft", id: row.id, team_status: row.status },
+              query: { type: "teamDraft", id: row.id, team_status: row.status }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团编辑中";
             }
           );
@@ -772,10 +785,10 @@ export default {
                 type: "teamAudit",
                 id: row.id,
                 clear: "true",
-                team_status: row.status,
-              },
+                team_status: row.status
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团审核中";
             }
           );
@@ -795,10 +808,10 @@ export default {
                 id: row.id,
                 name: row.name,
                 team_status: "DRAFT",
-                tabrouter: 3,
-              },
+                tabrouter: 3
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "创建缴费中";
             }
           );
@@ -814,10 +827,10 @@ export default {
                 type: "feeAudit",
                 id: row.id,
                 clear: "true",
-                team_status: row.status,
-              },
+                team_status: row.status
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团费用审核中";
             }
           );
@@ -833,10 +846,10 @@ export default {
                 type: "teamDraft",
                 id: row.id,
                 clear: "true",
-                team_status: row.status,
-              },
+                team_status: row.status
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团审核失败";
             }
           );
@@ -853,10 +866,10 @@ export default {
                 id: row.id,
                 clear: "true",
                 team_status: row.status,
-                tabrouter: 3,
-              },
+                tabrouter: 3
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "费用审核失败";
             }
           );
@@ -873,10 +886,10 @@ export default {
                 id: row.id,
                 name: row.name,
                 team_status: "PRE_APPLY",
-                tabrouter: 9,
-              },
+                tabrouter: 9
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团预报名";
             }
           );
@@ -897,10 +910,10 @@ export default {
                 name: row.name,
                 team_status: "APPLY",
                 type: "look",
-                tabrouter: 11,
-              },
+                tabrouter: 11
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团报名中";
             }
           );
@@ -917,10 +930,10 @@ export default {
                 name: row.name,
                 team_status: "PAY",
                 type: "look",
-                tabrouter: 11,
-              },
+                tabrouter: 11
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团缴费中";
             }
           );
@@ -937,10 +950,10 @@ export default {
                 id: row.id,
                 name: row.name,
                 team_status: row.status,
-                tabrouter: 10,
-              },
+                tabrouter: 10
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团筹备中";
             }
           );
@@ -958,10 +971,10 @@ export default {
                 name: row.name,
                 organId: row.organId,
                 type: "resetTeam",
-                team_status: row.status,
-              },
+                team_status: row.status
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团进行中";
             }
           );
@@ -975,10 +988,10 @@ export default {
               query: {
                 type: "teamCanceled",
                 id: row.id,
-                team_status: row.status,
-              },
+                team_status: row.status
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "取消乐团";
             }
           );
@@ -993,9 +1006,9 @@ export default {
           this.$router.push(
             {
               path: "/business/resetTeaming",
-              query: { type: "resetTeam", id: row.id, team_status: row.status },
+              query: { type: "resetTeam", id: row.id, team_status: row.status }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团暂停";
             }
           );
@@ -1010,10 +1023,10 @@ export default {
                 id: row.id,
                 name: row.name,
                 team_status: "CLOSE",
-                type: "look",
-              },
+                type: "look"
+              }
             },
-            (router) => {
+            router => {
               router.meta.title = "乐团关闭";
             }
           );
@@ -1035,7 +1048,7 @@ export default {
     gotodetailList(row) {
       this.$router.push({
         path: "/teamListedList",
-        query: { id: row.id },
+        query: { id: row.id }
       });
     },
     //
@@ -1048,8 +1061,8 @@ export default {
           type: "look",
           id: row.id,
           name: row.name,
-          team_status: row.status,
-        },
+          team_status: row.status
+        }
       });
     },
     // setImprovement 设置基础技能班
@@ -1058,7 +1071,7 @@ export default {
       let rules = JSON.stringify(this.rules);
       this.$router.push({
         path: "/business/setImprovement",
-        query: { id: row.id },
+        query: { id: row.id }
       });
     },
     // 停止乐团
@@ -1066,12 +1079,12 @@ export default {
       this.$confirm("您确定取消申请乐团?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
           cancelMusicGroup({
-            musicGroupId: row.id,
-          }).then((res) => {
+            musicGroupId: row.id
+          }).then(res => {
             if (res.code == 200) {
               this.$message.success("停止成功");
               this.getList();
@@ -1085,10 +1098,10 @@ export default {
       this.$confirm("是否确定成团?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
-          startTeam({ musicGroupId: row.id }).then((res) => {
+          startTeam({ musicGroupId: row.id }).then(res => {
             if (res.code == 200) {
               this.$message.success("开启乐团成功");
               this.getList();
@@ -1101,12 +1114,12 @@ export default {
       this.$confirm("您确定删除该乐团?", "提示", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning",
+        type: "warning"
       })
         .then(() => {
           deleteMusicGroup({
-            musicGroupId: row.id,
-          }).then((res) => {
+            musicGroupId: row.id
+          }).then(res => {
             if (res.code == 200) {
               this.$message.success("删除成功");
               this.getList();
@@ -1123,9 +1136,9 @@ export default {
       this.$router.push(
         {
           path: `/business/remedy`,
-          query: { status: row.status, id: row.id, name: row.name },
+          query: { status: row.status, id: row.id, name: row.name }
         },
-        (router) => {
+        router => {
           router.meta.title = "报名详情";
         }
       );
@@ -1135,9 +1148,13 @@ export default {
       let obj = {
         ...reset,
         organId: this.topForm.orgin.join(",") || null,
-        ...getTimes(createTimer, ["createStartDate", "createEndDate"], "YYYY-MM-DD"),
+        ...getTimes(
+          createTimer,
+          ["createStartDate", "createEndDate"],
+          "YYYY-MM-DD"
+        ),
         searchType: this.$route.query.searchType,
-        ...getTimes(billTimer, ["billStartDate", "billEndDate"], "YYYY-MM-DD"),
+        ...getTimes(billTimer, ["billStartDate", "billEndDate"], "YYYY-MM-DD")
       };
       await Export(
         this,
@@ -1145,7 +1162,7 @@ export default {
           url: "/api-web/export/musicGroup",
           fileName: "乐团列表.xls",
           method: "post",
-          params: qs.stringify(cleanDeep(obj)),
+          params: qs.stringify(cleanDeep(obj))
         },
         "您确定导出乐团列表?"
       );
@@ -1157,21 +1174,21 @@ export default {
         return;
       }
       // 合作单位
-      await queryByOrganId({ organId: value.join(",") }).then((res) => {
+      await queryByOrganId({ organId: value.join(",") }).then(res => {
         if (res.code == 200) {
           this.cooperationList = res.data;
           this.topForm.cooperationOrganId = null;
         }
       });
-    },
+    }
   },
   watch: {
     showSteam(val) {
       if (!val) {
         this.activeId = null;
       }
-    },
-  },
+    }
+  }
 };
 </script>
 <style lang="scss" scoped>