From 59e79288692eb2b973f5daa2c73acd953b32bda6 Mon Sep 17 00:00:00 2001 From: xiaobai <857694115@qq.com> Date: Fri, 27 Aug 2021 09:25:41 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E5=85=B6=E4=BB=96=E5=8E=9F?= =?UTF-8?q?=E5=A7=8B=E8=AE=B0=E5=BD=95=E6=A3=80=E9=AA=8C=E7=BB=93=E6=9E=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/ysjl/3000/common/index.vue | 2 +- src/views/ysjl/4000/dj/common/index.vue | 28 ++++++++++++++++------- src/views/ysjl/4000/jj/common/index.vue | 30 +++++++++++++++++-------- 3 files changed, 42 insertions(+), 18 deletions(-) diff --git a/src/views/ysjl/3000/common/index.vue b/src/views/ysjl/3000/common/index.vue index d83d727..484faed 100644 --- a/src/views/ysjl/3000/common/index.vue +++ b/src/views/ysjl/3000/common/index.vue @@ -1221,7 +1221,7 @@ export default { }) }) if (operation === 'add') { - this.ysjl.jilubianhao = this.jlbh1 + this.jlbh4 + this.jlbh2 + '-' + this.jlbh3 + this.ysjl.jilubianhao = this.jlbh1 + this.jlbh4 + this.jlbh2 + '-' + this.jlbh3 this.save(operation, 'post', tableData, fubiao) } else if (operation === 'build') { this.ysjl.baogaobianhao = this.ysjl.jilubianhao diff --git a/src/views/ysjl/4000/dj/common/index.vue b/src/views/ysjl/4000/dj/common/index.vue index a3f3208..8335847 100644 --- a/src/views/ysjl/4000/dj/common/index.vue +++ b/src/views/ysjl/4000/dj/common/index.vue @@ -926,12 +926,10 @@ export default { created() { if (this.state === 'create') { this.initYsjl() - this.getJyxm(1) // 查询最大记录编号 this.getMaxBh() } else { this.getYsjl(this.$route.query.id) - this.getJyxm(1) } this.getDepartment() }, @@ -1008,6 +1006,7 @@ export default { } }).then((data) => { this.ysjl = data.ysjl + this.getJyxm(1) this.departmentId = this.ysjl.departmentId this.param = data.param !== null && data.param !== undefined ? data.param : {} @@ -1036,6 +1035,7 @@ export default { } }).then((data) => { this.ysjl = data + this.getJyxm(1) this.departmentId = this.ysjl.departmentId if ( this.ysjl.jianyanrenyuan !== null && @@ -1072,10 +1072,15 @@ export default { getJyxm(sort) { if (this.$route.query.state === 'update') { this.jyxmService - .getJdCyJyxm(this.ysjlId, this.$route.query.templateId, sort) + .getJdCyJyxm(this.ysjlId, this.$route.query.templateId, sort, 0) .then((data) => { - this.sybjSData = data - this.tableJs.getData(this.cols, undefined, this.sybjSData) + this.bgfyData = data + this.tableJs.getData(this.cols, this.rows, this.bgfyData) + }) + this.jyxmService + .getJdCyJyxm(this.ysjlId, this.ysjl.jybgTemplateId, sort, 1) + .then((data) => { + this.jybgData = data }) } else { this.jyxmService @@ -1084,9 +1089,16 @@ export default { data.forEach((row) => { row.dicJyxmId = row.id }) - - this.sybjSData = data - this.tableJs.getData(this.cols, undefined, this.sybjSData) + this.bgfyData = data + this.tableJs.getData(this.cols, this.rows, this.bgfyData) + }) + this.jyxmService + .getCyJyxm(this.ysjl.jybgTemplateId, sort) + .then((data) => { + data.forEach((row) => { + row.dicJyxmId = row.id + }) + this.jybgData = data }) } }, diff --git a/src/views/ysjl/4000/jj/common/index.vue b/src/views/ysjl/4000/jj/common/index.vue index ecdb890..868280f 100644 --- a/src/views/ysjl/4000/jj/common/index.vue +++ b/src/views/ysjl/4000/jj/common/index.vue @@ -1011,12 +1011,10 @@ export default { created() { if (this.state === 'create') { this.initYsjl() - this.getJyxm(1) // 查询最大记录编号 this.getMaxBh() } else { this.getYsjl(this.$route.query.id) - this.getJyxm(1) } this.getDepartment() }, @@ -1094,6 +1092,7 @@ export default { }).then((data) => { this.ysjl = data.ysjl this.departmentId = this.ysjl.departmentId + this.getJyxm(1) this.param = data.param !== null && data.param !== undefined ? data.param : {} this.ysjl.jianyanjieshuriqi = this.formatter.dateFormat('YYYY-MM-dd') @@ -1116,7 +1115,7 @@ export default { ) this.param.shangcijianyanriqi = this.common.checkDateFormat( this.param.shangcijianyanriqi - ) + ) }) }, getYsjl(id) { @@ -1129,6 +1128,7 @@ export default { }).then((data) => { this.ysjl = data this.departmentId = this.ysjl.departmentId + this.getJyxm(1) if ( this.ysjl.jianyanrenyuan !== null && this.ysjl.jianyanrenyuan.length > 0 @@ -1165,10 +1165,15 @@ export default { getJyxm(sort) { if (this.$route.query.state === 'update') { this.jyxmService - .getJdCyJyxm(this.ysjlId, this.$route.query.templateId, sort) + .getJdCyJyxm(this.ysjlId, this.$route.query.templateId, sort, 0) + .then((data) => { + this.bgfyData = data + this.tableJs.getData(this.cols, this.rows, this.bgfyData) + }) + this.jyxmService + .getJdCyJyxm(this.ysjlId, this.ysjl.jybgTemplateId, sort, 1) .then((data) => { - this.sybjSData = data - this.tableJs.getData(this.cols, undefined, this.sybjSData) + this.jybgData = data }) } else { this.jyxmService @@ -1177,9 +1182,16 @@ export default { data.forEach((row) => { row.dicJyxmId = row.id }) - - this.sybjSData = data - this.tableJs.getData(this.cols, undefined, this.sybjSData) + this.bgfyData = data + this.tableJs.getData(this.cols, this.rows, this.bgfyData) + }) + this.jyxmService + .getCyJyxm(this.ysjl.jybgTemplateId, sort) + .then((data) => { + data.forEach((row) => { + row.dicJyxmId = row.id + }) + this.jybgData = data }) } },