Commit 7790fddf by chenwenbin

// 表外记账,费用账务,会计分录前后端联调

parent 2c94e7bf
...@@ -177,7 +177,8 @@ export default { ...@@ -177,7 +177,8 @@ export default {
return { return {
root: this, root: this,
activeNames: ["ovwp"], activeNames: ["ovwp"],
reflashSetpan: this.reloadSetpan // reflashSetpan: this.reloadSetpan,
// setSetgllAccts: this.getSetgllAccts
}; };
}, },
// 里面包含了Default、Check等的公共处理 // 里面包含了Default、Check等的公共处理
...@@ -297,9 +298,6 @@ export default { ...@@ -297,9 +298,6 @@ export default {
this.model.pageId = 'CtxCache-4079be82-bb5e-4ced-835e-0f20d3268ec2' this.model.pageId = 'CtxCache-4079be82-bb5e-4ced-835e-0f20d3268ec2'
this.model.setmod.dspflg = 'CG' this.model.setmod.dspflg = 'CG'
}, },
reloadSetpan() {
this.calcPayDetailPro();
}
}, },
created () { created () {
this.initModelData() this.initModelData()
......
...@@ -160,7 +160,7 @@ export default { ...@@ -160,7 +160,7 @@ export default {
async processSetpan() { async processSetpan() {
//组数据,发post请求 //组数据,发post请求
let loading = this.loading('正在请求试算费用'); let loading = this.loading('正在请求试算费用');
let rulePath = '/service/setmod/calcSettleDetail'; let rulePath = '/service/gid/setmod/calcSettleDetail';
let setfegRequest = this.buildSetfegRequest(); let setfegRequest = this.buildSetfegRequest();
let rtnmsg = await Api.post(rulePath, setfegRequest); let rtnmsg = await Api.post(rulePath, setfegRequest);
if (rtnmsg.respCode == SUCCESS) { if (rtnmsg.respCode == SUCCESS) {
...@@ -170,7 +170,7 @@ export default { ...@@ -170,7 +170,7 @@ export default {
this.model.setmod.docamt = rtnmsg.data.docamt; this.model.setmod.docamt = rtnmsg.data.docamt;
if (this.model.setmod.setfeg.setfel.length > 0) { if (this.model.setmod.setfeg.setfel.length > 0) {
loading = this.loading('正在请求试算账务'); loading = this.loading('正在请求试算账务');
rulePath = '/service/setmod/calcPayDetail'; rulePath = '/service/gid/setmod/calcPayDetail';
let setglgRequest = this.buildSetglgRequest(); let setglgRequest = this.buildSetglgRequest();
rtnmsg = await Api.post(rulePath, setglgRequest); rtnmsg = await Api.post(rulePath, setglgRequest);
if (rtnmsg.respCode == SUCCESS) { if (rtnmsg.respCode == SUCCESS) {
...@@ -181,14 +181,28 @@ export default { ...@@ -181,14 +181,28 @@ export default {
loading.close() loading.close()
}, },
async calcPayDetail() { async calcPayDetail() {
debugger
let loading = this.loading('正在请求试算账务'); let loading = this.loading('正在请求试算账务');
let rulePath = '/service/setmod/calcPayDetail'; let rulePath = '/service/gid/setmod/calcPayDetail';
let setglgRequest = this.buildSetglgRequest(); let setglgRequest = this.buildSetglgRequest();
let rtnmsg = await Api.post(rulePath, setglgRequest); let rtnmsg = await Api.post(rulePath, setglgRequest);
if (rtnmsg.respCode == SUCCESS) { if (rtnmsg.respCode == SUCCESS) {
this.model.setmod.setglg = rtnmsg.data.setglg; this.model.setmod.setglg = rtnmsg.data.setglg;
} }
loading.close() loading.close()
},
async setgllAccts(index, setgll) {
this.model.setmod.setglg.setgll = setgll;
let rulePath = '/service/gid/setmod/setgll/' + index + '/accts';
let setglgRequest = this.buildSetglgRequest();
setglgRequest.setglg.setgll = setgll;
let rtnmsg = await Api.post(rulePath, setglgRequest);
if (rtnmsg.respCode == SUCCESS) {
this.model.setmod = rtnmsg.data;
}
} }
} }
...@@ -372,7 +372,9 @@ export default { ...@@ -372,7 +372,9 @@ export default {
}, },
computed: { computed: {
formData() { formData() {
return this.model.setmod.setfeg.setfel[this.idx] let formDataTmp = this.model.setmod.setfeg.setfel[this.idx];
formDataTmp.fecp1.taxrat = formDataTmp.fecp1.taxrat || '';
return formDataTmp
} }
}, },
methods: { methods: {
......
...@@ -537,7 +537,7 @@ ...@@ -537,7 +537,7 @@
> >
<c-select v-model="scope.row.act"> <c-select v-model="scope.row.act">
<el-option <el-option
v-for="item in scope.act" v-for="item in scope.row.acts"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
...@@ -1344,11 +1344,9 @@ ...@@ -1344,11 +1344,9 @@
// import Event from "~/model/Ditopn/Event"; // import Event from "~/model/Ditopn/Event";
import commonProcess from "~/mixin/commonProcess"; import commonProcess from "~/mixin/commonProcess";
import SetpanDialog from "./dialog.vue"; import SetpanDialog from "./dialog.vue";
import Utils from "~/utils/index";
import SetfegRequest from '../model/SetfegRequest.js';
export default { export default {
inject: ["root", 'reflashSetpan'], inject: ["root"],
components: { SetpanDialog }, components: { SetpanDialog },
props: ["model", "codes"], props: ["model", "codes"],
mixins: [commonProcess], mixins: [commonProcess],
...@@ -1413,7 +1411,7 @@ export default { ...@@ -1413,7 +1411,7 @@ export default {
addRowSetfol() { addRowSetfol() {
let newRow = { ...this.newdialog }; let newRow = { ...this.newdialog };
this.model.setmod.setfog.setfol.splice(0, 0, newRow); this.model.setmod.setfog.setfol.splice(0, 0, newRow);
this.defaultFunction(); // this.defaultFunction();
}, },
removeRowSetfol() { removeRowSetfol() {
this.model.setmod.setfog.setfol.shift(); this.model.setmod.setfog.setfol.shift();
...@@ -1433,18 +1431,18 @@ export default { ...@@ -1433,18 +1431,18 @@ export default {
this.model.setmod.setfeg.setfel.shift(); this.model.setmod.setfeg.setfel.shift();
this.defaultFunction(); this.defaultFunction();
}, },
detail1(index, row) {s detail1(index, row) {
this.index = index; this.index = index;
this.dialogVisible = true; this.dialogVisible = true;
this.dialog = row; this.dialog = row;
}, },
dispDefault(index) { dispDefault(index) {
let vm = this; let vm = this;
// Utils.copyValueFromVO(vm.model, res.data); vm.root.calcPayDetail();
vm.reflashSetpan();
}, },
// 第二个表格 // 第二个表格
detail2(index, row) { detail2(index, row) {
const that = this; const that = this;
that.index = index; that.index = index;
that.$refs.setpanDialog.visiable = true; that.$refs.setpanDialog.visiable = true;
...@@ -1458,13 +1456,11 @@ export default { ...@@ -1458,13 +1456,11 @@ export default {
}, },
async handleDetail(index, row) { async handleDetail(index, row) {
const that = this; const that = this;
const rule = "setmod.setglg.setgll(" + (index + 1) + ").det";
let rtnmsg = await this.executeRule(rule);
if (rtnmsg.respCode == SUCCESS) {
that.index = index; that.index = index;
that.$refs.detpDialog.visiable = true; that.$refs.detpDialog.visiable = true;
this.detpDialogVisible = true; this.detpDialogVisible = true;
that.dialog3 = that.model.setmod.setglg.setgll[index]; that.dialog3 = that.model.setmod.setglg.setgll[index];
debugger
that.rattyp = that.strCalCode(that.dialog3.rattyp, that.codes.ratetype); that.rattyp = that.strCalCode(that.dialog3.rattyp, that.codes.ratetype);
that.dcbrattyp = that.strCalCode( that.dcbrattyp = that.strCalCode(
that.dialog3.dcbrattyp, that.dialog3.dcbrattyp,
...@@ -1474,7 +1470,24 @@ export default { ...@@ -1474,7 +1470,24 @@ export default {
that.dialog3.scbrattyp, that.dialog3.scbrattyp,
that.codes.ratetype that.codes.ratetype
); );
}
// const rule = "setmod.setglg.setgll(" + (index + 1) + ").det";
// let rtnmsg = await this.executeRule(rule);
// if (rtnmsg.respCode == SUCCESS) {
// that.index = index;
// that.$refs.detpDialog.visiable = true;
// this.detpDialogVisible = true;
// that.dialog3 = that.model.setmod.setglg.setgll[index];
// that.rattyp = that.strCalCode(that.dialog3.rattyp, that.codes.ratetype);
// that.dcbrattyp = that.strCalCode(
// that.dialog3.dcbrattyp,
// that.codes.ratetype
// );
// that.scbrattyp = that.strCalCode(
// that.dialog3.scbrattyp,
// that.codes.ratetype
// );
// }
}, },
strCalCode(str, code) { strCalCode(str, code) {
var result = ""; var result = "";
...@@ -1535,26 +1548,22 @@ export default { ...@@ -1535,26 +1548,22 @@ export default {
} }
}, },
async dspChange(index) { async dspChange(index) {
// 获取记账账号
debugger
const vm = this; const vm = this;
vm.getSetgllAccts(1, {}); vm.root.setgllAccts((index + 1), vm.stmData3);
// let rtnmsg = await this.executeDefault(
debugger // "setmod.setglg.setgll(" + (index + 1) + ").dsp"
let rtnmsg = await this.executeDefault( // );
"setmod.setglg.setgll(" + (index + 1) + ").dsp" // if (rtnmsg.respCode == SUCCESS) {
); // //TODO 处理数据逻辑
if (rtnmsg.respCode == SUCCESS) { // this.updateModel(rtnmsg.data);
//TODO 处理数据逻辑 // this.$nextTick(() => {
this.updateModel(rtnmsg.data); // this.executeRule("setmod.glemod.glepan").then((res) => {
this.$nextTick(() => { // //TODO 处理数据逻辑
this.executeRule("setmod.glemod.glepan").then((res) => { // if (res.respCode == SUCCESS) this.updateModel(res.data);
//TODO 处理数据逻辑 // });
if (res.respCode == SUCCESS) this.updateModel(res.data); // });
}); // }
});
}
}, },
}, },
created: function () {}, created: function () {},
......
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