maotao 7 mesi fa
parent
commit
3d5488c5a1

+ 92 - 52
components/IncidentListFilter.vue

@@ -12,12 +12,16 @@
12
       
12
       
13
       <view class="area" @click="clickPageRouter('area')">
13
       <view class="area" @click="clickPageRouter('area')">
14
         <text class="name">楼栋</text>
14
         <text class="name">楼栋</text>
15
-        <text class="value ellipsis">{{searchData.area ? searchData.area.area : ''}}</text>
15
+        <text class="value ellipsis">{{searchData.area ? searchData.area.buildingName : ''}}</text>
16
       </view>
16
       </view>
17
       
17
       
18
-      <view class="category" @click="clickPageRouter('category')">
18
+      <view class="category">
19
         <text class="name">故障现象</text>
19
         <text class="name">故障现象</text>
20
-        <text class="value ellipsis">{{searchData.category ? searchData.category.category : ''}}</text>
20
+        <text class="value flex-1">
21
+					<uni-data-picker @change="categoryChange" v-model="searchData.category" :localdata="pageData.categoryList" popup-title="请选择故障信息" :map="{text:'category',value:'id'}">
22
+						
23
+					</uni-data-picker>
24
+				</text>
21
       </view>
25
       </view>
22
       
26
       
23
       <view class="acceptDate" @click="changeIsShowDate()">
27
       <view class="acceptDate" @click="changeIsShowDate()">
@@ -50,7 +54,7 @@
50
       </view>
54
       </view>
51
       
55
       
52
       <scroll-view scroll-y class="areas">
56
       <scroll-view scroll-y class="areas">
53
-        <view class="areas_item" v-for="area in pageData.areaList" :key="area.id" @click="clickArea(area)">{{area.area}}</view>
57
+        <view class="areas_item" v-for="area in pageData.areaList" :key="area.id" @click="clickArea(area)">{{area.buildingName}}</view>
54
       </scroll-view>
58
       </scroll-view>
55
     </view>
59
     </view>
56
     <view class="container_foot">
60
     <view class="container_foot">
@@ -59,7 +63,7 @@
59
       </view>
63
       </view>
60
     </view>
64
     </view>
61
   </view>
65
   </view>
62
-  <view class="container" @touchmove.stop.prevent v-else-if="pageData.pageRouter === 'category'">
66
+<!--  <view class="container" @touchmove.stop.prevent v-else-if="pageData.pageRouter === 'category'">
63
     <view class="container_form">
67
     <view class="container_form">
64
       <view class="hospital">
68
       <view class="hospital">
65
         <text class="name">故障现象</text>
69
         <text class="name">故障现象</text>
@@ -74,7 +78,7 @@
74
         <view class="cancel" @click="clickPageRouter('default')">取消</view>
78
         <view class="cancel" @click="clickPageRouter('default')">取消</view>
75
       </view>
79
       </view>
76
     </view>
80
     </view>
77
-  </view>
81
+  </view> -->
78
   <view class="mask" @touchmove.stop.prevent></view>
82
   <view class="mask" @touchmove.stop.prevent></view>
79
   <view class="line" @touchmove.stop.prevent></view>
83
   <view class="line" @touchmove.stop.prevent></view>
80
   
84
   
@@ -86,9 +90,10 @@
86
   import { startOfYear, endOfYear, format, add } from 'date-fns'
90
   import { startOfYear, endOfYear, format, add } from 'date-fns'
87
   import { onLoad } from '@dcloudio/uni-app'
91
   import { onLoad } from '@dcloudio/uni-app'
88
   import { useLoginUserStore } from '@/stores/loginUser'
92
   import { useLoginUserStore } from '@/stores/loginUser'
89
-  import { api_area, api_incidentcategory } from "@/http/api.js"
93
+  import { api_area, getFetchDataList, api_incidentcategory } from "@/http/api.js"
90
   import { defaultColor } from '@/static/js/theme.js'
94
   import { defaultColor } from '@/static/js/theme.js'
91
-  
95
+  import { transform } from '@/utils/index.js'
96
+	
92
   const emit = defineEmits(['cancelEmit', 'confirmEmit']);
97
   const emit = defineEmits(['cancelEmit', 'confirmEmit']);
93
   const { evt } = defineProps({
98
   const { evt } = defineProps({
94
     evt: {
99
     evt: {
@@ -125,7 +130,7 @@
125
     hospital: {},
130
     hospital: {},
126
     selected: 'todoingAll',
131
     selected: 'todoingAll',
127
     area: {id: 0, area: '全部'},
132
     area: {id: 0, area: '全部'},
128
-    category: {id: 0, category: '全部'},
133
+    category: {},
129
     acceptDate: [],
134
     acceptDate: [],
130
   })
135
   })
131
   
136
   
@@ -194,6 +199,10 @@
194
     }
199
     }
195
   }
200
   }
196
   
201
   
202
+	function categoryChange(val){
203
+		searchData.category = val.detail.value[val.detail.value.length-1]
204
+	}
205
+	
197
   // 获取楼栋列表
206
   // 获取楼栋列表
198
   function getAreaList(){
207
   function getAreaList(){
199
     uni.showLoading({
208
     uni.showLoading({
@@ -201,25 +210,39 @@
201
       mask: true,
210
       mask: true,
202
     });
211
     });
203
     
212
     
204
-    let postData = {
205
-      idx: 0,
206
-      sum: 9999,
207
-      area: {
208
-        branch: searchData.hospital.id,
209
-      },
210
-    }
211
-    api_area(postData).then(res => {
212
-      uni.hideLoading();
213
-      if(res.status == 200){
214
-        let list = res.list || [];
215
-        pageData.areaList = [{ id: 0, area: '全部' }, ...list];
216
-      }else{
217
-        uni.showToast({
218
-          icon: 'none',
219
-          title: res.msg || '请求数据失败!'
220
-        });
221
-      }
222
-    })
213
+    // let postData = {
214
+    //   idx: 0,
215
+    //   sum: 9999,
216
+    //   area: {
217
+    //     branch: searchData.hospital.id,
218
+    //   },
219
+    // }
220
+    // api_area(postData).then(res => {
221
+    //   uni.hideLoading();
222
+    //   if(res.status == 200){
223
+    //     let list = res.list || [];
224
+    //     pageData.areaList = [{ id: 0, area: '全部' }, ...list];
225
+    //   }else{
226
+    //     uni.showToast({
227
+    //       icon: 'none',
228
+    //       title: res.msg || '请求数据失败!'
229
+    //     });
230
+    //   }
231
+    // })
232
+		
233
+		let postData = {
234
+		  idx: 0,
235
+		  sum: 9999,
236
+			building:{
237
+				hosId: loginUserStore.loginUser.user.currentHospital.id,
238
+			}
239
+		};
240
+		getFetchDataList("simple/data", "building", postData)
241
+		  .then((res) => {
242
+				uni.hideLoading();
243
+		    let list = res.list || [];
244
+		    pageData.areaList = [{ id: 0, area: '全部' }, ...list];
245
+		  });
223
   }
246
   }
224
   
247
   
225
   // 获取故障现象列表
248
   // 获取故障现象列表
@@ -230,28 +253,44 @@
230
     });
253
     });
231
     
254
     
232
     let postData = {
255
     let postData = {
233
-      idx: 0,
234
-      sum: 9999,
235
-      incidentcategory: {},
236
-    }
237
-    if(loginUserStore.loginUser.user.duty){
238
-      postData.incidentcategory.dutyToCategory = loginUserStore.loginUser.user.duty.id;
239
-    }else if(loginUserStore.loginUser.user.branch){
240
-      postData.incidentcategory.selectType = 'one';
241
-    }
256
+    		hasThird:true,
257
+    		category: {
258
+    			dutyIds: loginUserStore.loginUser.user.currentHospital.id,
259
+    		},
260
+    	}
261
+    // if(loginUserStore.loginUser.user.duty){
262
+    //   postData.incidentcategory.dutyToCategory = loginUserStore.loginUser.user.duty.id;
263
+    // }else if(loginUserStore.loginUser.user.branch){
264
+    //   postData.incidentcategory.selectType = 'one';
265
+    // }
242
     
266
     
243
-    api_incidentcategory(postData).then(res => {
244
-      uni.hideLoading();
245
-      if(res.status == 200){
246
-        let list = res.list || [];
247
-        pageData.categoryList = [{ id:0, category: '全部' }, ...list];
248
-      }else{
249
-        uni.showToast({
250
-          icon: 'none',
251
-          title: res.msg || '请求数据失败!'
252
-        });
253
-      }
254
-    })
267
+    // api_incidentcategory(postData).then(res => {
268
+    //   uni.hideLoading();
269
+    //   if(res.status == 200){
270
+    //     let list = res.list || [];
271
+    //     pageData.categoryList = [{ id:0, category: '全部' }, ...list];
272
+    //   }else{
273
+    //     uni.showToast({
274
+    //       icon: 'none',
275
+    //       title: res.msg || '请求数据失败!'
276
+    //     });
277
+    //   }
278
+    // })
279
+		
280
+		
281
+		 api_incidentcategory(postData).then(res => {
282
+		   uni.hideLoading();
283
+		   if(res.status == 200){
284
+		     let list = res.data || [];
285
+					list = list.map(i=> ({...i, parentid: i.parent?.id}))
286
+					pageData.categoryList = transform(list, 'id', 'parentid')
287
+		   }else{
288
+		     uni.showToast({
289
+		       icon: 'none',
290
+		       title: res.msg || '请求数据失败!'
291
+		     });
292
+		   }
293
+		 })
255
   }
294
   }
256
   
295
   
257
   // 页面路由跳转
296
   // 页面路由跳转
@@ -261,9 +300,6 @@
261
       case 'area':
300
       case 'area':
262
         getAreaList();
301
         getAreaList();
263
       break;
302
       break;
264
-      case 'category':
265
-        getCategoryList();
266
-      break;
267
     }
303
     }
268
   }
304
   }
269
   
305
   
@@ -273,6 +309,7 @@
273
   }
309
   }
274
   
310
   
275
   onLoad((option) => {
311
   onLoad((option) => {
312
+		getCategoryList()
276
     // searchData.hospital = evt.hospital;
313
     // searchData.hospital = evt.hospital;
277
     for (let i = 0; i < loginUserStore.loginUser.menu.length; i++) {
314
     for (let i = 0; i < loginUserStore.loginUser.menu.length; i++) {
278
       if (loginUserStore.loginUser.menu[i].link == "shijianliebiao_all") {
315
       if (loginUserStore.loginUser.menu[i].link == "shijianliebiao_all") {
@@ -414,6 +451,9 @@
414
       flex-shrink: 0;
451
       flex-shrink: 0;
415
       margin-right: 24rpx;
452
       margin-right: 24rpx;
416
     }
453
     }
454
+		.flex-1{
455
+			flex: 3;
456
+		}
417
   }
457
   }
418
   
458
   
419
   .container_foot{
459
   .container_foot{

+ 15 - 20
components/InspectionListFilter.vue

@@ -77,7 +77,7 @@
77
   import { startOfYear, endOfYear, format, add } from 'date-fns'
77
   import { startOfYear, endOfYear, format, add } from 'date-fns'
78
   import { onLoad } from '@dcloudio/uni-app'
78
   import { onLoad } from '@dcloudio/uni-app'
79
   import { useLoginUserStore } from '@/stores/loginUser'
79
   import { useLoginUserStore } from '@/stores/loginUser'
80
-  import { api_building, api_inspectionForm } from "@/http/api.js"
80
+  import { api_building, getFetchDataList, api_inspectionForm } from "@/http/api.js"
81
   import { defaultColor } from '@/static/js/theme.js'
81
   import { defaultColor } from '@/static/js/theme.js'
82
   
82
   
83
   const emit = defineEmits(['cancelEmit', 'confirmEmit']);
83
   const emit = defineEmits(['cancelEmit', 'confirmEmit']);
@@ -158,25 +158,20 @@
158
       title: "加载中",
158
       title: "加载中",
159
       mask: true,
159
       mask: true,
160
     });
160
     });
161
-    
162
-    let postData = {
163
-      idx: 0,
164
-      sum: 9999,
165
-      account: loginUserStore.loginUser.user.account,
166
-      building: {},
167
-    }
168
-    api_building(postData).then(res => {
169
-      uni.hideLoading();
170
-      if(res.status == 200){
171
-        let list = res.list || [];
172
-        pageData.areaList = [{ id: 0, buildingName: '全部' }, ...list];
173
-      }else{
174
-        uni.showToast({
175
-          icon: 'none',
176
-          title: res.msg || '请求数据失败!'
177
-        });
178
-      }
179
-    })
161
+		let postData = {
162
+		  idx: 0,
163
+		  sum: 9999,
164
+			building:{
165
+				hosId: loginUserStore.loginUser.user.currentHospital.id,
166
+			}
167
+		};
168
+		getFetchDataList("simple/data", "building", postData)
169
+		  .then((res) => {
170
+				uni.hideLoading();
171
+		    let list = res.list || [];
172
+		    pageData.areaList = [{ id: 0, buildingName: '全部' }, ...list];
173
+				console.log(444,pageData.areaList )
174
+		  });
180
   }
175
   }
181
   
176
   
182
   // 获取故障现象列表
177
   // 获取故障现象列表

+ 6 - 13
components/repositoryFilter.vue

@@ -89,23 +89,16 @@
89
       mask: true,
89
       mask: true,
90
     });
90
     });
91
     
91
     
92
-    let postData = {
93
-      idx: 0,
94
-      sum: 9999,
95
-      incidentcategory: {
96
-
92
+	 let postData = {
93
+			hasThird:true,
94
+			category: {
95
+				dutyIds: loginUserStore.loginUser.user.currentHospital.id,
97
 			},
96
 			},
98
-    }
99
-    if(loginUserStore.loginUser.user.duty){
100
-      postData.incidentcategory.duty = loginUserStore.loginUser.user.duty.id;
101
-    }else if(loginUserStore.loginUser.user.branch){
102
-      postData.incidentcategory.branch = loginUserStore.loginUser.user.branch.id;
103
-    }
104
-    
97
+		}
105
     api_incidentcategory(postData).then(res => {
98
     api_incidentcategory(postData).then(res => {
106
       uni.hideLoading();
99
       uni.hideLoading();
107
       if(res.status == 200){
100
       if(res.status == 200){
108
-        let list = res.list || [];
101
+        let list = res.data || [];
109
 				list = list.map(i=> ({...i, parentid: i.parent?.id}))
102
 				list = list.map(i=> ({...i, parentid: i.parent?.id}))
110
 				pageData.categoryList = transform(list, 'id', 'parentid')
103
 				pageData.categoryList = transform(list, 'id', 'parentid')
111
       }else{
104
       }else{

+ 21 - 15
http/api.js

@@ -4,14 +4,14 @@ import { get, post, path } from "@/http/http.js"
4
  * 微信登录
4
  * 微信登录
5
  */
5
  */
6
 export function api_wechatLoginEncrypt(data){
6
 export function api_wechatLoginEncrypt(data){
7
-  return post("/auth/wechatLoginEncrypt", data);
7
+  return post("/auth/wxlogina", data);
8
 }
8
 }
9
 
9
 
10
 /**
10
 /**
11
  * 微信登录2
11
  * 微信登录2
12
  */
12
  */
13
 export function api_wechatAuth(data){
13
 export function api_wechatAuth(data){
14
-  return post("/auth/wechatAuth", data);
14
+  return post("/auth/wxlogin", data);
15
 }
15
 }
16
 
16
 
17
 /**
17
 /**
@@ -60,7 +60,7 @@ export function api_area(data){
60
  * 获取故障现象列表
60
  * 获取故障现象列表
61
  */
61
  */
62
 export function api_incidentcategory(data){
62
 export function api_incidentcategory(data){
63
-  return post("/bpm/data/fetchDataList/incidentcategory", data);
63
+  return post("/incident/listIncidentCategory", data);
64
 }
64
 }
65
 
65
 
66
 /**
66
 /**
@@ -81,21 +81,21 @@ export function api_callrecord(data){
81
  * 获取工作组列表
81
  * 获取工作组列表
82
  */
82
  */
83
 export function api_group(data){
83
 export function api_group(data){
84
-  return post("/user/data/fetchDataList/group", data);
84
+  return post("/data/fetchDataList/group2", data);
85
 }
85
 }
86
 
86
 
87
 /**
87
 /**
88
  * 获取人员列表
88
  * 获取人员列表
89
  */
89
  */
90
 export function api_user(data){
90
 export function api_user(data){
91
-  return post("/user/data/fetchDataList/user", data);
91
+  return post("/data/fetchDataList/user", data);
92
 }
92
 }
93
 
93
 
94
 /**
94
 /**
95
  * 获取院区列表
95
  * 获取院区列表
96
  */
96
  */
97
 export function api_branch(data){
97
 export function api_branch(data){
98
-  return post("/user/data/fetchDataList/branch", data);
98
+  return post("/data/fetchDataList/hospital", data);
99
 }
99
 }
100
 
100
 
101
 /**
101
 /**
@@ -151,7 +151,7 @@ export function api_workHourManagement(data){
151
  * 上传附件
151
  * 上传附件
152
  */
152
  */
153
 export function api_uploadAttachment(type, id){
153
 export function api_uploadAttachment(type, id){
154
-  return `${path}/common/common/uploadAttachment/${type}/${id}`
154
+  return `${path}/common/common/uploadAttachment/${type}/${id}/${id}`
155
 }
155
 }
156
 
156
 
157
 /**
157
 /**
@@ -172,7 +172,7 @@ export function api_incidentLog(data){
172
  * 获取报修科室列表
172
  * 获取报修科室列表
173
  */
173
  */
174
 export function api_department(data){
174
 export function api_department(data){
175
-  return post("/user/data/fetchDataList/department", data);
175
+  return post("/data/fetchDataList/department", data);
176
 }
176
 }
177
 
177
 
178
 /**
178
 /**
@@ -193,7 +193,7 @@ export function api_systemConfiguration(data){
193
  * 获取事件单号
193
  * 获取事件单号
194
  */
194
  */
195
 export function api_sj(){
195
 export function api_sj(){
196
-  return get("/bpm/bpm/restful/sj");
196
+  return get("/bpm/bpm/restful");
197
 }
197
 }
198
 
198
 
199
 /**
199
 /**
@@ -205,7 +205,7 @@ export function api_incidentCategoryConsumable(data){
205
 
205
 
206
 // 获取知识库列表
206
 // 获取知识库列表
207
 export function api_getSolution(data){
207
 export function api_getSolution(data){
208
-  return post("/solution/fetchDataList/solution", data);
208
+  return post("/data/fetchDataList/solution", data);
209
 }
209
 }
210
 	
210
 	
211
 /**
211
 /**
@@ -219,14 +219,14 @@ export function api_loginEncrypt(data){
219
  * 获取巡检执行列表
219
  * 获取巡检执行列表
220
  */
220
  */
221
 export function api_inspectionTask(data){
221
 export function api_inspectionTask(data){
222
-  return post("/hsms/fetchDataList/inspectionTask", data);
222
+  return post("/simple/data/fetchDataList/inspectionTask", data);
223
 }
223
 }
224
 
224
 
225
 /**
225
 /**
226
  * 获取巡检执行列表-数量
226
  * 获取巡检执行列表-数量
227
  */
227
  */
228
 export function api_listCount(data){
228
 export function api_listCount(data){
229
-  return post("/hsms/listCount", data);
229
+  return post("/itsmTemp/listCount", data);
230
 }
230
 }
231
 
231
 
232
 /**
232
 /**
@@ -240,7 +240,7 @@ export function api_hsms_getDictionary(data){
240
  * 获取巡检单列表
240
  * 获取巡检单列表
241
  */
241
  */
242
 export function api_inspectionForm(data){
242
 export function api_inspectionForm(data){
243
-  return post("/hsms/fetchDataList/inspectionForm", data);
243
+  return post("/simple/data/fetchDataList/inspectionForm", data);
244
 }
244
 }
245
 
245
 
246
 /**
246
 /**
@@ -254,13 +254,13 @@ export function api_building(data){
254
  * 巡检签到
254
  * 巡检签到
255
  */
255
  */
256
 export function api_scanCode(data){
256
 export function api_scanCode(data){
257
-  return post("/hsms/scanCode", data);
257
+  return post("/itsmTemp/scanCode", data);
258
 }
258
 }
259
 /**
259
 /**
260
  * 巡检执行项保存
260
  * 巡检执行项保存
261
  */
261
  */
262
 export function api_addModel(data){
262
 export function api_addModel(data){
263
-  return post("/hsms/addModel", data);
263
+  return post("/itsmTemp/addModel", data);
264
 }
264
 }
265
 
265
 
266
 /**
266
 /**
@@ -297,3 +297,9 @@ export function api_taskresolve(data){
297
 export function api_request(data){
297
 export function api_request(data){
298
   return post("/flow/incident/task/request", data);
298
   return post("/flow/incident/task/request", data);
299
 }
299
 }
300
+
301
+// 通用list
302
+export function getFetchDataList(type, target, data){
303
+  return post("/" + type + "/fetchDataList/" + target, data);
304
+}
305
+

+ 2 - 2
manifest.json

@@ -62,8 +62,8 @@
62
         "devServer" : {
62
         "devServer" : {
63
             "proxy" : {
63
             "proxy" : {
64
                 "/service" : {
64
                 "/service" : {
65
-                    "target" : "http://192.168.3.108", //请求的目标域名
66
-										// "target" : "http://192.168.4.163", //宋程玉本地
65
+                    // "target" : "http://192.168.3.108", //请求的目标域名
66
+										"target" : "http://192.168.4.105", //宋程玉本地
67
                     "changeOrigin" : true, //是否跨域
67
                     "changeOrigin" : true, //是否跨域
68
                     "secure" : false
68
                     "secure" : false
69
                 },
69
                 },

+ 10 - 1
pages.json

@@ -254,7 +254,16 @@
254
          "titleNView": false
254
          "titleNView": false
255
        }
255
        }
256
      }
256
      }
257
-   }
257
+   },
258
+	 {
259
+	   "path": "pages/searchUser/searchUser",
260
+	   "style": {
261
+	     "h5": {
262
+	       "titleNView": false
263
+	     },
264
+	     "enablePullDownRefresh": true
265
+	   }
266
+	 }
258
   ],
267
   ],
259
   "globalStyle": {
268
   "globalStyle": {
260
     "navigationBarTextStyle": "black",
269
     "navigationBarTextStyle": "black",

+ 214 - 151
pages/assign/assign.vue

@@ -44,7 +44,7 @@
44
 				</view>
44
 				</view>
45
         <view class="form_item">
45
         <view class="form_item">
46
           <view class="title"><text class="required newicon newicon-bitian transparent"></text>协同人员:</view>
46
           <view class="title"><text class="required newicon newicon-bitian transparent"></text>协同人员:</view>
47
-          <text class="synergeticNames ellipsis">{{dataInfo.synergetic.map(v => v.name).join(',')}}</text>
47
+          <text class="synergeticNames ellipsis">{{ synergeticArr}}</text>
48
           <button type="primary" plain size="mini" class="primaryPlainButton synergeticAdd" @click="synergeticAdd">+立即添加</button>
48
           <button type="primary" plain size="mini" class="primaryPlainButton synergeticAdd" @click="synergeticAdd">+立即添加</button>
49
         </view>
49
         </view>
50
         <view class="form_item_column">
50
         <view class="form_item_column">
@@ -121,7 +121,7 @@
121
         </view>
121
         </view>
122
         <view class="form_item">
122
         <view class="form_item">
123
           <view class="title"><text class="required newicon newicon-bitian transparent"></text>协同人员:</view>
123
           <view class="title"><text class="required newicon newicon-bitian transparent"></text>协同人员:</view>
124
-          <text class="synergeticNames ellipsis">{{dataInfo.synergetic.map(v => v.name).join(',')}}</text>
124
+          <text class="synergeticNames ellipsis">{{synergeticArr}}</text>
125
           <button type="primary" plain size="mini" class="primaryPlainButton synergeticAdd" @click="synergeticAdd('assign_supplement')">+立即添加</button>
125
           <button type="primary" plain size="mini" class="primaryPlainButton synergeticAdd" @click="synergeticAdd('assign_supplement')">+立即添加</button>
126
         </view>
126
         </view>
127
         <view class="form_item_column">
127
         <view class="form_item_column">
@@ -197,7 +197,7 @@
197
   import { ref, reactive, computed } from 'vue'
197
   import { ref, reactive, computed } from 'vue'
198
   import { onLoad } from '@dcloudio/uni-app'
198
   import { onLoad } from '@dcloudio/uni-app'
199
   import { generateNumberArray } from '@/utils/index.js'
199
   import { generateNumberArray } from '@/utils/index.js'
200
-  import { api_group, api_incidentDetail, api_getSolution, api_user, api_incidentTask, api_branch, api_dutyDepartment, api_getDictionary, api_querySummaryDoc, api_addSummaryDoc, api_systemConfiguration, api_sj } from "@/http/api.js"
200
+  import { api_group, getFetchDataList, api_incidentDetail, api_getSolution, api_user, api_incidentTask, api_branch, api_dutyDepartment, api_getDictionary, api_querySummaryDoc, api_addSummaryDoc, api_systemConfiguration, api_sj } from "@/http/api.js"
201
   import { defaultColor } from '@/static/js/theme.js'
201
   import { defaultColor } from '@/static/js/theme.js'
202
   import { useSetTitle } from '@/share/useSetTitle.js'
202
   import { useSetTitle } from '@/share/useSetTitle.js'
203
   import { useMakePhoneCall } from '@/share/useMakePhoneCall.js'
203
   import { useMakePhoneCall } from '@/share/useMakePhoneCall.js'
@@ -221,6 +221,18 @@
221
 	// 知识库id
221
 	// 知识库id
222
 	const solutionId = ref(null)
222
 	const solutionId = ref(null)
223
 	
223
 	
224
+	// 楼层id
225
+	const floorId = ref(null)
226
+	
227
+	// 协同人员
228
+	const synergeticArr = ref(null)
229
+	
230
+	const dicData = ref(null)
231
+	
232
+	const dutyList = ref(null)
233
+	
234
+	const userTypes = ref(null)
235
+	
224
   // 数据
236
   // 数据
225
   const dataInfo = reactive({
237
   const dataInfo = reactive({
226
     tabs: [
238
     tabs: [
@@ -252,7 +264,7 @@
252
     closecodeList: [],//处理结果列表
264
     closecodeList: [],//处理结果列表
253
     handlerImgList: [],//处理图片列表
265
     handlerImgList: [],//处理图片列表
254
     category: {},//故障现象
266
     category: {},//故障现象
255
-    synergetic: [],//协同人员
267
+    synergetic: null,//协同人员
256
     isAssignUser: 1, //工作组是否转派到人
268
     isAssignUser: 1, //工作组是否转派到人
257
     isAssignUserList: [
269
     isAssignUserList: [
258
       { text: '是', value: 1 },
270
       { text: '是', value: 1 },
@@ -547,7 +559,9 @@
547
     isSubmit.value = false;
559
     isSubmit.value = false;
548
     reset();
560
     reset();
549
     dataInfo.category = dataInfo.incidentData.category || {};
561
     dataInfo.category = dataInfo.incidentData.category || {};
550
-    dataInfo.synergetic = dataInfo.incidentData.synergetic || [];
562
+		if(dataInfo.incidentData.synergetic&&dataInfo.incidentData.synergetic.length>0){
563
+			synergeticArr.value = dataInfo.incidentData.synergetic.map(v => v.name).join(',');
564
+		}
551
     initForm();
565
     initForm();
552
   }
566
   }
553
   
567
   
@@ -555,7 +569,14 @@
555
   function changeGroup(){
569
   function changeGroup(){
556
     dataInfo.userId = undefined;
570
     dataInfo.userId = undefined;
557
     dataInfo.userList = [];
571
     dataInfo.userList = [];
558
-    getUsers();
572
+		let postData = {
573
+			"key": 'usertype',
574
+			"type": "list",
575
+		};
576
+		api_getDictionary(postData).then((data) => {
577
+			userTypes.value = data;
578
+			getUsers();
579
+		});
559
   }
580
   }
560
   
581
   
561
   // 选择是否转派到人
582
   // 选择是否转派到人
@@ -573,9 +594,8 @@
573
     let postData = {
594
     let postData = {
574
       "idx": 0,
595
       "idx": 0,
575
       "sum": 9999,
596
       "sum": 9999,
576
-      "group": {
577
-        "duty": dataInfo.incidentData.duty || undefined,
578
-        "selectType": "nouser"
597
+      "group2": {
598
+        "hospitals": loginUserStore.loginUser.user.currentHospital.id,
579
       }
599
       }
580
     };
600
     };
581
     api_group(postData).then(res => {
601
     api_group(postData).then(res => {
@@ -608,15 +628,9 @@
608
       "idx": 0,
628
       "idx": 0,
609
       "sum": 9999,
629
       "sum": 9999,
610
       "user": {
630
       "user": {
611
-        "duty": dataInfo.incidentData.duty || undefined,
631
+        "hospital": loginUserStore.loginUser.user.currentHospital.id,
612
         "groupdata": (dataInfo.groupId && !noGroup) ? { "id": dataInfo.groupId } : undefined,
632
         "groupdata": (dataInfo.groupId && !noGroup) ? { "id": dataInfo.groupId } : undefined,
613
-        "roledata": {
614
-            "rolecode": "first-line support"
615
-        },
616
-        "selectType": "1",
617
-        "selectDetails": 1,
618
-        "simple": true,
619
-        "engineer": 1,
633
+        userTypeIds:String(userTypes.value.map(v => v.id)),
620
       }
634
       }
621
     };
635
     };
622
     api_user(postData).then(res => {
636
     api_user(postData).then(res => {
@@ -643,7 +657,7 @@
643
       mask: true,
657
       mask: true,
644
     });
658
     });
645
     let postData = {
659
     let postData = {
646
-      "key": 'incident_handleCategory',
660
+      "key": 'incident_handle_type',
647
       "type": "list",
661
       "type": "list",
648
     };
662
     };
649
     api_getDictionary(postData).then(res => {
663
     api_getDictionary(postData).then(res => {
@@ -762,23 +776,29 @@
762
       incident: dataInfo.incidentData,
776
       incident: dataInfo.incidentData,
763
 			solutionId: solutionId.value
777
 			solutionId: solutionId.value
764
     }
778
     }
765
-    let result = await beforeBuild();
766
-    if(result[0].status == 200 && result[1].status == 200){
767
-      postData.incident.repairType = result[0].list.length ? result[0].list[0].valueconfig : undefined;
768
-      postData.incident.incidentsign = result[1].data || undefined;
769
-    }else{
770
-      uni.showToast({
771
-        icon: 'none',
772
-        title: '请求数据失败!'
773
-      });
774
-      return;
775
-    }
776
-    
779
+    // let result = await beforeBuild();
780
+    // if(result[0].status == 200 && result[1].status == 200){
781
+    //   postData.incident.repairType = result[0].list.length ? result[0].list[0].valueconfig : undefined;
782
+    //   postData.incident.incidentsign = result[1].data || undefined;
783
+    // }else{
784
+    //   uni.showToast({
785
+    //     icon: 'none',
786
+    //     title: '请求数据失败!'
787
+    //   });
788
+    //   return;
789
+    // }
790
+		postData.incident.place = {}
791
+		postData.incident.place.id = floorId.value
777
     postData.incident.handleDescription = dataInfo.handleDescription;
792
     postData.incident.handleDescription = dataInfo.handleDescription;
778
     postData.incident.handleCategory = {id: dataInfo.handleCategory};
793
     postData.incident.handleCategory = {id: dataInfo.handleCategory};
779
     postData.incident.closecode = {id: dataInfo.closecode};
794
     postData.incident.closecode = {id: dataInfo.closecode};
780
     postData.incident.category = dataInfo.category;
795
     postData.incident.category = dataInfo.category;
781
-    postData.incident.synergetic = dataInfo.synergetic;
796
+		if(dataInfo.synergetic && dataInfo.synergetic.length>0){
797
+			postData.incident.synergetic = dataInfo.synergetic
798
+		}else{
799
+			postData.incident.synergetic = null
800
+		}
801
+		console.log(999, postData.incident)
782
     postData.incident.directProcess = 1;//直接解决
802
     postData.incident.directProcess = 1;//直接解决
783
     return api_incidentTask('accept', postData);
803
     return api_incidentTask('accept', postData);
784
   }
804
   }
@@ -790,31 +810,35 @@
790
 			solutionId: solutionId.value
810
 			solutionId: solutionId.value
791
     }
811
     }
792
     
812
     
793
-    let result = await beforeBuild();
794
-    if(result[0].status == 200 && result[1].status == 200){
795
-      postData.incident.repairType = result[0].list.length ? result[0].list[0].valueconfig : undefined;
796
-      postData.incident.incidentsign = result[1].data || undefined;
797
-    }else{
798
-      uni.showToast({
799
-        icon: 'none',
800
-        title: '请求数据失败!'
801
-      });
802
-      return;
803
-    }
813
+    // let result = await beforeBuild();
814
+    // if(result[0].status == 200 && result[1].status == 200){
815
+    //   postData.incident.repairType = result[0].list.length ? result[0].list[0].valueconfig : undefined;
816
+    //   postData.incident.incidentsign = result[1].data || undefined;
817
+    // }else{
818
+    //   uni.showToast({
819
+    //     icon: 'none',
820
+    //     title: '请求数据失败!'
821
+    //   });
822
+    //   return;
823
+    // }
804
     
824
     
825
+		postData.incident.place = {}
826
+		postData.incident.place.id = floorId.value
805
     postData.incident.handleDescription = dataInfo.handleDescription;
827
     postData.incident.handleDescription = dataInfo.handleDescription;
806
     postData.incident.handleCategory = {id: dataInfo.handleCategory};
828
     postData.incident.handleCategory = {id: dataInfo.handleCategory};
807
     postData.incident.closecode = {id: dataInfo.closecode};
829
     postData.incident.closecode = {id: dataInfo.closecode};
808
     postData.incident.category = dataInfo.category;
830
     postData.incident.category = dataInfo.category;
809
-    postData.incident.synergetic = dataInfo.synergetic;
831
+		if(dataInfo.synergetic && dataInfo.synergetic.length>0){
832
+			postData.incident.synergetic = dataInfo.synergetic
833
+		}else{
834
+			postData.incident.synergetic = null
835
+		}
810
     postData.incident.directProcess = 1;//直接解决
836
     postData.incident.directProcess = 1;//直接解决
811
     
837
     
812
     postData.incident.acceptDate = dataInfo.acceptDate;
838
     postData.incident.acceptDate = dataInfo.acceptDate;
813
     postData.incident.responseHandleTime = dataInfo.responseHandleTime;
839
     postData.incident.responseHandleTime = dataInfo.responseHandleTime;
814
     postData.incident.handleTime = dataInfo.handleTime;
840
     postData.incident.handleTime = dataInfo.handleTime;
815
     postData.incident.handlingPersonnelUser = { id: dataInfo.handlingPersonnelUserId };
841
     postData.incident.handlingPersonnelUser = { id: dataInfo.handlingPersonnelUserId };
816
-    console.log(postData.incident)
817
-    
818
     return api_incidentTask('patchOrder', postData);
842
     return api_incidentTask('patchOrder', postData);
819
   }
843
   }
820
   
844
   
@@ -838,17 +862,17 @@
838
       incident: dataInfo.incidentData,
862
       incident: dataInfo.incidentData,
839
     }
863
     }
840
     
864
     
841
-    let result = await beforeBuild();
842
-    if(result[0].status == 200 && result[1].status == 200){
843
-      postData.incident.repairType = result[0].list.length ? result[0].list[0].valueconfig : undefined;
844
-      postData.incident.incidentsign = result[1].data || undefined;
845
-    }else{
846
-      uni.showToast({
847
-        icon: 'none',
848
-        title: '请求数据失败!'
849
-      });
850
-      return;
851
-    }
865
+    // let result = await beforeBuild();
866
+    // if(result[0].status == 200 && result[1].status == 200){
867
+    //   postData.incident.repairType = result[0].list.length ? result[0].list[0].valueconfig : undefined;
868
+    //   postData.incident.incidentsign = result[1].data || undefined;
869
+    // }else{
870
+    //   uni.showToast({
871
+    //     icon: 'none',
872
+    //     title: '请求数据失败!'
873
+    //   });
874
+    //   return;
875
+    // }
852
     
876
     
853
     if(dataInfo.userId){
877
     if(dataInfo.userId){
854
       // 派人
878
       // 派人
@@ -916,17 +940,13 @@
916
       return;
940
       return;
917
     }
941
     }
918
     
942
     
919
-    if(!dataInfo.incidentData.duty){
943
+    if(!dutyList.value){
920
       uni.showToast({
944
       uni.showToast({
921
       	icon: 'none',
945
       	icon: 'none',
922
         title: '您选择的故障现象没有设置责任科室'
946
         title: '您选择的故障现象没有设置责任科室'
923
       });
947
       });
924
       return;
948
       return;
925
     }
949
     }
926
-    console.log(dataInfo)
927
-    console.log(dataInfo.handlerImgList)
928
-    console.log(dataInfo.incidentData.repairImgList)
929
-    
930
     uni.showLoading({
950
     uni.showLoading({
931
       title: "加载中",
951
       title: "加载中",
932
       mask: true,
952
       mask: true,
@@ -997,6 +1017,7 @@
997
   
1017
   
998
   // 派单提交
1018
   // 派单提交
999
   function submitAssign(){
1019
   function submitAssign(){
1020
+		console.log(444,dutyList.value)
1000
     if(!dataInfo.groupId){
1021
     if(!dataInfo.groupId){
1001
       uni.showToast({
1022
       uni.showToast({
1002
       	icon: 'none',
1023
       	icon: 'none',
@@ -1013,7 +1034,7 @@
1013
       return;
1034
       return;
1014
     }
1035
     }
1015
     
1036
     
1016
-    if(!dataInfo.incidentData.duty){
1037
+    if(!dutyList.value){
1017
       uni.showToast({
1038
       uni.showToast({
1018
       	icon: 'none',
1039
       	icon: 'none',
1019
         title: '您选择的故障现象没有设置责任科室'
1040
         title: '您选择的故障现象没有设置责任科室'
@@ -1109,7 +1130,7 @@
1109
       return;
1130
       return;
1110
     }
1131
     }
1111
     
1132
     
1112
-    if(!dataInfo.incidentData.duty){
1133
+    if(!dutyList.value){
1113
       uni.showToast({
1134
       uni.showToast({
1114
       	icon: 'none',
1135
       	icon: 'none',
1115
         title: '您选择的故障现象没有设置责任科室'
1136
         title: '您选择的故障现象没有设置责任科室'
@@ -1214,10 +1235,10 @@
1214
 	    idx: 0,
1235
 	    idx: 0,
1215
 	    sum: 9999,
1236
 	    sum: 9999,
1216
 	    solution: {
1237
 	    solution: {
1217
-				category:{
1218
-					id:categoryId,
1219
-				},
1220
-				status:{id:72},
1238
+				deleteFlag:0,
1239
+				hosId: loginUserStore.loginUser.user.currentHospital.id,
1240
+				categoryId: categoryId,
1241
+				status:{id:dicData.value?.id},
1221
 	    }
1242
 	    }
1222
 	  }
1243
 	  }
1223
 	  
1244
 	  
@@ -1241,93 +1262,135 @@
1241
 	  return tempDiv.textContent || tempDiv.innerText || '';
1262
 	  return tempDiv.textContent || tempDiv.innerText || '';
1242
 	}
1263
 	}
1243
 	
1264
 	
1244
-  onLoad((option) => {
1245
-    menuAuthHandle()
1246
-    // 跳转页面选择了选项
1247
-    if(handlerStore.handler.data){
1248
-      Object.assign(dataInfo, handlerStore.handler.data);
1249
-      console.log(dataInfo)
1250
-      if(handlerStore.handler.sign === 'assign'){
1251
-        dataInfo.tabActiveValue = 'direct';
1252
-      }else if(handlerStore.handler.sign === 'assign_supplement'){
1253
-        dataInfo.tabActiveValue = 'supplement';
1254
-        next();
1255
-      }
1256
-			
1257
-			let storeData = handlerStore.handler.data
1258
-			if(storeData.type == 'rep'){
1259
-				if(storeData.handleDescription){
1260
-					dataInfo.handleDescription = getHtml(storeData.handleDescription);
1261
-					solutionId.value = storeData.solutionId
1265
+	// 获取字典
1266
+	function getDic(){
1267
+		let postData = {
1268
+		  "key": 'solution_status',
1269
+		  "type": "list",
1270
+		};
1271
+		api_getDictionary(postData).then(res => {
1272
+		  dicData.value = res.find(v => v.value == '3');
1273
+			// 跳转页面选择了选项
1274
+			if(handlerStore.handler.data){
1275
+			  Object.assign(dataInfo, handlerStore.handler.data);
1276
+				if(dataInfo.synergetic){
1277
+					synergeticArr.value = dataInfo.synergetic.map(v => v.name).join(',')
1262
 				}
1278
 				}
1263
-				if(storeData.tabType == 'direct'){
1264
-					dataInfo.tabActiveValue = 'direct'
1265
-				}else{
1266
-					dataInfo.tabActiveValue = 'supplement'
1267
-					dataInfo.supplementFlag = false
1279
+			  if(handlerStore.handler.sign === 'assign'){
1280
+			    dataInfo.tabActiveValue = 'direct';
1281
+			  }else if(handlerStore.handler.sign === 'assign_supplement'){
1282
+			    dataInfo.tabActiveValue = 'supplement';
1283
+			    next();
1284
+			  }
1285
+				
1286
+				let storeData = handlerStore.handler.data
1287
+				if(storeData.type == 'rep'){
1288
+					if(storeData.handleDescription){
1289
+						dataInfo.handleDescription = getHtml(storeData.handleDescription);
1290
+						solutionId.value = storeData.solutionId
1291
+					}
1292
+					if(storeData.tabType == 'direct'){
1293
+						dataInfo.tabActiveValue = 'direct'
1294
+					}else{
1295
+						dataInfo.tabActiveValue = 'supplement'
1296
+						dataInfo.supplementFlag = false
1297
+					}
1268
 				}
1298
 				}
1299
+				
1300
+			  handlerStore.clearHandlerData();
1301
+			  
1302
+			  if(dataInfo.category){
1303
+			     dataInfo.incidentData.category = dataInfo.category;
1304
+					 if(dataInfo.incidentData.place.floor){
1305
+					 	floorId.value = JSON.parse(JSON.stringify(dataInfo.incidentData.place.floor.id))
1306
+					 }
1307
+					 console.log(111)
1308
+					 getIntroduceCount(dataInfo.category.id)
1309
+			    // 处理责任科室
1310
+			    if(dataInfo.category.branchType == 1){
1311
+			      // 分院区
1312
+			      if(dataInfo.incidentData.branch){
1313
+			        let dutyConfig = dataInfo.category.branchUserGroups.find(v=>v.branchId == dataInfo.incidentData.branch);
1314
+			        if(dutyConfig && dutyConfig.dutyId && dutyConfig.dutyName){
1315
+			          dataInfo.incidentData.duty = {id:dutyConfig.dutyId,dept:dutyConfig.dutyName};
1316
+			        }else{
1317
+			          dataInfo.incidentData.duty = undefined;
1318
+			        }
1319
+			      }else{
1320
+			        dataInfo.incidentData.duty = undefined;
1321
+			      }
1322
+			    }else{
1323
+			      // 不分院区
1324
+			      dataInfo.incidentData.duty = dataInfo.category.dutyDepartment;
1325
+			    }
1326
+					getDuty()
1327
+			  }
1328
+			}else if(incidentBuildStore.incidentBuild.data){
1329
+				console.log(222)
1330
+			  // 初始化
1331
+			  Object.assign(dataInfo.incidentData, incidentBuildStore.incidentBuild.data);
1332
+				console.log(8889889,dataInfo.incidentData)
1333
+				if(dataInfo.incidentData.category){
1334
+					if(dataInfo.incidentData.synergetic){
1335
+						synergeticArr.value = dataInfo.incidentData.synergetic.map(v => v.name).join(',')
1336
+					}
1337
+			    dataInfo.category = dataInfo.incidentData.category;
1338
+			    getIntroduceCount(dataInfo.category.id)
1339
+			    // 处理责任科室
1340
+			    if(dataInfo.category.branchType == 1){
1341
+			      // 分院区
1342
+			      if(dataInfo.incidentData.branch){
1343
+			        let dutyConfig = dataInfo.category.branchUserGroups.find(v=>v.branchId == dataInfo.incidentData.branch);
1344
+			        if(dutyConfig && dutyConfig.dutyId && dutyConfig.dutyName){
1345
+			          dataInfo.incidentData.duty = {id:dutyConfig.dutyId,dept:dutyConfig.dutyName};
1346
+			        }else{
1347
+			          dataInfo.incidentData.duty = undefined;
1348
+			        }
1349
+			      }else{
1350
+			        dataInfo.incidentData.duty = undefined;
1351
+			      }
1352
+			    }else{
1353
+			      // 不分院区
1354
+			      dataInfo.incidentData.duty = dataInfo.category.dutyDepartment;
1355
+			    }
1356
+			  }
1357
+				if(dataInfo.incidentData.place.floor){
1358
+					floorId.value = JSON.parse(JSON.stringify(dataInfo.incidentData.place.floor.id))
1359
+				}
1360
+			  // if(dataInfo.incidentData.priority){
1361
+			  //   dataInfo.incidentData.priority = { id: dataInfo.incidentData.priority };
1362
+			  // }
1363
+				getDuty()
1364
+			  if(dataInfo.incidentData.source){
1365
+			    dataInfo.incidentData.source = { id: dataInfo.incidentData.source };
1366
+			  }
1367
+			  if(dataInfo.incidentData.requester){
1368
+			    dataInfo.incidentData.requester = dataInfo.incidentData.requester
1369
+			  }
1269
 			}
1370
 			}
1270
-			
1271
-      handlerStore.clearHandlerData();
1272
-      
1273
-      if(dataInfo.category){
1274
-         dataInfo.incidentData.category = dataInfo.category;
1275
-				 console.log(111)
1276
-				 getIntroduceCount(dataInfo.category.id)
1277
-        // 处理责任科室
1278
-        if(dataInfo.category.branchType == 1){
1279
-          // 分院区
1280
-          if(dataInfo.incidentData.branch){
1281
-            let dutyConfig = dataInfo.category.branchUserGroups.find(v=>v.branchId == dataInfo.incidentData.branch);
1282
-            if(dutyConfig && dutyConfig.dutyId && dutyConfig.dutyName){
1283
-              dataInfo.incidentData.duty = {id:dutyConfig.dutyId,dept:dutyConfig.dutyName};
1284
-            }else{
1285
-              dataInfo.incidentData.duty = undefined;
1286
-            }
1287
-          }else{
1288
-            dataInfo.incidentData.duty = undefined;
1289
-          }
1290
-        }else{
1291
-          // 不分院区
1292
-          dataInfo.incidentData.duty = dataInfo.category.dutyDepartment;
1293
-        }
1294
-      }
1295
-    }else if(incidentBuildStore.incidentBuild.data){
1296
-			console.log(222)
1297
-      // 初始化
1298
-      Object.assign(dataInfo.incidentData, incidentBuildStore.incidentBuild.data);
1299
-      if(dataInfo.incidentData.category){
1300
-        dataInfo.category = dataInfo.incidentData.category;
1301
-        getIntroduceCount(dataInfo.category.id)
1302
-        // 处理责任科室
1303
-        if(dataInfo.category.branchType == 1){
1304
-          // 分院区
1305
-          if(dataInfo.incidentData.branch){
1306
-            let dutyConfig = dataInfo.category.branchUserGroups.find(v=>v.branchId == dataInfo.incidentData.branch);
1307
-            if(dutyConfig && dutyConfig.dutyId && dutyConfig.dutyName){
1308
-              dataInfo.incidentData.duty = {id:dutyConfig.dutyId,dept:dutyConfig.dutyName};
1309
-            }else{
1310
-              dataInfo.incidentData.duty = undefined;
1311
-            }
1312
-          }else{
1313
-            dataInfo.incidentData.duty = undefined;
1314
-          }
1315
-        }else{
1316
-          // 不分院区
1317
-          dataInfo.incidentData.duty = dataInfo.category.dutyDepartment;
1318
-        }
1319
-      }
1320
-      if(dataInfo.incidentData.priority){
1321
-        dataInfo.incidentData.priority = { id: dataInfo.incidentData.priority };
1322
-      }
1323
-      if(dataInfo.incidentData.source){
1324
-        dataInfo.incidentData.source = { id: dataInfo.incidentData.source };
1325
-      }
1326
-      if(dataInfo.incidentData.requester){
1327
-        dataInfo.incidentData.requester = dataInfo.incidentData.requester
1328
-      }
1329
-    }
1330
-    
1371
+		})
1372
+	}
1373
+	
1374
+	// 获取故障现象是否绑定责任科室
1375
+	function getDuty(){
1376
+		let postData = {
1377
+		  idx: 0,
1378
+		  sum: 9999,
1379
+		  incidentCategoryConfig: {
1380
+		    categoryId: dataInfo.incidentData.category.id,
1381
+		    dutyId: loginUserStore.loginUser.user.currentHospital.id,
1382
+		  },
1383
+		};
1384
+		getFetchDataList("simple/data", "incidentCategoryConfig", postData).then(res => {
1385
+			dutyList.value = res.list.find(i=>i.priority == dataInfo.incidentData.priority) 
1386
+			// console.log(1111,dutyList.value)
1387
+			console.log(999,dataInfo.incidentData)
1388
+		})
1389
+	}
1390
+	
1391
+  onLoad((option) => {
1392
+    menuAuthHandle()
1393
+		getDic()
1331
     if(!dataInfo.tabActiveValue){
1394
     if(!dataInfo.tabActiveValue){
1332
       dataInfo.tabActiveValue = dataInfo.tabs[0].value;
1395
       dataInfo.tabActiveValue = dataInfo.tabs[0].value;
1333
     }
1396
     }

+ 14 - 17
pages/buildIncident/buildIncident.vue

@@ -35,7 +35,7 @@
35
       <view class="form_item">
35
       <view class="form_item">
36
         <view class="title"><text class="required newicon newicon-bitian transparent"></text>楼栋楼层:</view>
36
         <view class="title"><text class="required newicon newicon-bitian transparent"></text>楼栋楼层:</view>
37
         <view class="value category" @click="selectAreaPlace">
37
         <view class="value category" @click="selectAreaPlace">
38
-          <text class="categoryName ellipsis-multiline">{{incidentData.place ? incidentData.place.area.area + ' ' + incidentData.place.place : ''}}</text>
38
+          <text class="categoryName ellipsis-multiline" v-if="incidentData.place">{{incidentData.place ? incidentData.place.building.buildingName:''}} {{ incidentData.place&&incidentData.place.floor?incidentData.place.floor.floorName : incidentData.place.floorName}}</text>
39
           <text class="newicon newicon-weibiaoti2010104"></text>
39
           <text class="newicon newicon-weibiaoti2010104"></text>
40
         </view>
40
         </view>
41
       </view>
41
       </view>
@@ -96,7 +96,7 @@
96
 <script setup>
96
 <script setup>
97
   import { ref, reactive } from 'vue'
97
   import { ref, reactive } from 'vue'
98
   import { onLoad } from '@dcloudio/uni-app'
98
   import { onLoad } from '@dcloudio/uni-app'
99
-  import { api_branch, api_getDictionary, api_incidentTask } from "@/http/api.js"
99
+  import { api_branch, api_getDictionary, getFetchDataList, api_incidentTask } from "@/http/api.js"
100
   import { defaultColor } from '@/static/js/theme.js'
100
   import { defaultColor } from '@/static/js/theme.js'
101
   import { useSetTitle } from '@/share/useSetTitle.js'
101
   import { useSetTitle } from '@/share/useSetTitle.js'
102
   import { useGoBack } from '@/share/useGoBack.js'
102
   import { useGoBack } from '@/share/useGoBack.js'
@@ -280,17 +280,18 @@
280
       mask: true,
280
       mask: true,
281
     });
281
     });
282
     let postData = {
282
     let postData = {
283
-      "key": 'incident_priority',
284
-      "type": "list",
283
+      priority: {},
284
+      idx: 0,
285
+      sum: 9999,
285
     };
286
     };
286
-    api_getDictionary(postData).then(res => {
287
-      uni.hideLoading();
288
-      res = res || [];
289
-      dataInfo.priorityList = res.map(v => ({
290
-        text: v.name,
291
-        value: v.id,
292
-      }));
293
-    })
287
+		getFetchDataList("simple/data", "priority", postData)
288
+		  .then((data) => {
289
+				uni.hideLoading();
290
+		    dataInfo.priorityList = data.list.map(v => ({
291
+		      text: v.name,
292
+		      value: v.id,
293
+		    }));
294
+		  });
294
   }
295
   }
295
 
296
 
296
   // 选择院区
297
   // 选择院区
@@ -306,7 +307,6 @@
306
     let postData = {
307
     let postData = {
307
       incident: dataInfo.incidentData,
308
       incident: dataInfo.incidentData,
308
     }
309
     }
309
-
310
     postData.incident.handleDescription = dataInfo.handleDescription;
310
     postData.incident.handleDescription = dataInfo.handleDescription;
311
     postData.incident.handleCategory = {id: dataInfo.handleCategory};
311
     postData.incident.handleCategory = {id: dataInfo.handleCategory};
312
     postData.incident.closecode = {id: dataInfo.closecode};
312
     postData.incident.closecode = {id: dataInfo.closecode};
@@ -324,7 +324,6 @@
324
   // 提交
324
   // 提交
325
   function submit(){
325
   function submit(){
326
     isSubmit.value = true;
326
     isSubmit.value = true;
327
-    console.log(dataInfo);
328
     if(!incidentData.branch){
327
     if(!incidentData.branch){
329
       uni.showToast({
328
       uni.showToast({
330
       	icon: 'none',
329
       	icon: 'none',
@@ -380,8 +379,6 @@
380
       });
379
       });
381
       return;
380
       return;
382
     }
381
     }
383
-    console.log(incidentData);
384
-
385
     // 处理责任科室
382
     // 处理责任科室
386
     if(incidentData.category.branchType == 1){
383
     if(incidentData.category.branchType == 1){
387
       // 分院区
384
       // 分院区
@@ -421,7 +418,7 @@
421
       // 修改报修科室,则回显楼栋,楼层,详细地址,联系电话
418
       // 修改报修科室,则回显楼栋,楼层,详细地址,联系电话
422
       if(incidentBuildStore.incidentBuild.sign === 'department'){
419
       if(incidentBuildStore.incidentBuild.sign === 'department'){
423
 				if(incidentData.department){
420
 				if(incidentData.department){
424
-					incidentData.place = incidentData.department.place || undefined;
421
+					incidentData.place = incidentData.department || undefined;
425
 					incidentData.houseNumber = incidentData.department.address || '';
422
 					incidentData.houseNumber = incidentData.department.address || '';
426
 					incidentData.contactsInformation = incidentData.department.phone ? incidentData.department.phone.split(',')[0] : '';
423
 					incidentData.contactsInformation = incidentData.department.phone ? incidentData.department.phone.split(',')[0] : '';
427
 				}
424
 				}

+ 27 - 26
pages/categoryOne/categoryOne.vue

@@ -55,37 +55,38 @@
55
       mask: true,
55
       mask: true,
56
     });
56
     });
57
     
57
     
58
-    dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
59
-    if(dataInfo.idx === 0){
60
-      dataInfo.list = [];
61
-    }
58
+    // dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
59
+    // if(dataInfo.idx === 0){
60
+    //   dataInfo.list = [];
61
+    // }
62
 
62
 
63
     let postData = {
63
     let postData = {
64
-      idx: dataInfo.idx,
65
-      sum: 9999,
66
-      incidentcategory: {
67
-        selectType: 'one',
68
-      }
64
+      // idx: dataInfo.idx,
65
+      // sum: 9999,
66
+			category: {hierarchy: 1}
67
+      // incidentcategory: {
68
+      //   selectType: 'one',
69
+      // }
69
     }
70
     }
70
     
71
     
71
     // 当前所属院区或责任科室
72
     // 当前所属院区或责任科室
72
-    if(loginUserStore.loginUser.user.duty){
73
-      postData.incidentcategory.duty = loginUserStore.loginUser.user.duty.id;
74
-    }else if(loginUserStore.loginUser.user.branch){
75
-      postData.incidentcategory.branch = loginUserStore.loginUser.user.branch.id;
76
-    }
73
+    // if(loginUserStore.loginUser.user.duty){
74
+    //   postData.incidentcategory.duty = loginUserStore.loginUser.user.duty.id;
75
+    // }else if(loginUserStore.loginUser.user.branch){
76
+    //   postData.incidentcategory.branch = loginUserStore.loginUser.user.branch.id;
77
+    // }
77
     
78
     
78
     api_incidentcategory(postData).then(res => {
79
     api_incidentcategory(postData).then(res => {
79
       uni.hideLoading();
80
       uni.hideLoading();
80
       uni.stopPullDownRefresh();
81
       uni.stopPullDownRefresh();
81
       if(res.status == 200){
82
       if(res.status == 200){
82
-        let list = res.list || [];
83
-        if(list.length){
84
-          dataInfo.hasMore = true;
85
-          dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
86
-        }else{
87
-          dataInfo.hasMore = false;
88
-        }
83
+        dataInfo.list = res.data || [];
84
+        // if(list.length){
85
+        //   dataInfo.hasMore = true;
86
+        //   dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
87
+        // }else{
88
+        //   dataInfo.hasMore = false;
89
+        // }
89
       }else{
90
       }else{
90
         uni.showToast({
91
         uni.showToast({
91
           icon: 'none',
92
           icon: 'none',
@@ -101,14 +102,14 @@
101
   })
102
   })
102
   
103
   
103
   onPullDownRefresh(() => {
104
   onPullDownRefresh(() => {
104
-    getList(0)
105
+    // getList(0)
105
   })
106
   })
106
   
107
   
107
   onReachBottom(() => {
108
   onReachBottom(() => {
108
-    dataInfo.idx += 1;
109
-    if (dataInfo.hasMore) {
110
-      getList(); // 当触底时加载更多数据
111
-    }
109
+    // dataInfo.idx += 1;
110
+    // if (dataInfo.hasMore) {
111
+    //   getList(); // 当触底时加载更多数据
112
+    // }
112
   })
113
   })
113
 </script>
114
 </script>
114
 
115
 

+ 24 - 24
pages/categoryThree/categoryThree.vue

@@ -99,15 +99,15 @@
99
       mask: true,
99
       mask: true,
100
     });
100
     });
101
     
101
     
102
-    dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
103
-    if(dataInfo.idx === 0){
104
-      dataInfo.list = [];
105
-    }
102
+    // dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
103
+    // if(dataInfo.idx === 0){
104
+    //   dataInfo.list = [];
105
+    // }
106
 
106
 
107
     let postData = {
107
     let postData = {
108
-      idx: dataInfo.idx,
109
-      sum: 9999,
110
-      incidentcategory: {
108
+      // idx: dataInfo.idx,
109
+      // sum: 9999,
110
+      category: {
111
         parent: {
111
         parent: {
112
           id: dataInfo.parentId,
112
           id: dataInfo.parentId,
113
         },
113
         },
@@ -115,23 +115,23 @@
115
     }
115
     }
116
     
116
     
117
     // 当前所属院区或责任科室
117
     // 当前所属院区或责任科室
118
-    if(loginUserStore.loginUser.user.duty){
119
-      postData.incidentcategory.duty = loginUserStore.loginUser.user.duty.id;
120
-    }else if(loginUserStore.loginUser.user.branch){
121
-      postData.incidentcategory.branch = loginUserStore.loginUser.user.branch.id;
122
-    }
118
+    // if(loginUserStore.loginUser.user.duty){
119
+    //   postData.incidentcategory.duty = loginUserStore.loginUser.user.duty.id;
120
+    // }else if(loginUserStore.loginUser.user.branch){
121
+    //   postData.incidentcategory.branch = loginUserStore.loginUser.user.branch.id;
122
+    // }
123
     
123
     
124
     api_incidentcategory(postData).then(res => {
124
     api_incidentcategory(postData).then(res => {
125
       uni.hideLoading();
125
       uni.hideLoading();
126
       uni.stopPullDownRefresh();
126
       uni.stopPullDownRefresh();
127
       if(res.status == 200){
127
       if(res.status == 200){
128
-        let list = res.list || [];
129
-        if(list.length){
130
-          dataInfo.hasMore = true;
131
-          dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
132
-        }else{
133
-          dataInfo.hasMore = false;
134
-        }
128
+         dataInfo.list = res.data || [];
129
+        // if(list.length){
130
+        //   dataInfo.hasMore = true;
131
+        //   dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
132
+        // }else{
133
+        //   dataInfo.hasMore = false;
134
+        // }
135
       }else{
135
       }else{
136
         uni.showToast({
136
         uni.showToast({
137
           icon: 'none',
137
           icon: 'none',
@@ -150,14 +150,14 @@
150
   })
150
   })
151
   
151
   
152
   onPullDownRefresh(() => {
152
   onPullDownRefresh(() => {
153
-    getList(0)
153
+    // getList(0)
154
   })
154
   })
155
   
155
   
156
   onReachBottom(() => {
156
   onReachBottom(() => {
157
-    dataInfo.idx += 1;
158
-    if (dataInfo.hasMore) {
159
-      getList(); // 当触底时加载更多数据
160
-    }
157
+    // dataInfo.idx += 1;
158
+    // if (dataInfo.hasMore) {
159
+    //   getList(); // 当触底时加载更多数据
160
+    // }
161
   })
161
   })
162
 </script>
162
 </script>
163
 
163
 

+ 24 - 24
pages/categoryTwo/categoryTwo.vue

@@ -57,15 +57,15 @@
57
       mask: true,
57
       mask: true,
58
     });
58
     });
59
     
59
     
60
-    dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
61
-    if(dataInfo.idx === 0){
62
-      dataInfo.list = [];
63
-    }
60
+    // dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
61
+    // if(dataInfo.idx === 0){
62
+    //   dataInfo.list = [];
63
+    // }
64
 
64
 
65
     let postData = {
65
     let postData = {
66
-      idx: dataInfo.idx,
67
-      sum: 9999,
68
-      incidentcategory: {
66
+      // idx: dataInfo.idx,
67
+      // sum: 9999,
68
+      category: {
69
         parent: {
69
         parent: {
70
           id: dataInfo.parentId,
70
           id: dataInfo.parentId,
71
         },
71
         },
@@ -73,23 +73,23 @@
73
     }
73
     }
74
     
74
     
75
     // 当前所属院区或责任科室
75
     // 当前所属院区或责任科室
76
-    if(loginUserStore.loginUser.user.duty){
77
-      postData.incidentcategory.duty = loginUserStore.loginUser.user.duty.id;
78
-    }else if(loginUserStore.loginUser.user.branch){
79
-      postData.incidentcategory.branch = loginUserStore.loginUser.user.branch.id;
80
-    }
76
+    // if(loginUserStore.loginUser.user.duty){
77
+    //   postData.incidentcategory.duty = loginUserStore.loginUser.user.duty.id;
78
+    // }else if(loginUserStore.loginUser.user.branch){
79
+    //   postData.incidentcategory.branch = loginUserStore.loginUser.user.branch.id;
80
+    // }
81
     
81
     
82
     api_incidentcategory(postData).then(res => {
82
     api_incidentcategory(postData).then(res => {
83
       uni.hideLoading();
83
       uni.hideLoading();
84
       uni.stopPullDownRefresh();
84
       uni.stopPullDownRefresh();
85
       if(res.status == 200){
85
       if(res.status == 200){
86
-        let list = res.list || [];
87
-        if(list.length){
88
-          dataInfo.hasMore = true;
89
-          dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
90
-        }else{
91
-          dataInfo.hasMore = false;
92
-        }
86
+        dataInfo.list = res.data || [];
87
+        // if(list.length){
88
+        //   dataInfo.hasMore = true;
89
+        //   dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
90
+        // }else{
91
+        //   dataInfo.hasMore = false;
92
+        // }
93
       }else{
93
       }else{
94
         uni.showToast({
94
         uni.showToast({
95
           icon: 'none',
95
           icon: 'none',
@@ -107,14 +107,14 @@
107
   })
107
   })
108
   
108
   
109
   onPullDownRefresh(() => {
109
   onPullDownRefresh(() => {
110
-    getList(0)
110
+    // getList(0)
111
   })
111
   })
112
   
112
   
113
   onReachBottom(() => {
113
   onReachBottom(() => {
114
-    dataInfo.idx += 1;
115
-    if (dataInfo.hasMore) {
116
-      getList(); // 当触底时加载更多数据
117
-    }
114
+    // dataInfo.idx += 1;
115
+    // if (dataInfo.hasMore) {
116
+    //   getList(); // 当触底时加载更多数据
117
+    // }
118
   })
118
   })
119
 </script>
119
 </script>
120
 
120
 

+ 10 - 8
pages/homePage/homePage.vue

@@ -24,23 +24,25 @@
24
    */
24
    */
25
   function wechatLoginEncrypt() {
25
   function wechatLoginEncrypt() {
26
     const url = window.location.href.split("?");
26
     const url = window.location.href.split("?");
27
+		let wenhaohoumian = window.location.href.split("?code="); //截取问号地址数组
28
+		let codeStr = wenhaohoumian[1]; //地址数组赋值
27
     if (!url[1]) {
29
     if (!url[1]) {
28
       wechatAuth();
30
       wechatAuth();
29
     } else {
31
     } else {
30
-      const code = {
31
-        code: url[1],
32
-        type: 'user',
33
-      };
32
+			codeStr = codeStr.split("&");
33
+			codeStr = codeStr[0];
34
       uni.showLoading({
34
       uni.showLoading({
35
         title: "登录中",
35
         title: "登录中",
36
         mask: true,
36
         mask: true,
37
       });
37
       });
38
-      api_wechatLoginEncrypt(code).then(res => {
38
+      api_wechatLoginEncrypt({
39
+				code:codeStr
40
+			}).then(res => {
39
         uni.hideLoading();
41
         uni.hideLoading();
40
-        if (res.state == 200) {
42
+        if (res.status == 200) {
41
           loginSuccess(res.user);
43
           loginSuccess(res.user);
42
 					getConfig();
44
 					getConfig();
43
-        } else if (res.state == 501) {
45
+        } else if (res.status == 501) {
44
           uni.showModal({
46
           uni.showModal({
45
             title: '提示',
47
             title: '提示',
46
             content: '您的账号被删除,请联系管理员',
48
             content: '您的账号被删除,请联系管理员',
@@ -48,7 +50,7 @@
48
             confirmColor: defaultColor,
50
             confirmColor: defaultColor,
49
             confirmText: '取消',
51
             confirmText: '取消',
50
           });
52
           });
51
-        } else if (res.state == 403) {
53
+        } else if (res.status == 403) {
52
           uni.reLaunch({
54
           uni.reLaunch({
53
             url: `/pages/initBind/initBind?wechat=${res.wechat}`
55
             url: `/pages/initBind/initBind?wechat=${res.wechat}`
54
           })
56
           })

+ 3 - 3
pages/incidentDetail/incidentDetail.vue

@@ -51,7 +51,7 @@
51
           </view>
51
           </view>
52
           <view class="deital_item">
52
           <view class="deital_item">
53
             <text class="name">详细地址:</text>
53
             <text class="name">详细地址:</text>
54
-            <text class="value" v-if="dataInfo.incidentData.place || dataInfo.incidentData.houseNumber">{{dataInfo.incidentData.place ? (dataInfo.incidentData.place.area.area + dataInfo.incidentData.place.place) : ''}}{{dataInfo.incidentData.houseNumber || ''}}</text>
54
+            <text class="value" v-if="dataInfo.incidentData.place || dataInfo.incidentData.houseNumber">{{dataInfo.incidentData.place ? dataInfo.incidentData.place.building.buildingName : ''}}{{dataInfo.incidentData.place ? dataInfo.incidentData.place.floorName : ''}}{{dataInfo.incidentData.houseNumber}}</text>
55
             <text class="value" v-else>无</text>
55
             <text class="value" v-else>无</text>
56
           </view>
56
           </view>
57
           <view class="deital_item">
57
           <view class="deital_item">
@@ -369,9 +369,9 @@
369
         let logs = dataInfo.incidentData.logs || [];
369
         let logs = dataInfo.incidentData.logs || [];
370
         dataInfo.resolveLogs = logs.filter(v => v.logType.value == 'resolve').slice(0, 1);
370
         dataInfo.resolveLogs = logs.filter(v => v.logType.value == 'resolve').slice(0, 1);
371
         dataInfo.callbackLogs = logs.filter(v => v.logType.value == 'callback').slice(0, 1);
371
         dataInfo.callbackLogs = logs.filter(v => v.logType.value == 'callback').slice(0, 1);
372
-
372
+				console.log(41414,dataInfo.incidentData)
373
         // 维修汇总单
373
         // 维修汇总单
374
-        if(dataInfo.incidentData.state.value == 'close' && dataInfo.incidentData.duty.addSummary == 1 && dataInfo.incidentData.summaryId){
374
+        if(dataInfo.incidentData.state.value == 'close' && dataInfo.incidentData.duty && dataInfo.incidentData.duty.addSummary == 1 && dataInfo.incidentData.summaryId){
375
           let flag = dataInfo.tabs.some(v => v.value === '2');
375
           let flag = dataInfo.tabs.some(v => v.value === '2');
376
           !flag && dataInfo.tabs.splice(1, 0, {id: 2, name: '维修汇总单', value: '2', num: ''});
376
           !flag && dataInfo.tabs.splice(1, 0, {id: 2, name: '维修汇总单', value: '2', num: ''});
377
         }
377
         }

+ 6 - 4
pages/incidentList/incidentList.vue

@@ -20,7 +20,7 @@
20
             <view class="status" :style="stateStyle(data.state)">{{data.state ? data.state.name : ''}}</view>
20
             <view class="status" :style="stateStyle(data.state)">{{data.state ? data.state.name : ''}}</view>
21
           </view>
21
           </view>
22
           <view class="body_item_content_p" v-if="data.place || data.houseNumber">
22
           <view class="body_item_content_p" v-if="data.place || data.houseNumber">
23
-            <text class="name ellipsis">详细地址:{{data.place ? data.place.area.area : ''}}{{data.place ? data.place.place : ''}}{{data.houseNumber}}</text>
23
+            <text class="name ellipsis">详细地址:{{data.place ? data.place.building.buildingName : ''}}{{data.place ? data.place.floorName : ''}}{{data.houseNumber}}</text>
24
           </view>
24
           </view>
25
           <view class="body_item_content_p" v-if="data.currentLog && data.currentLog.extra1DTO && data.currentLog.extra2 && data.currentLog.startTime">
25
           <view class="body_item_content_p" v-if="data.currentLog && data.currentLog.extra1DTO && data.currentLog.extra2 && data.currentLog.startTime">
26
             <text class="name ellipsis">延期处理:{{currentLogOverTime(data.currentLog)}}</text>
26
             <text class="name ellipsis">延期处理:{{currentLogOverTime(data.currentLog)}}</text>
@@ -292,8 +292,8 @@
292
         delete postData.incident.candidateGroups;
292
         delete postData.incident.candidateGroups;
293
     }
293
     }
294
 
294
 
295
-    if(dataInfo.evtFilter && dataInfo.evtFilter.category && dataInfo.evtFilter.category.id){
296
-      postData.incident.levelCategory = { id: dataInfo.evtFilter.category.id };
295
+    if(dataInfo.evtFilter && dataInfo.evtFilter.category){
296
+      postData.incident.levelCategory = { id: dataInfo.evtFilter.category.value };
297
     }
297
     }
298
 
298
 
299
     if(dataInfo.evtFilter && Array.isArray(dataInfo.evtFilter.acceptDate) && dataInfo.evtFilter.acceptDate.length){
299
     if(dataInfo.evtFilter && Array.isArray(dataInfo.evtFilter.acceptDate) && dataInfo.evtFilter.acceptDate.length){
@@ -302,7 +302,9 @@
302
     }
302
     }
303
 
303
 
304
     if(dataInfo.evtFilter && dataInfo.evtFilter.area && dataInfo.evtFilter.area.id){
304
     if(dataInfo.evtFilter && dataInfo.evtFilter.area && dataInfo.evtFilter.area.id){
305
-      postData.incident.area = dataInfo.evtFilter.area
305
+			let id = dataInfo.evtFilter.area.id
306
+			// postData.incident.area = dataInfo.evtFilter.area
307
+			postData.incident.area = {id:id}
306
     }
308
     }
307
 
309
 
308
     incidentListSearchStore.setIncidentListSearchData(dataInfo);
310
     incidentListSearchStore.setIncidentListSearchData(dataInfo);

+ 4 - 3
pages/inspection/inspectionExecute/inspectionExecute.vue

@@ -50,7 +50,7 @@
50
   import { ref, reactive, computed } from 'vue'
50
   import { ref, reactive, computed } from 'vue'
51
   import { onLoad, onPullDownRefresh, onReachBottom, onTabItemTap } from '@dcloudio/uni-app'
51
   import { onLoad, onPullDownRefresh, onReachBottom, onTabItemTap } from '@dcloudio/uni-app'
52
   import { SM } from "@/http/http.js"
52
   import { SM } from "@/http/http.js"
53
-  import { api_hsms_getDictionary, api_inspectionTask, api_listCount, api_scanCode } from "@/http/api.js"
53
+  import { api_getDictionary, api_inspectionTask, api_listCount, api_scanCode } from "@/http/api.js"
54
   import { filterFormatDate } from '@/filters/filterFormatDate.js'
54
   import { filterFormatDate } from '@/filters/filterFormatDate.js'
55
   import { computedPriorityStyle } from '@/filters/computedPriorityStyle.js'
55
   import { computedPriorityStyle } from '@/filters/computedPriorityStyle.js'
56
   import { computedStateStyle } from '@/filters/computedStateStyle.js'
56
   import { computedStateStyle } from '@/filters/computedStateStyle.js'
@@ -110,6 +110,7 @@
110
     });
110
     });
111
     // 'inspection|$|1bd0c704-0962-4ed4-b5a6-b5bda3d78231'
111
     // 'inspection|$|1bd0c704-0962-4ed4-b5a6-b5bda3d78231'
112
     // 'inspection|$|bc9f61af-99c8-4c86-88f9-f29dd3fc43c0'
112
     // 'inspection|$|bc9f61af-99c8-4c86-88f9-f29dd3fc43c0'
113
+		// 'inspection|$|92e7bb9a-5f58-42f6-991a-fcd67247e295'
113
     SM().then((ress1) => {
114
     SM().then((ress1) => {
114
       let postData = {
115
       let postData = {
115
         code: ress1,
116
         code: ress1,
@@ -141,12 +142,12 @@
141
       title: "加载中",
142
       title: "加载中",
142
       mask: true,
143
       mask: true,
143
     });
144
     });
144
-    api_hsms_getDictionary({
145
+    api_getDictionary({
145
       "type": "list",
146
       "type": "list",
146
       "key": "inspection_task_status"
147
       "key": "inspection_task_status"
147
     }).then(res => {
148
     }).then(res => {
148
       uni.hideLoading();
149
       uni.hideLoading();
149
-      let list = res.data || [];
150
+      let list = res || [];
150
       let todo = list.find(v => v.value === '1');
151
       let todo = list.find(v => v.value === '1');
151
       let close = list.find(v => v.value === '2');
152
       let close = list.find(v => v.value === '2');
152
       dataInfo.tabs = [{id: 0, name: '全部', value: 'all', num: ''}];
153
       dataInfo.tabs = [{id: 0, name: '全部', value: 'all', num: ''}];

+ 34 - 17
pages/repository/repository.vue

@@ -40,7 +40,7 @@
40
 <script setup>
40
 <script setup>
41
   import { ref, reactive} from 'vue'
41
   import { ref, reactive} from 'vue'
42
   import { onLoad, onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
42
   import { onLoad, onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
43
-  import { api_getSolution } from "@/http/api.js"
43
+  import { api_getSolution,api_getDictionary } from "@/http/api.js"
44
   import { useSetTitle } from '@/share/useSetTitle.js'
44
   import { useSetTitle } from '@/share/useSetTitle.js'
45
   import { useGoBack } from '@/share/useGoBack.js'
45
   import { useGoBack } from '@/share/useGoBack.js'
46
   import { useHandlerStore } from '@/stores/handler'
46
   import { useHandlerStore } from '@/stores/handler'
@@ -67,6 +67,9 @@
67
 	// 筛选状态
67
 	// 筛选状态
68
 	const isFilter = ref(null)
68
 	const isFilter = ref(null)
69
 	
69
 	
70
+	// 字典
71
+	const dicData = ref(null)
72
+	
70
   // 数据
73
   // 数据
71
   const dataInfo = reactive({
74
   const dataInfo = reactive({
72
     list: [],//工单列表
75
     list: [],//工单列表
@@ -79,7 +82,7 @@
79
   function toCategoryTwo(data){
82
   function toCategoryTwo(data){
80
     uni.navigateTo({
83
     uni.navigateTo({
81
       url: `/pages/repositoryDetails/repositoryDetails?incidentId=${dataInfo.incidentId}
84
       url: `/pages/repositoryDetails/repositoryDetails?incidentId=${dataInfo.incidentId}
82
-			&solutionnumber=${data.solutionnumber}&editType=${entrance.value}`
85
+			&solutionnumber=${data.solutionNumber}&editType=${entrance.value}`
83
     })
86
     })
84
   }
87
   }
85
 	
88
 	
@@ -113,7 +116,7 @@
113
 	function conformFilter(evtFilter){
116
 	function conformFilter(evtFilter){
114
 	  evtFilter.value = evtFilter;
117
 	  evtFilter.value = evtFilter;
115
 	  isFilter.value = false;
118
 	  isFilter.value = false;
116
-	  getList(0,evtFilter);
119
+	  getList(evtFilter);
117
 	}
120
 	}
118
 	
121
 	
119
 	// 关闭筛选
122
 	// 关闭筛选
@@ -122,32 +125,34 @@
122
 	}
125
 	}
123
 	
126
 	
124
   // 获取列表信息
127
   // 获取列表信息
125
-  function getList(idx,data){
128
+  function getList(data){
126
     uni.showLoading({
129
     uni.showLoading({
127
       title: "加载中",
130
       title: "加载中",
128
       mask: true,
131
       mask: true,
129
     });
132
     });
130
     
133
     
131
-    dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
132
     if(dataInfo.idx === 0){
134
     if(dataInfo.idx === 0){
133
       dataInfo.list = [];
135
       dataInfo.list = [];
134
     }
136
     }
135
 		let categoryId = entrance.value=='view' ? data && data.category : handlerStore.handler.data.category.id
137
 		let categoryId = entrance.value=='view' ? data && data.category : handlerStore.handler.data.category.id
136
     let postData = {
138
     let postData = {
137
-      idx: dataInfo.idx,
139
+      idx: 0,
138
       sum: 9999,
140
       sum: 9999,
139
       solution: {
141
       solution: {
140
-				category:{
141
-					id:'',
142
-				},
142
+				deleteFlag:0,
143
+				hosId: loginUserStore.loginUser.user.currentHospital.id,
144
+				// category:{
145
+				// 	id:'',
146
+				// },
147
+				categoryId:null,
143
 				title:'',
148
 				title:'',
144
-				status:{id:72},
149
+				status:{id:dicData.value.id},
145
       }
150
       }
146
     }
151
     }
147
     if(typeof(categoryId)=='number' || typeof(categoryId)=='string'){
152
     if(typeof(categoryId)=='number' || typeof(categoryId)=='string'){
148
-			postData.solution.category.id = categoryId
153
+			postData.solution.categoryId = categoryId
149
 		}else{
154
 		}else{
150
-			delete postData.solution.category.id
155
+			delete postData.solution.categoryId
151
 		}
156
 		}
152
 		if(data && data.title){
157
 		if(data && data.title){
153
 			postData.solution.title = data.title
158
 			postData.solution.title = data.title
@@ -159,10 +164,10 @@
159
 		}else if(loginUserStore.loginUser.user.branch){
164
 		}else if(loginUserStore.loginUser.user.branch){
160
 		  postData.solution.branch = loginUserStore.loginUser.user.branch.id;
165
 		  postData.solution.branch = loginUserStore.loginUser.user.branch.id;
161
 		}
166
 		}
162
-		if(entrance.value=='view'){
163
-			postData.solution.selectType = "keySearch"
164
-			postData.solution.tabType = "publish"
165
-		}
167
+		// if(entrance.value=='view'){
168
+		// 	postData.solution.selectType = "keySearch"
169
+		// 	postData.solution.tabType = "publish"
170
+		// }
166
     api_getSolution(postData).then(res => {
171
     api_getSolution(postData).then(res => {
167
       uni.hideLoading();
172
       uni.hideLoading();
168
       // uni.stopPullDownRefresh();
173
       // uni.stopPullDownRefresh();
@@ -185,10 +190,22 @@
185
     })
190
     })
186
   }
191
   }
187
   
192
   
193
+	// 获取字典
194
+	function getDic(){
195
+		let postData = {
196
+		  "key": 'solution_status',
197
+		  "type": "list",
198
+		};
199
+		api_getDictionary(postData).then(res => {
200
+		  dicData.value = res.find(v => v.value == '3');
201
+		  getList();
202
+		})
203
+	}
204
+	
188
   onLoad((option) => {
205
   onLoad((option) => {
189
     dataInfo.incidentId = option.incidentId;
206
     dataInfo.incidentId = option.incidentId;
190
 		entrance.value = option.type
207
 		entrance.value = option.type
191
-    getList(0);
208
+    getDic()
192
   })
209
   })
193
   
210
   
194
   onPullDownRefresh(() => {
211
   onPullDownRefresh(() => {

+ 15 - 7
pages/repositoryDetails/repositoryDetails.vue

@@ -3,10 +3,10 @@
3
     <view class="head">{{dataInfo.data.title}}</view>
3
     <view class="head">{{dataInfo.data.title}}</view>
4
     <view class="sign">
4
     <view class="sign">
5
 			<text>引入次数:{{dataInfo.data.introduceCount?dataInfo.data.introduceCount: 0}}</text>
5
 			<text>引入次数:{{dataInfo.data.introduceCount?dataInfo.data.introduceCount: 0}}</text>
6
-			<text>版本号:{{dataInfo.data.visionNumber}}</text>
7
-			<text>{{dataInfo.data.createtime}}</text>
6
+			<text>版本号:{{dataInfo.data.versionNumber}}</text>
7
+			<text>{{formatDate(dataInfo.data.createTime, 'yyyy-MM-dd HH:mm:ss')}}</text>
8
 		</view>
8
 		</view>
9
-		<view class="theme">{{mutiCategory}}</view>
9
+		<view class="theme" v-if="dataInfo.data.type">{{dataInfo.data.type.name}}</view>
10
 		<view class="content" v-html="dataInfo.data.content"></view>
10
 		<view class="content" v-html="dataInfo.data.content"></view>
11
 		<view class="file-list" v-for="item in dataInfo.fileData" :key="item">
11
 		<view class="file-list" v-for="item in dataInfo.fileData" :key="item">
12
 			<view class="file-item" @click="downloadFile(item)">{{item.name}}</view>
12
 			<view class="file-item" @click="downloadFile(item)">{{item.name}}</view>
@@ -29,11 +29,16 @@
29
   import { useSetTitle } from '@/share/useSetTitle.js'
29
   import { useSetTitle } from '@/share/useSetTitle.js'
30
   import { useGoBack } from '@/share/useGoBack.js'
30
   import { useGoBack } from '@/share/useGoBack.js'
31
   import { useHandlerStore } from '@/stores/handler'
31
   import { useHandlerStore } from '@/stores/handler'
32
+	import { useLoginUserStore } from '@/stores/loginUser'
33
+	import { filterFormatDate } from '@/filters/filterFormatDate.js'
32
 	
34
 	
33
   useSetTitle();
35
   useSetTitle();
36
+	const { formatDate }  = filterFormatDate();
34
 	
37
 	
35
 	const handlerStore = useHandlerStore();
38
 	const handlerStore = useHandlerStore();
36
 	
39
 	
40
+	const loginUserStore = useLoginUserStore();
41
+	
37
   const { goBack }  = useGoBack();
42
   const { goBack }  = useGoBack();
38
   
43
   
39
   // 故障类型
44
   // 故障类型
@@ -122,10 +127,13 @@
122
     });
127
     });
123
     
128
     
124
     let postData = {
129
     let postData = {
125
-      idx: dataInfo.idx,
126
-      sum: 20,
130
+      idx: 0,
131
+      sum: 999,
127
       solution: {
132
       solution: {
128
-        solutionnumber: dataInfo.solutionnumber,
133
+				deleteFlag:0,
134
+				hosId: loginUserStore.loginUser.user.currentHospital.id,
135
+				operationType: "lookOver",
136
+        solutionNumber: dataInfo.solutionnumber,
129
       }
137
       }
130
     }
138
     }
131
     
139
     
@@ -135,7 +143,7 @@
135
         let list = res.list || [];
143
         let list = res.list || [];
136
 				introduceCount.value = res.totalNum
144
 				introduceCount.value = res.totalNum
137
         dataInfo.data = list[0]
145
         dataInfo.data = list[0]
138
-				mutiCategory.value = list[0].category.mutiCategory
146
+				// mutiCategory.value = list[0].category.mutiCategory
139
 				getHandlerImgs('knowledge',list[0].id)
147
 				getHandlerImgs('knowledge',list[0].id)
140
       }else{
148
       }else{
141
         uni.showToast({
149
         uni.showToast({

+ 46 - 42
pages/searchArea/searchArea.vue

@@ -5,7 +5,7 @@
5
     </view>
5
     </view>
6
     <view class="body" v-if="dataInfo.list.length">
6
     <view class="body" v-if="dataInfo.list.length">
7
       <view class="body_item ellipsis" v-for="data in dataInfo.list" :key="data.id" @click="toPlace(data)">
7
       <view class="body_item ellipsis" v-for="data in dataInfo.list" :key="data.id" @click="toPlace(data)">
8
-        {{data.area}}
8
+        {{data.buildingName}}
9
       </view>
9
       </view>
10
     </view>
10
     </view>
11
     <view class="zanwu" v-else>
11
     <view class="zanwu" v-else>
@@ -20,7 +20,7 @@
20
 <script setup>
20
 <script setup>
21
   import { ref, reactive} from 'vue'
21
   import { ref, reactive} from 'vue'
22
   import { onLoad, onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
22
   import { onLoad, onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
23
-  import { api_area } from "@/http/api.js"
23
+  import { api_area, getFetchDataList } from "@/http/api.js"
24
   import { defaultColor } from '@/static/js/theme.js'
24
   import { defaultColor } from '@/static/js/theme.js'
25
   import { useSetTitle } from '@/share/useSetTitle.js'
25
   import { useSetTitle } from '@/share/useSetTitle.js'
26
   import { useLoginUserStore } from '@/stores/loginUser'
26
   import { useLoginUserStore } from '@/stores/loginUser'
@@ -46,55 +46,59 @@
46
   // 跳转地点列表
46
   // 跳转地点列表
47
   function toPlace(data){
47
   function toPlace(data){
48
     uni.navigateTo({
48
     uni.navigateTo({
49
-      url: `/pages/searchPlace/searchPlace?incidentId=${dataInfo.incidentId}&parentId=${data.id}&parentName=${data.area}`
49
+      url: `/pages/searchPlace/searchPlace?incidentId=${dataInfo.incidentId}&parentId=${data.id}&parentName=${data.buildingName}`
50
     })
50
     })
51
   }
51
   }
52
   
52
   
53
   // 获取列表信息
53
   // 获取列表信息
54
   function getList(idx){
54
   function getList(idx){
55
-    if(!incidentBuildStore.incidentBuild.data.branch){
56
-      dataInfo.list = [];
57
-      uni.stopPullDownRefresh();
58
-      dataInfo.hasMore = false;
59
-      return;
60
-    }
55
+    // if(!incidentBuildStore.incidentBuild.data.branch){
56
+    //   dataInfo.list = [];
57
+    //   uni.stopPullDownRefresh();
58
+    //   dataInfo.hasMore = false;
59
+    //   return;
60
+    // }
61
     uni.showLoading({
61
     uni.showLoading({
62
       title: "加载中",
62
       title: "加载中",
63
       mask: true,
63
       mask: true,
64
     });
64
     });
65
     
65
     
66
-    dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
67
-    if(dataInfo.idx === 0){
68
-      dataInfo.list = [];
69
-    }
66
+    // dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
67
+    // if(dataInfo.idx === 0){
68
+    //   dataInfo.list = [];
69
+    // }
70
 
70
 
71
     let postData = {
71
     let postData = {
72
-      "idx": 0,
73
-      "sum": 9999,
74
-      "area": {
75
-        "branch": incidentBuildStore.incidentBuild.data.branch,
76
-        "searchType": "quickStart",
77
-      }
72
+      idx: 0,
73
+      sum: 9999,
74
+			building:{
75
+				hosId: loginUserStore.loginUser.user.currentHospital.id,
76
+			}
78
     };
77
     };
78
+    getFetchDataList("simple/data", "building", postData)
79
+      .then((res) => {
80
+    		uni.hideLoading();
81
+        dataInfo.list = res.list
82
+      });
79
     
83
     
80
-    api_area(postData).then(res => {
81
-      uni.hideLoading();
82
-      uni.stopPullDownRefresh();
83
-      if(res.status == 200){
84
-        let list = res.list || [];
85
-        if(list.length){
86
-          dataInfo.hasMore = true;
87
-          dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
88
-        }else{
89
-          dataInfo.hasMore = false;
90
-        }
91
-      }else{
92
-        uni.showToast({
93
-          icon: 'none',
94
-          title: res.msg || '请求数据失败!'
95
-        });
96
-      }
97
-    })
84
+    // api_area(postData).then(res => {
85
+    //   uni.hideLoading();
86
+    //   uni.stopPullDownRefresh();
87
+    //   if(res.status == 200){
88
+    //     let list = res.list || [];
89
+    //     if(list.length){
90
+    //       dataInfo.hasMore = true;
91
+    //       dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
92
+    //     }else{
93
+    //       dataInfo.hasMore = false;
94
+    //     }
95
+    //   }else{
96
+    //     uni.showToast({
97
+    //       icon: 'none',
98
+    //       title: res.msg || '请求数据失败!'
99
+    //     });
100
+    //   }
101
+    // })
98
   }
102
   }
99
   
103
   
100
   onLoad((option) => {
104
   onLoad((option) => {
@@ -103,14 +107,14 @@
103
   })
107
   })
104
   
108
   
105
   onPullDownRefresh(() => {
109
   onPullDownRefresh(() => {
106
-    getList(0)
110
+    // getList(0)
107
   })
111
   })
108
   
112
   
109
   onReachBottom(() => {
113
   onReachBottom(() => {
110
-    dataInfo.idx += 1;
111
-    if (dataInfo.hasMore) {
112
-      getList(); // 当触底时加载更多数据
113
-    }
114
+    // dataInfo.idx += 1;
115
+    // if (dataInfo.hasMore) {
116
+    //   getList(); // 当触底时加载更多数据
117
+    // }
114
   })
118
   })
115
 </script>
119
 </script>
116
 
120
 

+ 4 - 3
pages/searchDept/searchDept.vue

@@ -73,9 +73,10 @@
73
       idx: dataInfo.idx,
73
       idx: dataInfo.idx,
74
       sum: 20,
74
       sum: 20,
75
       department: {
75
       department: {
76
-        branch: dataInfo.incidentData.branch,
77
-        searchType: 'quickStart',
78
-        selectType: 'pinyin_qs',
76
+				hospital:loginUserStore.loginUser.user.currentHospital.id,
77
+        // branch: dataInfo.incidentData.branch,
78
+        // searchType: 'quickStart',
79
+        // selectType: 'pinyin_qs',
79
         dept: dataInfo.keyWord,
80
         dept: dataInfo.keyWord,
80
       }
81
       }
81
     }
82
     }

+ 49 - 36
pages/searchPlace/searchPlace.vue

@@ -5,7 +5,7 @@
5
       <text class="two ellipsis">{{dataInfo.placeObj.place}}</text>
5
       <text class="two ellipsis">{{dataInfo.placeObj.place}}</text>
6
     </view>
6
     </view>
7
     <view class="body" v-if="dataInfo.list.length">
7
     <view class="body" v-if="dataInfo.list.length">
8
-      <uni-data-checkbox v-model="dataInfo.place" :localdata="dataInfo.list" mode="list" wrap icon="right" :map="{text:'place',value:'id'}" @change="selectItem"></uni-data-checkbox>
8
+      <uni-data-checkbox v-model="dataInfo.place" :localdata="dataInfo.list" mode="list" wrap icon="right" :map="{text:'floorName',value:'id'}" @change="selectItem"></uni-data-checkbox>
9
     </view>
9
     </view>
10
     <view class="zanwu" v-else>
10
     <view class="zanwu" v-else>
11
       <text class="newicon newicon-zanwu"></text>
11
       <text class="newicon newicon-zanwu"></text>
@@ -20,7 +20,7 @@
20
 <script setup>
20
 <script setup>
21
   import { ref, reactive} from 'vue'
21
   import { ref, reactive} from 'vue'
22
   import { onLoad, onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
22
   import { onLoad, onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
23
-  import { api_place } from "@/http/api.js"
23
+  import { api_place, getFetchDataList } from "@/http/api.js"
24
   import { defaultColor } from '@/static/js/theme.js'
24
   import { defaultColor } from '@/static/js/theme.js'
25
   import { useSetTitle } from '@/share/useSetTitle.js'
25
   import { useSetTitle } from '@/share/useSetTitle.js'
26
   import { useLoginUserStore } from '@/stores/loginUser'
26
   import { useLoginUserStore } from '@/stores/loginUser'
@@ -86,37 +86,50 @@
86
       mask: true,
86
       mask: true,
87
     });
87
     });
88
     
88
     
89
-    dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
90
-    if(dataInfo.idx === 0){
91
-      dataInfo.list = [];
92
-    }
89
+    // dataInfo.idx = idx === undefined ? dataInfo.idx : idx;
90
+    // if(dataInfo.idx === 0){
91
+    //   dataInfo.list = [];
92
+    // }
93
 
93
 
94
-    let postData = {
95
-      idx: dataInfo.idx,
96
-      sum: 20,
97
-      place: {
98
-        areaId: dataInfo.parentId,
99
-      }
100
-    }
94
+    // let postData = {
95
+    //   idx: dataInfo.idx,
96
+    //   sum: 20,
97
+    //   place: {
98
+    //     areaId: dataInfo.parentId,
99
+    //   }
100
+    // }
101
     
101
     
102
-    api_place(postData).then(res => {
103
-      uni.hideLoading();
104
-      uni.stopPullDownRefresh();
105
-      if(res.status == 200){
106
-        let list = res.list || [];
107
-        if(list.length){
108
-          dataInfo.hasMore = true;
109
-          dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
110
-        }else{
111
-          dataInfo.hasMore = false;
112
-        }
113
-      }else{
114
-        uni.showToast({
115
-          icon: 'none',
116
-          title: res.msg || '请求数据失败!'
117
-        });
118
-      }
119
-    })
102
+    // api_place(postData).then(res => {
103
+    //   uni.hideLoading();
104
+    //   uni.stopPullDownRefresh();
105
+    //   if(res.status == 200){
106
+    //     let list = res.list || [];
107
+    //     if(list.length){
108
+    //       dataInfo.hasMore = true;
109
+    //       dataInfo.list = dataInfo.idx === 0 ? list : dataInfo.list.concat(list);
110
+    //     }else{
111
+    //       dataInfo.hasMore = false;
112
+    //     }
113
+    //   }else{
114
+    //     uni.showToast({
115
+    //       icon: 'none',
116
+    //       title: res.msg || '请求数据失败!'
117
+    //     });
118
+    //   }
119
+    // })
120
+		let postData = {
121
+		  idx: 0,
122
+		  sum: 9999,
123
+			floor:{
124
+				hosId: loginUserStore.loginUser.user.currentHospital.id,
125
+				buildId:dataInfo.parentId
126
+			}
127
+		};
128
+		getFetchDataList("simple/data", "floor", postData)
129
+		  .then((res) => {
130
+				uni.hideLoading();
131
+		    dataInfo.list = res.list
132
+		  });
120
   }
133
   }
121
   
134
   
122
   onLoad((option) => {
135
   onLoad((option) => {
@@ -127,14 +140,14 @@
127
   })
140
   })
128
   
141
   
129
   onPullDownRefresh(() => {
142
   onPullDownRefresh(() => {
130
-    getList(0)
143
+    // getList(0)
131
   })
144
   })
132
   
145
   
133
   onReachBottom(() => {
146
   onReachBottom(() => {
134
-    dataInfo.idx += 1;
135
-    if (dataInfo.hasMore) {
136
-      getList(); // 当触底时加载更多数据
137
-    }
147
+    // dataInfo.idx += 1;
148
+    // if (dataInfo.hasMore) {
149
+    //   getList(); // 当触底时加载更多数据
150
+    // }
138
   })
151
   })
139
 </script>
152
 </script>
140
 
153
 

+ 20 - 5
pages/searchUser/searchUser.vue

@@ -21,7 +21,7 @@
21
   import { debounce } from 'lodash-es'
21
   import { debounce } from 'lodash-es'
22
   import { ref, reactive} from 'vue'
22
   import { ref, reactive} from 'vue'
23
   import { onLoad, onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
23
   import { onLoad, onPullDownRefresh, onReachBottom } from '@dcloudio/uni-app'
24
-  import { api_user } from "@/http/api.js"
24
+  import { api_user, api_getDictionary } from "@/http/api.js"
25
   import { defaultColor } from '@/static/js/theme.js'
25
   import { defaultColor } from '@/static/js/theme.js'
26
   import { useSetTitle } from '@/share/useSetTitle.js'
26
   import { useSetTitle } from '@/share/useSetTitle.js'
27
   import { useLoginUserStore } from '@/stores/loginUser'
27
   import { useLoginUserStore } from '@/stores/loginUser'
@@ -36,6 +36,8 @@
36
   // 主题颜色
36
   // 主题颜色
37
   const primaryColor = ref(defaultColor)
37
   const primaryColor = ref(defaultColor)
38
   
38
   
39
+	const userTypes = ref([])
40
+	
39
   // placeHolder
41
   // placeHolder
40
   const placeHolder = ref('');
42
   const placeHolder = ref('');
41
   
43
   
@@ -73,10 +75,12 @@
73
       idx: dataInfo.idx,
75
       idx: dataInfo.idx,
74
       sum: 20,
76
       sum: 20,
75
       user: {
77
       user: {
76
-        simple: true,
77
-        engineer: undefined,
78
-        selectType: "pinyin_all",
78
+        // simple: true,
79
+        // engineer: undefined,
80
+        // selectType: "pinyin_all",
81
+				hospital:loginUserStore.loginUser.user.currentHospital.id,
79
         name: dataInfo.keyWord,
82
         name: dataInfo.keyWord,
83
+				userTypeIds:String(userTypes.value.map(v => v.id))
80
       }
84
       }
81
     }
85
     }
82
     
86
     
@@ -109,6 +113,17 @@
109
     })
113
     })
110
   }
114
   }
111
   
115
   
116
+	function getUserType(){
117
+		let postData = {
118
+		  "key": 'usertype',
119
+		  "type": "list",
120
+		};
121
+		api_getDictionary(postData).then((data) => {
122
+		  userTypes.value = data;
123
+			getList(0);
124
+		});
125
+	}
126
+	
112
   onLoad((option) => {
127
   onLoad((option) => {
113
     if(incidentBuildStore.incidentBuild.data){
128
     if(incidentBuildStore.incidentBuild.data){
114
       dataInfo.incidentData = incidentBuildStore.incidentBuild.data;
129
       dataInfo.incidentData = incidentBuildStore.incidentBuild.data;
@@ -116,7 +131,7 @@
116
     if(incidentBuildStore.incidentBuild.type === 'buildIncident' && incidentBuildStore.incidentBuild.sign === 'requester'){
131
     if(incidentBuildStore.incidentBuild.type === 'buildIncident' && incidentBuildStore.incidentBuild.sign === 'requester'){
117
       placeHolder.value = '请搜索报修人'
132
       placeHolder.value = '请搜索报修人'
118
     }
133
     }
119
-    getList(0);
134
+		getUserType()
120
   })
135
   })
121
   
136
   
122
   onPullDownRefresh(() => {
137
   onPullDownRefresh(() => {

+ 1 - 1
share/useSetTabbar.js

@@ -18,7 +18,7 @@ export function useSetTabbar() {
18
         // 巡检
18
         // 巡检
19
 				if(loginUserStore.loginUser.user.engineer == 0){
19
 				if(loginUserStore.loginUser.user.engineer == 0){
20
 					flag = false;
20
 					flag = false;
21
-				}else if(loginUserStore.loginUser.menu.some(v => v.link === 'app.inspection.inspectList')){
21
+				}else if(loginUserStore.loginUser.menu.some(v => v.link === 'inspectionExecute')){
22
           flag = true;
22
           flag = true;
23
         }
23
         }
24
         break;
24
         break;