Commit f128740e authored by 谢子梦's avatar 谢子梦

stage:代发账户线下充值服务费限制

parent c184e342
......@@ -123,3 +123,10 @@ export function getOfflineRechargeInfo(rechargeType, cardNo) {
}
})
}
// 判断代发账户是否可以进行线下充值
export function isEDMAccountOfflineserviceChargeAPI(cardNo) {
return request({
url: `/business/company/payChannelParams/recharge/query?cardNo=${cardNo}`,
method: 'get'
})
}
......@@ -14,15 +14,18 @@
<el-col :span="12">
<div class="ownRechargeMain">
<img class="ownRechargeImage" src="@/assets/images/zfb.png" alt="">
<div class="ownRechargeButton"
@click="rechargeCoursePanelDialog = false; aliQRCodeRechargeOpen = true">直属账户充值</div>
<el-button class="ownRechargeButton"
@click="rechargeCoursePanelDialog = false; aliQRCodeRechargeOpen = true">直属账户充值</el-button>
</div>
</el-col>
<el-col :span="12">
<div class="ownRechargeMain">
<img class="ownRechargeImage" src="@/assets/images/xianxia.png" alt="">
<div class="ownRechargeButton" @click="offlineRecharge">线下充值</div>
<el-button class="ownRechargeButton" :disabled="!isOfflineRecharge"
@click="offlineRecharge">线下充值
</el-button>
</div>
<div v-if="!isOfflineRecharge" class="functionDisabled">(该功能暂不可用)</div>
</el-col>
</el-row>
</el-dialog>
......@@ -151,7 +154,7 @@
<script>
import { addAccRecharge } from '@/api/business/accRecharge.js'
import QrCodeComponent from '@/components/QrCode.vue'
import { getOfflineRechargeInfo, setOfflineRechargeInfo } from '@/api/business/accInfo.js'
import { getOfflineRechargeInfo, setOfflineRechargeInfo, isEDMAccountOfflineserviceChargeAPI } from '@/api/business/accInfo.js'
export default {
components: { QrCodeComponent },
data() {
......@@ -222,7 +225,8 @@ export default {
payerAccName: [
{ required: true, message: '请输入付款账户名称', trigger: 'blur' }
]
}
},
isOfflineRecharge: false
}
},
methods: {
......@@ -302,9 +306,21 @@ export default {
},
/** 父组件调用子组件 */
enableRecharge(val) {
this.aliQRCodeRechargeForm.payeeAccNo = val.payAccNo
this.aliQRCodeRechargeForm.bindType = val.bindType
this.rechargeCoursePanelDialog = true
// console.log('当前卡信息', val);
isEDMAccountOfflineserviceChargeAPI(val.payAccNo).then(res => {
if (res.code == 200) {
if (res.data && res.data.proxy_recharge_cmb) {
this.isOfflineRecharge = res.data.proxy_recharge_cmb.isNormal
} else {
this.isOfflineRecharge = false
}
}
}).finally(() => {
this.aliQRCodeRechargeForm.payeeAccNo = val.payAccNo
this.aliQRCodeRechargeForm.bindType = val.bindType
this.rechargeCoursePanelDialog = true
})
},
}
}
......@@ -318,6 +334,13 @@ export default {
line-height: 28px;
height: 28px;
font-size: 12px;
padding: 0;
display: inline-block;
}
.functionDisabled {
color: #f56c6c;
font-size: 12px;
text-align: center;
}
</style>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment