From a77e81bbf008e311fe0e1590bf6ac2962880502f Mon Sep 17 00:00:00 2001 From: shanao <178391389@qq.com> Date: Sun, 8 Sep 2024 22:08:29 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../accident/records/components/addOrEdit.vue | 87 +++++++++++++------ .../accident/records/components/list.vue | 16 ++-- src/views/accident/records/index.vue | 3 +- 3 files changed, 74 insertions(+), 32 deletions(-) diff --git a/src/views/accident/records/components/addOrEdit.vue b/src/views/accident/records/components/addOrEdit.vue index 1029d9a..a9c6e14 100644 --- a/src/views/accident/records/components/addOrEdit.vue +++ b/src/views/accident/records/components/addOrEdit.vue @@ -14,21 +14,13 @@ - - + + - + @@ -62,18 +54,9 @@ - diff --git a/src/views/accident/records/components/list.vue b/src/views/accident/records/components/list.vue index 0ef47bc..3e10e21 100644 --- a/src/views/accident/records/components/list.vue +++ b/src/views/accident/records/components/list.vue @@ -49,7 +49,7 @@ - 新增 + 新增 导出 全部导出 刷新 @@ -76,8 +76,8 @@ @@ -179,13 +179,17 @@ export default { }, /** - * 新增 + * 跳转页面 */ - handleAddNew() { + goView(id, name) { + this.$parent.id = id + this.$parent.tableName = name this.$parent.activeName = 'AddOrEdit' }, - // 删除行数据 + /** + * 删除行数据 + */ deleteRow(id) { if (id === null || id === '') { this.$message.warning('请选择要删除的行') diff --git a/src/views/accident/records/index.vue b/src/views/accident/records/index.vue index 2b09927..20a3876 100644 --- a/src/views/accident/records/index.vue +++ b/src/views/accident/records/index.vue @@ -19,7 +19,8 @@ export default { data() { return { activeName: 'List', - hiddenId: '' + id: '', + tableName: '' } }, watch: {