|
|
@@ -21,7 +21,7 @@ |
|
|
|
finished-text="没有更多了" |
|
|
|
@load="getList"> |
|
|
|
<van-swipe-cell v-for="(item,index) in applicationList" :key="index"> |
|
|
|
<van-cell :title="item.payer" center :to="{name:'approvalDetail', query: {id:item.id}}"> |
|
|
|
<van-cell :title="item.payerAccount" center :to="{name:'approvalDetail', query: {id:item.id}}"> |
|
|
|
<template #icon> |
|
|
|
<van-icon name="../../../../../static/images/onlineHome/icon_yn1.png" size="30" color="#FF4646" style="margin-right: 10px;" /> |
|
|
|
</template> |
|
|
@@ -30,6 +30,11 @@ |
|
|
|
</template> |
|
|
|
<template #default> |
|
|
|
<p style="width: 80px;display: inline-block">{{item.auditStatus}}</p> |
|
|
|
<p v-if="item.auditStatus === '通过' && item.paymentState === '待支付'" style="color: #606266;width: 80px;display: inline-block">{{item.paymentState}}</p> |
|
|
|
<p v-else-if="item.paymentState === '银行受理'" style="width: 80px;display: inline-block">{{item.paymentState}}</p> |
|
|
|
<p v-else-if="(item.paymentState === '支付失败' || item.paymentState === '部分失败') && item.downId == null" style="color: #F56C6C;width: 80px;display: inline-block">{{item.paymentState}}-未重新申请</p> |
|
|
|
<p v-else-if="(item.paymentState === '支付失败' || item.paymentState === '部分失败') && item.downId != null" style="color: #E6A23C;width: 80px;display: inline-block">{{item.paymentState}}-已重新申请</p> |
|
|
|
<p v-else-if="item.paymentState === '支付成功'" style="color: #67C23A;width: 80px;display: inline-block">{{item.paymentState}}</p> |
|
|
|
</template> |
|
|
|
</van-cell> |
|
|
|
<template #right> |
|
|
@@ -46,6 +51,12 @@ |
|
|
|
<van-col> |
|
|
|
<van-button v-if="item.auditStatus=='待审'" square text="撤回" type="danger" @click="cancelApply(item)" class="delete-button" /> |
|
|
|
</van-col> |
|
|
|
<van-col> |
|
|
|
<van-button v-if="item.paymentState === '银行受理'" square text="核实结果" type="danger" @click="transactionStatusQuery(item.id)" class="delete-button" /> |
|
|
|
</van-col> |
|
|
|
<van-col> |
|
|
|
<van-button v-if="(item.paymentState === '支付失败' || item.paymentState === '部分失败') && item.downId == null" square text="重新申请" type="danger" @click="reapply(item.id)" class="delete-button" /> |
|
|
|
</van-col> |
|
|
|
</van-row> |
|
|
|
</template> |
|
|
|
</van-swipe-cell> |
|
|
@@ -54,13 +65,14 @@ |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
import { listTransfer , customSubmit , delTransfer , updateTYinnongTransferFoStatus } from "@/api/onlineHome/bankAgriculture/paymentApproval"; |
|
|
|
import { listTransfer , customSubmit , delTransfer , updateTYinnongTransferFoStatus,transactionStatusQuery,reapply } from "@/api/onlineHome/bankAgriculture/paymentApproval"; |
|
|
|
export default { |
|
|
|
name: "approvalList", |
|
|
|
data() { |
|
|
|
return { |
|
|
|
applicationList:[], |
|
|
|
auditStatusOptions:[], |
|
|
|
paymentStateOptions:[], |
|
|
|
loading: false, |
|
|
|
finished: false, |
|
|
|
queryParams:{ |
|
|
@@ -75,6 +87,9 @@ export default { |
|
|
|
this.getDicts("audit_status").then((response) => { |
|
|
|
this.auditStatusOptions = response.data; |
|
|
|
}); |
|
|
|
this.getDicts("payment_state").then((response) => { |
|
|
|
this.paymentStateOptions = response.data; |
|
|
|
}); |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
//金额千分符 会在整数后添加两个0 |
|
|
@@ -97,6 +112,7 @@ export default { |
|
|
|
console.log(response) |
|
|
|
for (var i = 0; i < response.rows.length; i++) { |
|
|
|
response.rows[i].auditStatus = this.selectDictLabel(this.auditStatusOptions, response.rows[i].auditStatus); |
|
|
|
response.rows[i].paymentState = this.selectDictLabel(this.paymentStateOptions, response.rows[i].paymentState); |
|
|
|
this.applicationList.push(response.rows[i]); |
|
|
|
} |
|
|
|
console.log(this.applicationList.length >= response.total) |
|
|
@@ -110,6 +126,38 @@ export default { |
|
|
|
}); |
|
|
|
}, 1000); |
|
|
|
}, |
|
|
|
reapply(id){ |
|
|
|
this.$dialog.confirm({ |
|
|
|
message: '您确认将单据中支付失败的记录重新申请?请先确保已根据详情中【交易结果描述】修改准确后,再执行此操作!', |
|
|
|
}) |
|
|
|
.then(() => { |
|
|
|
// on confirm |
|
|
|
reapply(id).then(res => { |
|
|
|
if(res.code = 200){ |
|
|
|
this.$toast.success('重新申请成功!'); |
|
|
|
} |
|
|
|
}); |
|
|
|
}) |
|
|
|
.catch(() => { |
|
|
|
// on cancel |
|
|
|
}); |
|
|
|
}, |
|
|
|
transactionStatusQuery(id){ |
|
|
|
this.$dialog.confirm({ |
|
|
|
message: '您确认查询单据的转账结果?', |
|
|
|
}) |
|
|
|
.then(() => { |
|
|
|
// on confirm |
|
|
|
transactionStatusQuery(id).then(res => { |
|
|
|
if(res.code = 200){ |
|
|
|
this.$toast.success('查询成功'); |
|
|
|
} |
|
|
|
}); |
|
|
|
}) |
|
|
|
.catch(() => { |
|
|
|
// on cancel |
|
|
|
}); |
|
|
|
}, |
|
|
|
deleteList(id,index){ |
|
|
|
this.$dialog.confirm({ |
|
|
|
message: '您确认删除草稿?', |
|
|
|