Commit 94007ba7 by 潘际乾

交易的repair处理

parent 232cf12b
......@@ -106,5 +106,8 @@ export default {
async handlePass(data) {
this.$store.state.Transaction.operateFuns[data.operateId]["pass"]()
},
async handleRefuse(data) {
this.$store.state.Transaction.operateFuns[data.operateId]["refuse"]()
},
},
};
......@@ -197,6 +197,7 @@ export default {
}
}
}
this.$el.querySelectorAll('input').forEach(input => input.blur())
})
},
/**
......
......@@ -97,7 +97,7 @@ export default {
const operateId = await this.$store.dispatch('Transaction/setOperateFuns', {
pass: this.onRelrow.bind(this, idx),
refuse: () => { alert("功能开发中") }
refuse: this.onReprow.bind(this, idx),
});
this.$router.push({ path: viewurl, query: { trn: row['INR'], operateId: operateId } });
......@@ -227,15 +227,61 @@ export default {
this.$notify.error({ title: '错误', message: '服务请求失败!' });
}
},
async onReprow() {
let rtnmsg = await this.executeRule("reprow")
if (rtnmsg.respCode == SUCCESS) {
//TODO 处理数据逻辑
async onReprow(idx) {
this.$confirm('您确定退回该笔交易?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(async () => {
const selIds = [idx + 1]; //rowno选中行
const selDst = "trncorco.trnstm" //列表对应后台模型中的stream
}
else {
this.$notify.error({ title: '错误', message: '服务请求失败!' });
}
let params = { selDst: selDst, selIds: selIds };
let rtnmsg = await this.executeRule("reprow", params)
if (rtnmsg.respCode == SUCCESS) {
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'
});
this.$store.dispatch("TagsView/delView", this.$route)
this.$router.history.push("/taskList", () => {
this.$store.commit("setTaskListTabVal", 'trnrel');
this.handleSearch()
});
}
}
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 = errorMsg + errorMsgkey + ':' + errorMsgVal + ";";
}
} else if (rtnmsg.respMsg) {
errorMsg = rtnmsg.respMsg;
}
this.$notify.error({ title: '错误', message: '退回失败!错误信息[' + errorMsg + ']' });
}
})
},
async onRejrow() {
console.log(this.getSelectedData())
......
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