From 087b4ce4c1078db207fda389358170697f0329cc Mon Sep 17 00:00:00 2001
From: shj <1790240199@qq.com>
Date: 星期六, 30 七月 2022 18:42:54 +0800
Subject: [PATCH] Merge branch 'master' of https://sinanoaq.cn:8888/r/gtqtOut

---
 src/views/contingencyManagement/contingency/component/openAdd.vue |   31 +++++++++++++++++++------------
 1 files changed, 19 insertions(+), 12 deletions(-)

diff --git a/src/views/contingencyManagement/contingency/component/openAdd.vue b/src/views/contingencyManagement/contingency/component/openAdd.vue
index e068c76..44361d3 100644
--- a/src/views/contingencyManagement/contingency/component/openAdd.vue
+++ b/src/views/contingencyManagement/contingency/component/openAdd.vue
@@ -1,7 +1,7 @@
 <template>
 	<div class="system-edit-user-container">
 		<el-dialog :title="titles" v-model="isShowDialog" width="769px" draggable :fullscreen="full">
-			<el-button @click="toggleFullscreen" size="small" class="pot" :icon="FullScreen"></el-button>
+			<el-button @click="toggleFullscreen" size="small" class="pot" :icon="FullScreen" ></el-button>
 			<el-form ref="ruleFormRef" :model="ruleForm" size="default" :rules="rules" label-width="120px" :disabled="disabled">
 				<el-row :gutter="35">
 					<el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20">
@@ -20,9 +20,9 @@
 					</el-col>
 					<el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20">
 						<el-form-item label="队伍负责人" prop="principalUid">
-							<el-input v-model="ruleForm.principalUid" placeholder="请选择" class="input-with-select">
+							<el-input v-model="ruleForm.principalUid" placeholder="请选择" class="input-with-select" disabled>
 								<template #append>
-									<el-button :icon="Search" @click="openUser" />
+									<el-button :icon="Search" @click="openUser" disabled/>
 								</template>
 							</el-input>
 						</el-form-item>
@@ -67,13 +67,14 @@
 			<el-row :gutter="35">
 				<el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24" class="mb20">
 					<el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick">
-						<el-tab-pane label="应急队伍人员" name="first">
-							<el-button type="primary" size="default" @click="onAddEmergencyPersonnel">新增</el-button>
+						<el-tab-pane label="应急队伍人员" name="first" :disabled="disabled">
+							<el-button type="primary" size="default" @click="onAddEmergencyPersonnel" :disabled="disabled">新增</el-button>
 							<el-table
 								:data="tableData"
 								style="width: 100%; margin-top: 15px"
 								ref="multipleTableRef"
 								:header-cell-style="{ background: '#f6f7fa', color: '#909399' }"
+                :disabled="disabled"
 							>
 								<el-table-column prop="jobNumber" label="人员工号" show-overflow-tooltip></el-table-column>
 								<el-table-column prop="name" label="人员名称" show-overflow-tooltip></el-table-column>
@@ -99,7 +100,7 @@
 			</template>
 		</el-dialog>
 		<AddEmergencyPersonnel ref="addRef"  @myAdd="onMyAdd"/>
-		<DailogSearchUser ref="userRef" @SearchUser="onUser" />
+		<DailogSearchUser ref="userRef" @SearchUsers="onUser" />
 	</div>
 </template>
 
@@ -144,7 +145,7 @@
     const ruleForm =ref({
         teamName: '', // 队伍名称
         teamLevel: '', // 队伍级别
-        principalUid: '', // 队伍负责人
+        principalUid: 1, // 队伍负责人
         principalDepartmentId: '',  //负责人部门
         principalPhone: '', // 负责人手机
         telephoneNumber: '', // 固定电话
@@ -238,9 +239,15 @@
     const openUser = () => {
       userRef.value.openDailog();
     };
+    const nameC = ref();
     const onUser = (e:any) => {
-      ruleForm.value.principalUid=e.id
+      ruleForm.value.principalUid = e.uid
+      nameC.value=e.realName
     };
+    // const onUser = (e:any) => {
+    //
+    //   ruleForm.value.principalUid=e.id
+    // };
     //定义tabs切换
     const activeName = ref('first')
     const handleClick = (tab: TabsPaneContext, event: Event) => {
@@ -364,7 +371,7 @@
         ruleForm.value = {
           teamName: '', // 队伍名称
           teamLevel: '', // 队伍级别
-          principalUid: '', // 队伍负责人
+          principalUid: 1, // 队伍负责人
           principalDepartmentId: '',  //负责人部门
           principalPhone: '', // 负责人手机
           telephoneNumber: '', // 固定电话
@@ -436,8 +443,8 @@
     const tableData = ref([]);
     //添加队伍负责人弹窗
     const addRef = ref();
-    const onAddEmergencyPersonnel = () => {
-      addRef.value.openDialog('新建应急队伍人员',false);
+    const onAddEmergencyPersonnel = (title:string,data: any) => {
+      addRef.value.openDialog('新建应急队伍人员',data);
     };
     // 新增后刷新
     const onMyAdd = (e: boolean) => {
@@ -508,7 +515,7 @@
       FullScreen,
       full,
       onUser,
-      // listQuery,
+      nameC,
       onMyAdd,
       // listApi,
       onEdit,

--
Gitblit v1.9.2