user-pay-form.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738
  1. <template>
  2. <div>
  3. <el-alert
  4. title="课程信息设置"
  5. :closable="false"
  6. class="alert"
  7. v-if="paymentTypeString !== 'SPAN_GROUP_CLASS_ADJUST'"
  8. type="info"
  9. >
  10. </el-alert>
  11. <userBaseinfo
  12. :form.sync="form"
  13. :isCommon="isCommon"
  14. v-if="paymentTypeString !== 'SPAN_GROUP_CLASS_ADJUST'"
  15. :isUserType="isUserType"
  16. @getCharges="getCharges"
  17. @changeActive="changeActive"
  18. :typeList="typeList"
  19. :charges="charges"
  20. :rowDetail="rowDetail"
  21. :chargeTypeName="chargeTypeName"
  22. :paymentType="paymentType"
  23. ref="base"
  24. />
  25. <template v-if="paymentTypeString === 'SPAN_GROUP_CLASS_ADJUST'">
  26. <el-alert
  27. title="加课信息设置"
  28. :closable="false"
  29. class="alert"
  30. type="info"
  31. >
  32. </el-alert>
  33. <extraClassUser
  34. :form.sync="eclassuser"
  35. ref="eclass"
  36. :isUserType="isUserType"
  37. :courseUnitPriceSettingsByType="
  38. organizationCourseUnitPriceSettingsByType
  39. "
  40. @priceChange="priceChange"
  41. :clearable="true"
  42. @moneyChange="syncAllMoney"
  43. />
  44. </template>
  45. <template v-else-if="!isCommon">
  46. <el-alert
  47. title="加课信息设置"
  48. :closable="false"
  49. class="alert"
  50. type="info"
  51. >
  52. </el-alert>
  53. <extraClass
  54. :form.sync="eclass"
  55. ref="eclass"
  56. @create="addExtraClass"
  57. @remove="removeExtraClass"
  58. :isUserType="isUserType"
  59. :courseUnitPriceSettingsByType="
  60. organizationCourseUnitPriceSettingsByType
  61. "
  62. @priceChange="priceChange"
  63. :clearable="true"
  64. @moneyChange="syncAllMoney"
  65. />
  66. </template>
  67. <extraClass
  68. v-else-if="(!isCommon && eclass.length) || isCommon"
  69. :form="eclass"
  70. ref="eclass"
  71. :isCommon="isCommon"
  72. @create="addExtraClass"
  73. @remove="removeExtraClass"
  74. @moneyChange="syncAllMoney"
  75. :courseUnitPriceSettingsByType="organizationCourseUnitPriceSettingsByType"
  76. :isUserType="isUserType"
  77. :isDisabled="
  78. form.leixing === '1' || form.leixing === '2' || paymentType == '0'
  79. "
  80. />
  81. <template>
  82. <el-alert title="缴费设置" :closable="false" class="alert" type="info">
  83. </el-alert>
  84. <el-form ref="payment" :model="payment">
  85. <el-form-item
  86. label-width="160px"
  87. label="缴费方式"
  88. prop="paymentPattern"
  89. :rules="[
  90. { required: true, message: '请选择缴费方式', trigger: 'change' },
  91. ]"
  92. >
  93. <el-select
  94. style="width: 100% !important"
  95. v-model="payment.paymentPattern"
  96. placeholder="请选择缴费方式"
  97. >
  98. <el-option
  99. v-for="item in paymentPatternTypeOptions"
  100. :key="item.value"
  101. :label="item.label"
  102. :value="item.value"
  103. >
  104. </el-option>
  105. </el-select>
  106. </el-form-item>
  107. </el-form>
  108. <template
  109. v-if="isMulticycle && paymentTypeString !== 'SPAN_GROUP_CLASS_ADJUST'"
  110. >
  111. <el-collapse :value="collapse" @change="collapseChange">
  112. <el-collapse-item
  113. v-for="(item, index) in cycles"
  114. :key="index"
  115. :name="index"
  116. >
  117. <template slot="title">
  118. <div class="collapse-title">
  119. <span>缴费周期 {{ index + 1 }}</span>
  120. <i
  121. v-if="cycles.length > 1"
  122. class="el-icon-circle-close"
  123. @click.stop="removeCycle(index)"
  124. ></i>
  125. </div>
  126. </template>
  127. <paymentCycle
  128. ref="cycles"
  129. :form="item"
  130. :hidePaymentPattern="true"
  131. :isCommon="isCommon"
  132. :isUserType="isUserType"
  133. :isDisabled="
  134. form.leixing === '1' ||
  135. form.leixing === '2' ||
  136. paymentType == '0'
  137. "
  138. />
  139. </el-collapse-item>
  140. </el-collapse>
  141. <el-button
  142. icon="el-icon-circle-plus-outline"
  143. plain
  144. type="info"
  145. size="small"
  146. style="width: 100%; margin: 20px 0"
  147. @click="addCycle"
  148. >新增缴费周期</el-button
  149. >
  150. </template>
  151. <paymentCycle
  152. ref="cycle"
  153. :form.sync="cycle"
  154. :isCommon="isCommon"
  155. :hidePaymentPattern="true"
  156. :isUserType="isUserType"
  157. :isDisabled="
  158. form.leixing === '1' || form.leixing === '2' || paymentType == '0'
  159. "
  160. v-else
  161. />
  162. </template>
  163. <el-alert title="其它" :closable="false" class="alert" type="info">
  164. </el-alert>
  165. <otherform :form="other" ref="other" />
  166. <div slot="footer" class="dialog-footer">
  167. <el-button @click="$listeners.close">取 消</el-button>
  168. <el-button type="primary" @click="submit">确认</el-button>
  169. </div>
  170. <el-dialog
  171. :title="nextTitle"
  172. :visible.sync="nextVisible"
  173. width="600px"
  174. append-to-body
  175. >
  176. <classrooms @close="closeNext" />
  177. </el-dialog>
  178. </div>
  179. </template>
  180. <script>
  181. import {
  182. chargeTypeList,
  183. musicGroupOrganizationCourseSettingsQueryPage,
  184. } from "@/api/specialSetting";
  185. import { getMusicGroupPaymentCalenderDetail } from "@/api/buildTeam";
  186. import {
  187. musicGroupPaymentCalenderAdd,
  188. musicGroupPaymentCalenderDetailBatchUpdate,
  189. queryByMusicGroupOrganizationCourseSettingsId,
  190. musicGroupPaymentCalenderView,
  191. } from "../api";
  192. import { paymentPatternType } from "@/constant";
  193. import { getTimes, objectToOptions } from "@/utils";
  194. import userBaseinfo from "./user-baseinfo";
  195. import paymentCycle from "./payment-cycle";
  196. import extraClass from "./extra-class";
  197. import extraClassUser from "./extra-class-user";
  198. import classrooms from "./classrooms";
  199. import otherform from "./other";
  200. import baseInfoVue from "../../teamDetail/components/baseInfo.vue";
  201. import merge from "webpack-merge";
  202. import numeral from "numeral";
  203. const paymentTypeFormat = {
  204. 0: "MUSIC_APPLY",
  205. 1: "MUSIC_RENEW",
  206. 2: "ADD_COURSE",
  207. 3: "ADD_STUDENT",
  208. 4: "SPAN_GROUP_CLASS_ADJUST",
  209. };
  210. export default {
  211. props: [
  212. "type",
  213. "musicGroupId",
  214. "baseInfo",
  215. "paymentType",
  216. "rowDetail",
  217. "organizationCourseUnitPriceSettings",
  218. ],
  219. components: {
  220. userBaseinfo,
  221. paymentCycle,
  222. extraClass,
  223. extraClassUser,
  224. classrooms,
  225. otherform,
  226. },
  227. data() {
  228. return {
  229. options: [],
  230. form: {
  231. payUserType: this.type === "user" ? "STUDENT" : "SCHOOL",
  232. leixing: "1",
  233. musicGroupOrganizationCourseSettingId: null,
  234. },
  235. chargeTypeName: "",
  236. other: {},
  237. cycles: [{}],
  238. cycle: {},
  239. eclass: [],
  240. eclassuser: [],
  241. collapse: [0],
  242. nextVisible: false,
  243. typeList: [],
  244. charges: [],
  245. studentIds: "",
  246. payment: {
  247. paymentPattern: null,
  248. },
  249. viewDetail: null,
  250. organizationCourseUnitPriceSettingsByType: {},
  251. paymentPatternTypeOptions: objectToOptions(paymentPatternType),
  252. };
  253. },
  254. computed: {
  255. musicGroup() {
  256. return this.baseInfo?.musicGroup;
  257. },
  258. isCommon() {
  259. return this.form.leixing === "1";
  260. },
  261. isDisabled() {
  262. return this.form.leixing === "1" || String(this.paymentType) === "0";
  263. },
  264. isUserType() {
  265. return this.type === "user";
  266. },
  267. nextTitle() {
  268. return this.isCommon ? "乐团课程-班级选择" : "临时加课-班级选择";
  269. },
  270. chargesById() {
  271. const data = {};
  272. for (const item of this.charges) {
  273. data[item.id] = item;
  274. }
  275. return data;
  276. },
  277. paymentAmountDisabled() {
  278. return (
  279. (this.isUserType || (this.isCommon && this.isUserType)) &&
  280. this.isDisabled
  281. );
  282. },
  283. isMulticycle() {
  284. let editMulticycle = false;
  285. let paymentType = "";
  286. if (this.viewDetail) {
  287. const { musicGroupPaymentCalenders, auditDto } = this.viewDetail;
  288. paymentType = musicGroupPaymentCalenders[0]?.paymentType;
  289. editMulticycle =
  290. musicGroupPaymentCalenders.length > 1 || paymentType != "ADD_COURSE";
  291. if (editMulticycle) {
  292. this.cycles = musicGroupPaymentCalenders.map((item) => ({
  293. paymentAmount: item.paymentAmount,
  294. paymentDate: [item?.startPaymentDate, item?.deadlinePaymentDate],
  295. paymentValid: [
  296. item?.paymentValidStartDate,
  297. item?.paymentValidEndDate,
  298. ],
  299. }));
  300. }
  301. }
  302. return (
  303. (this.payment.paymentPattern == 0 &&
  304. this.form.leixing !== "2" &&
  305. paymentType !== "ADD_COURSE") ||
  306. (this.payment.paymentPattern == 0 && editMulticycle)
  307. );
  308. },
  309. paymentTypeString() {
  310. let paymentType = "";
  311. if (this.viewDetail) {
  312. const { musicGroupPaymentCalenders } = this.viewDetail;
  313. paymentType = musicGroupPaymentCalenders[0]?.paymentType;
  314. }
  315. return paymentType;
  316. },
  317. },
  318. watch: {
  319. type() {
  320. this.$set(
  321. this.form,
  322. "payUserType",
  323. this.type === "user" ? "STUDENT" : "SCHOOL"
  324. );
  325. },
  326. baseInfo(val) {
  327. this.formatCourse();
  328. this.getCharges();
  329. },
  330. organizationCourseUnitPriceSettings() {
  331. this.formatCourse();
  332. },
  333. "form.leixing"(val) {
  334. this.cycles = [{}];
  335. this.collapse = [0];
  336. this.cycle = {};
  337. this.$set(this.form, "musicGroupOrganizationCourseSettingId", undefined);
  338. this.$set(this.cycle, "paymentAmount", undefined);
  339. if (val === "1") {
  340. this.eclass = [];
  341. } else if (val === "2") {
  342. this.eclass = [{}];
  343. }
  344. },
  345. async "form.musicGroupOrganizationCourseSettingId"(val) {
  346. if (val && !this.rowDetail) {
  347. try {
  348. const res = await queryByMusicGroupOrganizationCourseSettingsId({
  349. id: val,
  350. });
  351. this.eclass = res.data.filter((item) => {
  352. return !item.isStudentOptional || this.paymentType !== undefined;
  353. }) || [{}];
  354. this.syncAllMoney();
  355. } catch (error) {}
  356. }
  357. },
  358. "payment.paymentPattern"() {
  359. this.syncAllMoney();
  360. },
  361. },
  362. mounted() {
  363. this.formatCourse();
  364. this.init();
  365. },
  366. activated() {
  367. this.formatCourse();
  368. this.init();
  369. },
  370. methods: {
  371. async init() {
  372. this.getCharges();
  373. if (this.rowDetail) {
  374. for (const key in paymentTypeFormat) {
  375. if (paymentTypeFormat.hasOwnProperty(key)) {
  376. const item = paymentTypeFormat[key];
  377. if (item === this.rowDetail.paymentType) {
  378. this.paymentType = key;
  379. }
  380. }
  381. }
  382. this.$set(
  383. this.other,
  384. "isGiveMusicNetwork",
  385. this.rowDetail.isGiveMusicNetwork
  386. );
  387. this.$set(this.other, "memo", this.rowDetail.memo);
  388. try {
  389. const res = await musicGroupPaymentCalenderView({
  390. musicGroupId: this.musicGroupId,
  391. batchNo: this.rowDetail.batchNo,
  392. });
  393. this.viewDetail = res.data;
  394. const firstPayment = res.data.musicGroupPaymentCalenders[0] || {};
  395. this.eclass = (
  396. res.data.musicGroupPaymentCalenderCourseSettings || []
  397. ).filter((item) => {
  398. return !item.isStudentOptional || this.paymentType !== undefined;
  399. });
  400. this.eclassuser = res.data.musicGroupPaymentCalenderStudentDetails.map(
  401. (item) => {
  402. if (this.paymentTypeString === "SPAN_GROUP_CLASS_ADJUST") {
  403. return {
  404. ...item,
  405. courseOriginalPrice: item.masterSubCoursePrice,
  406. };
  407. }
  408. return item;
  409. }
  410. );
  411. this.$set(
  412. this.payment,
  413. "paymentPattern",
  414. String(this.viewDetail.auditDto?.paymentPattern)
  415. );
  416. if (this.$refs.cycle) {
  417. this.$set(
  418. this.cycle,
  419. "paymentPattern",
  420. firstPayment.paymentPattern + ""
  421. );
  422. let arr = [
  423. firstPayment.paymentValidStartDate,
  424. firstPayment.paymentValidEndDate,
  425. ];
  426. // paymentDate startPaymentDate deadlinePaymentDate
  427. this.$set(this.cycle, "paymentDate", [
  428. firstPayment.startPaymentDate,
  429. firstPayment.deadlinePaymentDate,
  430. ]);
  431. this.$set(this.cycle, "paymentValid", arr);
  432. }
  433. this.studentIds = firstPayment.studentIds;
  434. this.$set(
  435. this.form,
  436. "musicGroupOrganizationCourseSettingId",
  437. res.data.auditDto?.musicGroupOrganizationCourseSettingsId
  438. );
  439. this.syncAllMoney();
  440. } catch (error) {}
  441. }
  442. },
  443. formatCourse() {
  444. const organId = this.musicGroup?.organId;
  445. const chargeTypeId = this.musicGroup?.chargeTypeId;
  446. const _ = {};
  447. const list = (this.organizationCourseUnitPriceSettings || []).filter(
  448. (item) =>
  449. organId &&
  450. organId == item.organId &&
  451. chargeTypeId &&
  452. chargeTypeId == item.chargeTypeId
  453. );
  454. for (const item of list) {
  455. _[item.courseType] = item;
  456. }
  457. this.organizationCourseUnitPriceSettingsByType = _;
  458. return _;
  459. },
  460. priceChange(item, index) {
  461. const _ = [...this.eclass];
  462. const active =
  463. this.organizationCourseUnitPriceSettingsByType[item.courseType] || {};
  464. const price = Math.round(
  465. numeral(active.unitPrice || 1)
  466. .multiply(item.courseTotalMinuties || 1)
  467. .value()
  468. );
  469. item.courseCurrentPrice = price;
  470. item.courseOriginalPrice = price;
  471. _[index] = item;
  472. this.eclass = [..._];
  473. this.syncAllMoney();
  474. },
  475. syncAllMoney() {
  476. if (this.paymentTypeString === "SPAN_GROUP_CLASS_ADJUST") {
  477. const money = this.viewDetail?.musicGroupPaymentCalenders[0]
  478. .paymentAmount;
  479. this.$set(this.cycle, "paymentAmount", money);
  480. return money;
  481. }
  482. let money = 0;
  483. let first = 0;
  484. let other = 0;
  485. let classs =
  486. this.paymentTypeString === "SPAN_GROUP_CLASS_ADJUST"
  487. ? this.eclassuser
  488. : this.eclass;
  489. for (const item of classs) {
  490. money += item.courseCurrentPrice;
  491. if (this.cycles && this.cycles.length) {
  492. if (item.isStudentOptional) {
  493. first += item.courseCurrentPrice;
  494. } else {
  495. const floorMoney = Math.floor(
  496. item.courseCurrentPrice / this.cycles.length
  497. );
  498. const remainder = item.courseCurrentPrice % this.cycles.length;
  499. first += floorMoney + remainder;
  500. other += floorMoney;
  501. }
  502. }
  503. }
  504. if (this.cycles && this.cycles.length) {
  505. this.cycles = this.cycles.map((item, index) => {
  506. return {
  507. ...item,
  508. paymentAmount: index === 0 ? first : other,
  509. };
  510. });
  511. }
  512. // if (!money) {
  513. // this.$set(this.cycle, "paymentAmount", undefined);
  514. // } else {
  515. this.$set(this.cycle, "paymentAmount", money);
  516. // }
  517. return money;
  518. },
  519. async getChargeTypeList() {
  520. try {
  521. const res = await chargeTypeList({
  522. row: 9999,
  523. });
  524. this.typeList = res.data.rows;
  525. } catch (error) {}
  526. },
  527. async getCharges() {
  528. const organId = this.musicGroup?.organId;
  529. const chargeTypeId = this.musicGroup?.chargeTypeId;
  530. this.chargeTypeName = this.musicGroup?.chargeTypeName;
  531. try {
  532. const res = await musicGroupOrganizationCourseSettingsQueryPage({
  533. row: 9999,
  534. chargeTypeId,
  535. organId,
  536. });
  537. const ids = res.data.rows.map((item) => item.id);
  538. if (!ids.includes(this.form.musicGroupOrganizationCourseSettingId)) {
  539. this.$set(this.form, "musicGroupOrganizationCourseSettingId", null);
  540. }
  541. this.charges = res.data.rows;
  542. } catch (error) {}
  543. },
  544. addExtraClass() {
  545. this.eclass.push({});
  546. },
  547. removeExtraClass(index) {
  548. this.eclass[index] = null;
  549. this.eclass = this.eclass.filter((item) => !!item);
  550. },
  551. addCycle() {
  552. this.cycles.push({});
  553. this.collapse.push(this.cycles.length - 1);
  554. this.syncAllMoney();
  555. },
  556. removeCycle(index) {
  557. this.cycles[index] = null;
  558. this.cycles = this.cycles.filter((item) => !!item);
  559. if (this.collapse.includes(index)) {
  560. this.collapse.splice(index, 1);
  561. this.collapse = this.collapse.map((item, _index) =>
  562. _index - 1 >= index ? item-- : item
  563. );
  564. }
  565. this.syncAllMoney();
  566. },
  567. collapseChange(val) {
  568. this.collapse = val;
  569. },
  570. closeNext() {
  571. this.nextVisible = false;
  572. },
  573. getForms() {
  574. const { $refs: refs } = this;
  575. return [
  576. refs.base,
  577. refs.eclass,
  578. refs.cycle,
  579. ...(refs.cycles || []),
  580. refs.other,
  581. refs.payment,
  582. ]
  583. .filter((item) => !!item)
  584. .map((item) => item.$refs.form || item);
  585. },
  586. changeActive(val) {
  587. if (this.$listeners.changeActive) {
  588. this.$listeners.changeActive(val);
  589. }
  590. },
  591. async submit() {
  592. const forms = this.getForms();
  593. const valided = [];
  594. for (const form of forms) {
  595. form.validate((valid) => {
  596. if (valid) {
  597. valided.push(form);
  598. }
  599. });
  600. }
  601. if (this.eclass.length < 1 && this.eclassuser.length < 1) {
  602. return this.$message.error("请至少选择一条加课信息");
  603. }
  604. if (valided.length === forms.length) {
  605. const { leixing, ...rest } = {
  606. ...this.form,
  607. ...this.other,
  608. paymentPattern: this.payment.paymentPattern,
  609. musicGroupPaymentDateRangeList: [
  610. ...this.cycles.map((item) => {
  611. const { paymentDate, paymentValid, ...other } = item;
  612. return {
  613. ...other,
  614. ...getTimes(paymentDate, [
  615. "startPaymentDate",
  616. "deadlinePaymentDate",
  617. ]),
  618. ...getTimes(paymentValid, [
  619. "paymentValidStartDate",
  620. "paymentValidEndDate",
  621. ]),
  622. };
  623. }),
  624. ],
  625. musicGroupPaymentCalenderCourseSettingsList: this.eclass,
  626. musicGroupPaymentCalenderStudentDetails: this.eclassuser,
  627. };
  628. if (this.$refs.cycle) {
  629. const { paymentDate, paymentValid, ...other } = this.cycle;
  630. rest.musicGroupPaymentDateRangeList = [
  631. {
  632. ...other,
  633. ...getTimes(paymentDate, [
  634. "startPaymentDate",
  635. "deadlinePaymentDate",
  636. ]),
  637. ...getTimes(paymentValid, [
  638. "paymentValidStartDate",
  639. "paymentValidEndDate",
  640. ]),
  641. },
  642. ];
  643. }
  644. const data = {
  645. ...rest,
  646. isGiveMusicNetwork: false,
  647. studentIds: this.studentIds,
  648. paymentType:
  649. paymentTypeFormat[
  650. this.paymentType == 0 ? this.paymentType : leixing
  651. ],
  652. musicGroupId: this.musicGroupId,
  653. };
  654. const info = this.viewDetail?.musicGroupPaymentCalenders[0];
  655. if (info && this.viewDetail?.auditDto.paymentType === "ADD_STUDENT") {
  656. data.attribute1 = info.attribute1;
  657. }
  658. let hasCourseFee = false
  659. for (const item of data.musicGroupPaymentCalenderCourseSettingsList) {
  660. if (item.courseCurrentPrice > 0 || item.isStudentOptional == true) {
  661. hasCourseFee = true
  662. break
  663. }
  664. }
  665. // console.log(this.baseInfo?.musicGroup?.courseViewType, this.paymentType, hasCourseFee, this.type)
  666. if (this.baseInfo?.musicGroup?.courseViewType == 2 && this.paymentType == 0 && hasCourseFee && this.type === 'user') {
  667. this.$message.error('报名缴费云教练收费模式课程费用不得大于0且不可选')
  668. return
  669. }
  670. if (!this.rowDetail?.batchNo) {
  671. try {
  672. const res = await musicGroupPaymentCalenderAdd(data);
  673. if (this.$route.query.team_status == "PRE_BUILD_FEE") {
  674. this.$message.success("创建成功");
  675. this.$store.dispatch("delVisitedViews", this.$route);
  676. this.$router.push({
  677. path: "/teamList",
  678. });
  679. }
  680. this.$listeners.close();
  681. this.$listeners.submited(res.data);
  682. // 在这里
  683. } catch (error) {}
  684. } else {
  685. try {
  686. data.batchNo = this.rowDetail.batchNo;
  687. // 缴费类型无法修改,按照之前覆盖
  688. data.paymentType = this.viewDetail.musicGroupPaymentCalenders[0]?.paymentType;
  689. const res = await musicGroupPaymentCalenderDetailBatchUpdate(data);
  690. this.$listeners.close();
  691. this.$listeners.submited(res.data);
  692. if (this.$route.query.type == "teamDraft") {
  693. this.$router.push({
  694. query: merge(this.$route.query, { type: "feeAudit" }),
  695. });
  696. }
  697. } catch (error) {}
  698. }
  699. }
  700. },
  701. },
  702. };
  703. </script>
  704. <style lang="less" scoped>
  705. .dialog-footer {
  706. margin-top: 20px;
  707. display: block;
  708. text-align: right;
  709. }
  710. .alert {
  711. margin-bottom: 10px;
  712. }
  713. .collapse-title {
  714. display: flex;
  715. justify-content: space-between;
  716. align-items: center;
  717. width: 100%;
  718. .el-icon-circle-close {
  719. font-size: 16px;
  720. margin-right: 10px;
  721. }
  722. }
  723. /deep/ .el-collapse-item__wrap {
  724. padding-top: 20px;
  725. }
  726. </style>