Commit 02b61df6 by Joey

fix(@gms/gms-plugin-billexpand): 工会提交、取回按钮提示信息调整

parent d7fc7c1b
...@@ -9,8 +9,18 @@ export default { ...@@ -9,8 +9,18 @@ export default {
data: bill.getBuillData(), data: bill.getBuillData(),
detailData: [], detailData: [],
} }
).then(() => { ).then((res) => {
GMS.$hideContainer.$Message.success('操作成功!') if (res.data && res.data.code == 0) {
GMS.$hideContainer.$Message.success('操作成功!')
}
else {
const { data } = res
data.message && GMS.$hideContainer.$Message.error({
content: errorMessageUtil.submitAction.getErrorMessage(data.message),
duration: 3
});
}
bill.setControlsSate(param["_control_name_"], "loading", false)
bill.setControlsSate(param["_control_name_"], "enable", true) bill.setControlsSate(param["_control_name_"], "enable", true)
bill.setControlsSate(param["_control_name_"], "loading", false) bill.setControlsSate(param["_control_name_"], "loading", false)
}).catch(() => { }).catch(() => {
......
...@@ -5,7 +5,6 @@ import { showSignModal, saveBill } from "../util"; ...@@ -5,7 +5,6 @@ import { showSignModal, saveBill } from "../util";
export default { export default {
execute: function (bill, param) { execute: function (bill, param) {
bill = bill.dom || bill bill = bill.dom || bill
console.log(param, bill)
if (param && param.param && param.param.budgetcontrol) { if (param && param.param && param.param.budgetcontrol) {
let res = this.getBudgetControl(bill, true, param); let res = this.getBudgetControl(bill, true, param);
res.then((data) => { res.then((data) => {
...@@ -83,8 +82,6 @@ export default { ...@@ -83,8 +82,6 @@ export default {
} }
let url = `/rbc/bill/action/zgh/change/work/${param.define}/bill.Basic.submit`; let url = `/rbc/bill/action/zgh/change/work/${param.define}/bill.Basic.submit`;
window.GMS.$http.post(url, postData).then((response) => { window.GMS.$http.post(url, postData).then((response) => {
console.log('------------------------------------')
console.log(response)
const data = response.data const data = response.data
let code = 200 let code = 200
if (data.code != 0) { if (data.code != 0) {
...@@ -92,7 +89,6 @@ export default { ...@@ -92,7 +89,6 @@ export default {
} }
bill.setControlsSate(param["_control_name_"], 'enable', true) bill.setControlsSate(param["_control_name_"], 'enable', true)
if (code === 200) { if (code === 200) {
const id = data.content.billData.id;
minusIndex();//上张下张用 minusIndex();//上张下张用
GMS.$hideContainer.$Message.success('提交成功'); GMS.$hideContainer.$Message.success('提交成功');
let curTagId = window.nros.context.getCurrTag(); let curTagId = window.nros.context.getCurrTag();
...@@ -108,6 +104,7 @@ export default { ...@@ -108,6 +104,7 @@ export default {
GMS.$hideContainer.$Message.error("暂存单据异常请联系管理员"); GMS.$hideContainer.$Message.error("暂存单据异常请联系管理员");
} }
}).catch((err) => { }).catch((err) => {
console.error(err)
GMS.$hideContainer.$Message.error('工作流配置错误,请联系管理员'); GMS.$hideContainer.$Message.error('工作流配置错误,请联系管理员');
bill.setControlsSate(param["_control_name_"],"loading",false) bill.setControlsSate(param["_control_name_"],"loading",false)
bill.setControlsSate(param["_control_name_"], "enable", true) bill.setControlsSate(param["_control_name_"], "enable", true)
......
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