|
@@ -292,7 +292,7 @@
|
|
|
<el-form-item label="所属乐团"
|
|
|
prop="musicGroupId">
|
|
|
<el-select v-model.trim="maskForm1.musicGroupId"
|
|
|
- :disabled='!isNew'
|
|
|
+ :disabled='!isNew1 || maskMusicList1.length <= 0'
|
|
|
clearable
|
|
|
filterable>
|
|
|
<el-option v-for='(item,index) in maskMusicList1'
|
|
@@ -528,30 +528,32 @@ export default {
|
|
|
this.title1 = '新增个人收费'
|
|
|
},
|
|
|
lookVisible (row) {
|
|
|
- if (row.userId) {
|
|
|
+ let maskForm = null
|
|
|
+ if(row.userId) {
|
|
|
+ maskForm = this.maskForm1
|
|
|
this.isNew1 = false;
|
|
|
this.zeroVisible1 = true;
|
|
|
this.title1 = '查看个人收费'
|
|
|
- this.activeRow = row
|
|
|
- this.maskForm1.code = vaildStudentUrl() + `/#/sporadicPay?id=${this.activeRow.id}&userId=${this.activeRow.userId}`
|
|
|
- this.maskForm1.type = parseInt(row.chargeType)
|
|
|
- this.maskForm1.desc = row.detail
|
|
|
- this.maskForm1.title = row.title
|
|
|
- this.maskForm1.money = row.amount
|
|
|
- this.maskForm1.studentId = row.userId
|
|
|
- this.maskForm1.studentName = row.userName
|
|
|
} else {
|
|
|
+ maskForm = this.maskForm
|
|
|
this.isNew = false;
|
|
|
this.zeroVisible = true;
|
|
|
this.title = '查看公用收费'
|
|
|
- this.activeRow = row
|
|
|
- this.maskForm.code = vaildStudentUrl() + `/#/sporadicLogin?id=${this.activeRow.id}`
|
|
|
- this.maskForm.type = parseInt(row.chargeType)
|
|
|
- this.maskForm.desc = row.detail
|
|
|
- this.maskForm.title = row.title
|
|
|
- this.maskForm.organId = row.organId
|
|
|
- this.maskForm.money = row.amount
|
|
|
- this.maskForm.subMoney = row.discountAmount
|
|
|
+ }
|
|
|
+
|
|
|
+ maskForm.code = vaildStudentUrl() + `/#/sporadicLogin?id=${this.activeRow.id}`
|
|
|
+ maskForm.type = parseInt(row.chargeType)
|
|
|
+ maskForm.desc = row.detail
|
|
|
+ maskForm.title = row.title
|
|
|
+ maskForm.organId = row.organId
|
|
|
+ maskForm.money = row.amount
|
|
|
+ maskForm.subMoney = row.discountAmount
|
|
|
+ maskForm.musicGroupId = row.musicGroupId ? row.musicGroupId : null
|
|
|
+
|
|
|
+ if(row.userId) {
|
|
|
+
|
|
|
+ } else {
|
|
|
+ this.onMusicGroupChange()
|
|
|
}
|
|
|
},
|
|
|
onCreateQRCode () { // 生成报名二维码
|
|
@@ -561,31 +563,13 @@ export default {
|
|
|
} else {
|
|
|
this.qrCodeUrl = vaildStudentUrl() + `/#/sporadicLogin?id=${this.activeRow.id}`
|
|
|
}
|
|
|
- // setTimeout(() => {
|
|
|
- // if (this.qrcodes) {
|
|
|
- // this.qrcodes = false
|
|
|
- // this.qrcode = new QRCode('qrcode', {
|
|
|
- // width: 250,
|
|
|
- // height: 250,
|
|
|
- // colorDark: '#000000',
|
|
|
- // colorLight: '#ffffff',
|
|
|
- // correctLevel: QRCode.CorrectLevel.H
|
|
|
- // })
|
|
|
- // }
|
|
|
- // this.qrcode.clear();
|
|
|
- // console.log(this.activeRow.userId, +new Date())
|
|
|
- // if (this.activeRow.userId) {
|
|
|
- // this.qrcode.makeCode(vaildStudentUrl() + `/#/sporadicPay?id=${this.activeRow.id}&userId=${this.activeRow.userId}`)
|
|
|
- // } else {
|
|
|
- // this.qrcode.makeCode(vaildStudentUrl() + `/#/sporadicLogin?id=${this.activeRow.id}`)
|
|
|
- // }
|
|
|
- // }, 500)
|
|
|
},
|
|
|
onMusicGroupChange() {
|
|
|
let maskForm = this.maskForm
|
|
|
if(!maskForm.organId) {
|
|
|
return
|
|
|
}
|
|
|
+ maskForm.musicGroupId = null // 重置可能已经选中的乐团
|
|
|
queryOrganMusicInfos({ organId: maskForm.organId }).then(res => {
|
|
|
console.log(res)
|
|
|
if(res.code == 200) {
|
|
@@ -627,6 +611,7 @@ export default {
|
|
|
chargeType: maskForm1.type,
|
|
|
detail: maskForm1.desc,
|
|
|
title: maskForm1.title,
|
|
|
+ musicGroupId: this.maskForm1.musicGroupId,
|
|
|
userId: maskForm1.studentId,
|
|
|
amount: maskForm1.money
|
|
|
}
|
|
@@ -656,9 +641,10 @@ export default {
|
|
|
if (res.code == 200) {
|
|
|
if (res.data) {
|
|
|
this.maskForm1.studentName = res.data.name
|
|
|
-
|
|
|
queryUserMusicInfos({ userId: studentId }).then(studentInfo => {
|
|
|
- console.log(studentInfo)
|
|
|
+ if(studentInfo.code == 200) {
|
|
|
+ this.maskMusicList1 = studentInfo.data
|
|
|
+ }
|
|
|
})
|
|
|
} else {
|
|
|
this.maskForm1.studentName = null
|