From ac33a3fb2bfc4d4b11b958afe4d4b462d96fbb26 Mon Sep 17 00:00:00 2001
From: pyt <626651354@qq.com>
Date: 星期二, 01 四月 2025 10:38:20 +0800
Subject: [PATCH] Merge branch 'main' of http://120.76.84.145:10101/gitblit/r/H5/leshan-laboratory

---
 src/views/projectList/index.vue |   33 ++++++++++++++++++++++++++++-----
 1 files changed, 28 insertions(+), 5 deletions(-)

diff --git a/src/views/projectList/index.vue b/src/views/projectList/index.vue
index ef16e42..ffa8f0b 100644
--- a/src/views/projectList/index.vue
+++ b/src/views/projectList/index.vue
@@ -1,6 +1,7 @@
 <template>
     <div class="list">
-        <TableCustom :queryForm="queryForm" :total="total" @currentChange="handleCurrentChange" @sizeChange="handleSizeChange">
+        <TableCustom :queryForm="queryForm" :total="total" @currentChange="handleCurrentChange"
+            @sizeChange="handleSizeChange">
             <template #search>
                 <el-form :model="form" label-width="140px" inline>
                     <el-form-item label="项目组名称:">
@@ -19,7 +20,8 @@
                 </el-form>
             </template>
             <template #setting>
-                <el-button class="el-icon-plus" style="margin-bottom: 20px;" type="primary"> 新增项目组</el-button>
+                <el-button @click="handleAddProject" class="el-icon-plus" style="margin-bottom: 20px;" type="primary">
+                    新增项目组</el-button>
             </template>
             <template #table>
                 <el-table-column prop="name" label="项目组名称" />
@@ -44,7 +46,8 @@
             </template>
         </TableCustom>
         <ShowDelConfirm :show="showDelConfirm" @close="showDelConfirm = false" @confirm="handleDelConfirm" />
-        <ShowDelConfirm :title="changeStatusTitle" :tip="changeStatusTip" :show="changeStatus" @close="changeStatus = false" @confirm="handleChangeStatus" />
+        <ShowDelConfirm :title="changeStatusTitle" :tip="changeStatusTip" :show="changeStatus"
+            @close="changeStatus = false" @confirm="handleChangeStatusConfirm" />
     </div>
 </template>
 
@@ -69,25 +72,45 @@
         }
     },
     methods: {
+        handleAddProject() {
+            this.$router.push({
+                path: '/projectList/addProject'
+            })
+        },
         handleDel(row) {
-            this.showDelConfirm = true
             this.rowId = row.id
+            this.showDelConfirm = true
         },
         handleDelConfirm() {
             this.showDelConfirm = false
             this.msgsuccess('删除成功')
+            this.rowId = ''
+            this.getList()
         },
         handleChangeStatus(row, status) {
-            this.changeStatus = true
             this.rowId = row.id
             this.changeStatusTitle = status == 1 ? '确认要封存这个项目组吗?' : '确认要解封该项目组吗?'
             this.changeStatusTip = status == 1 ? '封存后项目组内人员看不到数据,审批人仍然可见数据。' : '解封后项目组内人员数据恢复。'
+            this.changeStatus = true
+        },
+        handleChangeStatusConfirm() {
+            this.changeStatus = false
+            this.msgsuccess('操作成功')
+            this.rowId = ''
+            this.changeStatusTitle = ''
+            this.changeStatusTip = ''
+            this.getList()
         },
         handleCurrentChange(page) {
             this.queryForm.pageNum = page
+            this.getList()
         },
         handleSizeChange(size) {
             this.queryForm.pageSize = size
+            this.getList()
+        },
+        getList() {
+
         }
     }
 }

--
Gitblit v1.7.1