From 646123cbbe83908eaaa681f8c0792830406affd4 Mon Sep 17 00:00:00 2001 From: "aoli.qu" <408346101@qq.com> Date: Tue, 23 Nov 2021 21:05:52 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=BA=E5=91=98=E9=A1=B9=E7=9B=AE=E5=85=B3?= =?UTF-8?q?=E8=81=94=E5=8A=9F=E8=83=BD=E5=BC=80=E5=8F=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/person/personOrg.js | 21 +++ src/views/org/OrgForm.vue | 4 +- src/views/org/OrgList.vue | 4 +- src/views/person/PersonForm.vue | 2 + src/views/person/PersonList.vue | 41 +++-- src/views/person/PersonOrgForm.vue | 254 +++++++++++++++++++++++++++++ 6 files changed, 308 insertions(+), 18 deletions(-) create mode 100644 src/api/person/personOrg.js create mode 100644 src/views/person/PersonOrgForm.vue diff --git a/src/api/person/personOrg.js b/src/api/person/personOrg.js new file mode 100644 index 0000000..d887449 --- /dev/null +++ b/src/api/person/personOrg.js @@ -0,0 +1,21 @@ +import request from '@/utils/request' + +const personOrgApi = { + listByOrgId: 'person/org/listByOrgId', + addPersonOrg: 'person/org/addPersonOrg' +} + +export function listPersonByOrgId(params) { + return request({ + url: personOrgApi.listByOrgId, + method: 'get', + params: params + }) +} +export function addPersonOrg(params) { + return request({ + url: personOrgApi.addPersonOrg, + method: 'post', + data: params + }) +} diff --git a/src/views/org/OrgForm.vue b/src/views/org/OrgForm.vue index eea5757..b9de120 100644 --- a/src/views/org/OrgForm.vue +++ b/src/views/org/OrgForm.vue @@ -193,7 +193,7 @@ this.$emit('ok', values) this.form.resetFields() } else { - this.$message.error('编辑失败:' + res.message) + this.$message.error('编辑失败:' + res.msg) } }).finally((res) => { this.confirmLoading = false @@ -208,7 +208,7 @@ this.$emit('ok', values) this.form.resetFields() } else { - this.$message.error('新增失败:' + res.message) + this.$message.error('新增失败:' + res.msg) } }).finally((res) => { this.confirmLoading = false diff --git a/src/views/org/OrgList.vue b/src/views/org/OrgList.vue index fdfeaca..10639d7 100644 --- a/src/views/org/OrgList.vue +++ b/src/views/org/OrgList.vue @@ -132,10 +132,10 @@ this.getOrgTree() this.$refs.table.clearRefreshSelected() } else { - this.$message.error('删除失败:' + res.message) + this.$message.error('删除失败:' + res.msg) } }).catch((err) => { - this.$message.error('删除错误:' + err.message) + this.$message.error('删除错误:' + err.msg) }) }, handleOk () { diff --git a/src/views/person/PersonForm.vue b/src/views/person/PersonForm.vue index 5582560..446f517 100644 --- a/src/views/person/PersonForm.vue +++ b/src/views/person/PersonForm.vue @@ -430,6 +430,8 @@ }, handleCancel () { this.form.resetFields() + this.fileList = [] + this.fileList2 = [] this.visible = false } } diff --git a/src/views/person/PersonList.vue b/src/views/person/PersonList.vue index d37038b..5b47638 100644 --- a/src/views/person/PersonList.vue +++ b/src/views/person/PersonList.vue @@ -5,10 +5,12 @@