|
@@ -65,7 +65,6 @@
|
|
|
<template slot-scope="scope">
|
|
|
<div>
|
|
|
<el-button type="text"
|
|
|
- v-if="scope.row.paymentStatus != 0"
|
|
|
@click="lookDetail(scope.row)"
|
|
|
v-permission="'/strudentPayInfo'">查看</el-button>
|
|
|
<el-button type="text"
|
|
@@ -162,6 +161,20 @@
|
|
|
v-if="codeUrl">{{ codeUrl }}</p>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
+ <el-dialog title="学员选择"
|
|
|
+ :visible.sync="chioseStudentVisible"
|
|
|
+ width='800px'>
|
|
|
+ <setStudentFee @chioseStudent='chioseStudent'
|
|
|
+ ref='setStudentFee'
|
|
|
+ :clearTale="clearStduent"></setStudentFee>
|
|
|
+ <div slot="footer"
|
|
|
+ class="dialog-footer">
|
|
|
+ <el-button @click="chioseStudentVisible = false">取 消</el-button>
|
|
|
+ <el-button type="primary"
|
|
|
+ @click="submitNewPay">确 定</el-button>
|
|
|
+
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
@@ -172,8 +185,9 @@ import load from "@/utils/loading";
|
|
|
import QRCode from 'qrcodejs2'
|
|
|
import { vaildStudentUrl } from '@/utils/validate'
|
|
|
import { addMusicGroupPaymentCalender, getMusicGroupPaymentCalender, resetMusicGroupPaymentCalender, delMusicGroupPaymentCalender } from "@/api/buildTeam";
|
|
|
+import setStudentFee from './studentPayBase'
|
|
|
export default {
|
|
|
- components: { pagination },
|
|
|
+ components: { pagination, setStudentFee },
|
|
|
data () {
|
|
|
return {
|
|
|
searchForm: {
|
|
@@ -208,6 +222,9 @@ export default {
|
|
|
qrcode: null,
|
|
|
codeUrl: null,
|
|
|
bigin: this.beginDate(),
|
|
|
+ chioseStudentVisible: false,
|
|
|
+ chioseStudentList: [],
|
|
|
+ clearStduent: true
|
|
|
};
|
|
|
},
|
|
|
//生命周期 - 创建完成(可以访问当前this实例)
|
|
@@ -218,7 +235,6 @@ export default {
|
|
|
|
|
|
this.init();
|
|
|
|
|
|
-
|
|
|
},
|
|
|
activated () {
|
|
|
this.init();
|
|
@@ -253,6 +269,9 @@ export default {
|
|
|
this.codeUrl = vaildStudentUrl() + '/#/SporadicLogin?type=renew&musicGroupId=' + id
|
|
|
}, 500)
|
|
|
},
|
|
|
+ chioseStudent (val) {
|
|
|
+ this.chioseStudentList = val;
|
|
|
+ },
|
|
|
newPay () {
|
|
|
this.diTitle = '新增缴费'
|
|
|
this.isNew = true
|
|
@@ -301,22 +320,40 @@ export default {
|
|
|
},
|
|
|
*
|
|
|
*/
|
|
|
- let obj = {}
|
|
|
- obj.musicGroupId = this.$route.query.id
|
|
|
- obj.startPaymentDate = this.payForm.startPaymentDate + ' 00:00:00'
|
|
|
- obj.deadlinePaymentDate = this.payForm.deadlinePaymentDate + ' 23:59:59'
|
|
|
- obj.type = this.payForm.type
|
|
|
- obj.memo = this.payForm.memo
|
|
|
- addMusicGroupPaymentCalender(obj).then(res => {
|
|
|
- if (res.code == 200) {
|
|
|
- this.$message.success('恭喜你创建成功')
|
|
|
- this.payVisible = false;
|
|
|
- this.getList()
|
|
|
- }
|
|
|
- })
|
|
|
+ this.chioseStudentVisible = true
|
|
|
+ return
|
|
|
+
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
+ submitNewPay () {
|
|
|
+ if (this.chioseStudentList.length < 1) {
|
|
|
+ this.$message.error('请至少选择一名学员')
|
|
|
+ return
|
|
|
+ }
|
|
|
+
|
|
|
+ let obj = {}
|
|
|
+ obj.studentIds = this.chioseStudentList.map(stu => {
|
|
|
+ return stu.userId
|
|
|
+ }).join(',')
|
|
|
+ console.log(obj)
|
|
|
+ obj.musicGroupId = this.$route.query.id
|
|
|
+ obj.startPaymentDate = this.payForm.startPaymentDate + ' 00:00:00'
|
|
|
+ obj.deadlinePaymentDate = this.payForm.deadlinePaymentDate + ' 23:59:59'
|
|
|
+ obj.type = this.payForm.type
|
|
|
+ obj.memo = this.payForm.memo
|
|
|
+ addMusicGroupPaymentCalender(obj).then(res => {
|
|
|
+ if (res.code == 200) {
|
|
|
+ this.$message.success('恭喜你创建成功')
|
|
|
+ this.$refs.setStudentFee.clearTable()
|
|
|
+ this.payVisible = false;
|
|
|
+ this.chioseStudentVisible = false;
|
|
|
+ this.getList()
|
|
|
+ }
|
|
|
+ })
|
|
|
+
|
|
|
+
|
|
|
+ },
|
|
|
resetPayDate () {
|
|
|
resetMusicGroupPaymentCalender({ id: this.activeRow.id, startTime: this.payForm.startPaymentDate }).then(res => {
|
|
|
if (res.code == 200) {
|