Commit 25ebde49 by wangguangchao

待复核交易优化

parent d2607a36
......@@ -139,6 +139,9 @@ export default {
}
it["IDX"] = i;
it['INR'] = items[0];
if(it['INR'].length < 8){
it['INR'] = items[1];
}
it.srcStr = d;
arr.push(it);
}
......
......@@ -72,5 +72,80 @@ export default {
this.$notify.error({ title: "错误", message: result.respMsg });
}
},
async handlePass(data) {
debugger;
this.$confirm('您确定复核该笔交易?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(
async ()=>{
let idxInt = parseInt(data.idx);
const selIds = [idxInt+1]; //rowno选中行
const selDst = "trncorco.trnstm" //列表对应后台模型中的stream
let params = { selDst: selDst, selIds: selIds };
this.declareParams.trnName = "trnrel";
console.log(this);
this.model.pageId = data.pageId;
let rtnmsg = await this.executeRule("relrow", params)
if (rtnmsg.respCode == SUCCESS) {
debugger;
let errorMsg = "";
let fieldErrorsFlag = (JSON.stringify(rtnmsg.fieldErrors) == "{}");
if(!fieldErrorsFlag){
let errorMsgkey = "";
let errorMsgVal = "";
for (const key in rtnmsg.fieldErrors) {
errorMsgkey = key;
errorMsgVal = rtnmsg.fieldErrors[key];
}
errorMsg = errorMsgkey+':'+errorMsgVal;
this.$notify.error({title: '错误',message: '复核失败!错误信息['+errorMsg+']'});
}else{
this.$notify({
title: '成功',
message: '复核成功',
type: 'success'
});
debugger;
// const that = this.root;
// that.executeRule("searow").then(res => {
// //TODO 处理数据逻辑
// that.$refs.inftrnps.stmData.data = res.data.trncorco_trnstm.rows;
// this.model.trncorco.trnstm = res.data.trncorco_trnstm;
// })
this.$router.history.push("/taskList", () => {
this.$store.commit("setTaskListTabVal", 'trnrel')
})
}
}
else {
let errorMsg = "";
let fieldErrorsFlag = (JSON.stringify(rtnmsg.fieldErrors) == "{}");
if(!fieldErrorsFlag){
let errorMsgkey = "";
let errorMsgVal = "";
for (const key in rtnmsg.fieldErrors) {
errorMsgkey = key;
errorMsgVal = rtnmsg.fieldErrors[key];
}
errorMsg = errorMsgkey+':'+errorMsgVal;
}else if(rtnmsg.respMsg){
errorMsg = rtnmsg.respMsg;
}
this.$notify.error({title: '错误',message: '复核失败!错误信息['+errorMsg+']'});
}
}
)
},
},
};
......@@ -86,8 +86,19 @@ export default {
this.$notify.error({ title: '错误', message: '服务请求失败!' });
}
},
async onRelrow(idx,row) {
async onHandle(idx,row) {
let viewurl = "/review/ditopn";
let pageId = this.model.pageId;
debugger;
this.$router.push({path:viewurl,query:{routeParams: {process: "1", commitFlag: "1"},trn:row['INR'],idx:idx,pageId:pageId}});
},
async onRelrow(idx) {
this.$confirm('您确定复核该笔交易?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
......@@ -97,7 +108,10 @@ export default {
const selDst = "trncorco.trnstm" //列表对应后台模型中的stream
let params = { selDst: selDst, selIds: selIds };
debugger;
let initRtnmsg = await this.init();
if(initRtnmsg.respCode == SUCCESS){
let rtnmsg = await this.executeRule("relrow", params)
if (rtnmsg.respCode == SUCCESS) {
debugger;
......@@ -143,10 +157,14 @@ export default {
}
this.$notify.error({title: '错误',message: '复核失败!错误信息['+errorMsg+']'});
}
}
})
},
sleep(ms) {
return new Promise((resolve, reject) => {
setTimeout(() => {
......
......@@ -401,28 +401,37 @@
fixed="right"
prop="display"
label="操作"
width="200px"
width="230px"
>
<template slot-scope="scope">
<!-- <a :href="`/#/display/${scope.row['10'].toLowerCase()}?trn=${scope.row['1']}`" target="_blank" >显示快照</a>-->
<!-- <a href="javascript:void(0)" @click="display(scope.$index, scope.row)"
>显示快照</a
> -->
<c-button
<!-- <c-button
style="margin-left: 0"
size="small"
type="primary"
@click="display(scope.$index, scope.row)"
>
快照
</c-button>
</c-button> -->
<c-button
style="margin-left: 0"
size="small"
type="primary"
@click="onRelrow(scope.$index,scope.row)"
@click="onHandle(scope.$index,scope.row)"
>
处理
</c-button>
<c-button
style="margin-left: 0"
size="small"
type="primary"
@click="onRelrow(scope.$index)"
>
复核
......@@ -433,7 +442,7 @@
type="primary"
>
退回
流程记录
</c-button>
......
......@@ -340,12 +340,15 @@ export default {
}
},
async handlePass() {
console.log(this.remark)
let data = {}
if (this.process == '1' || this.process == '2' || this.process == '4') {
// 复核通过需要传递参数:复核意见和tips
// 通过 - 清空tips
data = {
pageId: this.$route.query.pageId,
idx: this.$route.query.idx,
remark: this.remark,
tips: [] //this.$store.state.Status.highlights
}
......
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