Ver código fonte

设备型号更新

XMLWAN 4 anos atrás
pai
commit
47489ce2aa

+ 269 - 225
src/api/manage.js Ver arquivo

@@ -1,19 +1,19 @@
1
-import request from '@/utils/request'
1
+import request from "@/utils/request";
2 2
 
3 3
 export function getAllSubregion(params) {
4 4
   return request({
5
-    url: '/api/management/getallsubregion',
6
-    method: 'Get',
5
+    url: "/api/management/getallsubregion",
6
+    method: "Get",
7 7
     params: params
8
-  })
8
+  });
9 9
 }
10 10
 
11 11
 export function SaveManageInfo(data) {
12 12
   return request({
13
-    url: '/api/management/savemanageinfo',
14
-    method: 'Post',
13
+    url: "/api/management/savemanageinfo",
14
+    method: "Post",
15 15
     data: data
16
-  })
16
+  });
17 17
 }
18 18
 
19 19
 export function getAllMachineInfo(
@@ -31,310 +31,314 @@ export function getAllMachineInfo(
31 31
     zoneid: zoneid,
32 32
     equipmentid: equipmentid,
33 33
     statusid: statusid
34
-  }
34
+  };
35 35
   return request({
36
-    url: '/api/management/getallmachineinfo',
37
-    method: 'Get',
36
+    url: "/api/management/getallmachineinfo",
37
+    method: "Get",
38 38
     params: params
39
-  })
39
+  });
40 40
 }
41 41
 
42
-export function getAllMachine(zoneid, classid, deviceid) {
42
+export function getAllMachine(zoneid, deviceid) {
43 43
   const params = {
44 44
     zoneid: zoneid,
45
-    classid: classid,
46 45
     deviceid: deviceid
47
-  }
46
+  };
48 47
   return request({
49
-    url: '/api/management/getallmachine',
50
-    method: 'Get',
48
+    url: "/api/management/getallmachine",
49
+    method: "Get",
51 50
     params: params
52
-  })
51
+  });
53 52
 }
54 53
 
55 54
 export function getMachineDetailById(id, params) {
56 55
   return request({
57
-    url: '/api/management/getmachinedetail?id=' + id,
58
-    method: 'Get',
56
+    url: "/api/management/getmachinedetail?id=" + id,
57
+    method: "Get",
59 58
     params: params
60
-  })
59
+  });
61 60
 }
62 61
 
63 62
 export function UpdateMachineInfo(data) {
63
+  console.log("data", data);
64 64
   return request({
65
-    url: '/api/management/updatemachineinfo',
66
-    method: 'Post',
65
+    url: "/api/management/updatemachineinfo",
66
+    method: "Post",
67 67
     data: data
68
-  })
68
+  });
69 69
 }
70 70
 
71 71
 export function UpdateMachineInfoTwo(data) {
72
-  console.log('data', data)
72
+  console.log("data", data);
73 73
   return request({
74
-    url: '/api/management/updatemachineinfotwo',
75
-    method: 'post',
74
+    url: "/api/management/updatemachineinfotwo",
75
+    method: "post",
76 76
     data: data
77
-  })
77
+  });
78 78
 }
79 79
 
80 80
 export function getAllEquimentName(params) {
81 81
   return request({
82
-    url: '/api/management/getallequimentname',
83
-    method: 'Get',
82
+    url: "/api/management/getallequimentname",
83
+    method: "Get",
84 84
     params: params
85
-  })
85
+  });
86 86
 }
87 87
 
88 88
 export function savePlan(data, id) {
89 89
   return request({
90
-    url: '/api/management/saveplan?id=' + id,
91
-    method: 'Post',
90
+    url: "/api/management/saveplan?id=" + id,
91
+    method: "Post",
92 92
     data: data
93
-  })
93
+  });
94 94
 }
95 95
 
96
-export function getAllPlan(params) {
96
+export function getAllPlan(bedid) {
97
+  const params = {
98
+    bedid: bedid
99
+  };
97 100
   return request({
98
-    url: '/api/management/getallplan',
99
-    method: 'Get',
101
+    url: "/api/management/getallplan",
102
+    method: "Get",
100 103
     params: params
101
-  })
104
+  });
102 105
 }
103 106
 
104
-export function getAllPlanDetail(unitype) {
107
+export function getAllPlanDetail(unitype, bedid) {
105 108
   // eslint-disable-next-line no-redeclare
106 109
   const params = {
107
-    unitype: unitype
108
-  }
110
+    unitype: unitype,
111
+    bedid: bedid
112
+  };
109 113
   return request({
110
-    url: '/api/management/getallplandetail',
111
-    method: 'Get',
114
+    url: "/api/management/getallplandetail",
115
+    method: "Get",
112 116
     params: params
113
-  })
117
+  });
114 118
 }
115 119
 
116 120
 export function getEditMachine(id, params) {
117 121
   return request({
118
-    url: '/api/management/geteditmachine?id=' + id,
119
-    method: 'Get',
122
+    url: "/api/management/geteditmachine?id=" + id,
123
+    method: "Get",
120 124
     params: params
121
-  })
125
+  });
122 126
 }
123 127
 
124 128
 export function DeletePlans(data) {
125 129
   return request({
126
-    url: '/api/staff/deleteplans',
127
-    method: 'delete',
130
+    url: "/api/staff/deleteplans",
131
+    method: "delete",
128 132
     data: data
129
-  })
133
+  });
130 134
 }
131 135
 
132 136
 export function EditPlanDetail(id, params) {
133 137
   return request({
134
-    url: '/api/manage/editplandetail?id=' + id,
135
-    method: 'get',
138
+    url: "/api/manage/editplandetail?id=" + id,
139
+    method: "get",
136 140
     params: params
137
-  })
141
+  });
138 142
 }
139 143
 
140 144
 export function UpdatePlanInfo(data) {
141 145
   return request({
142
-    url: '/api/manage/updateplaninfo',
143
-    method: 'Post',
146
+    url: "/api/manage/updateplaninfo",
147
+    method: "Post",
144 148
     data: data
145
-  })
149
+  });
146 150
 }
147 151
 
148 152
 export function getComprehensive(params) {
149 153
   return request({
150
-    url: '/api/manage/getcomprehensive',
151
-    method: 'Get',
154
+    url: "/api/manage/getcomprehensive",
155
+    method: "Get",
152 156
     params: params
153
-  })
157
+  });
154 158
 }
155 159
 
156 160
 export function SaveInformation(eid, data) {
157 161
   return request({
158
-    url: '/api/manage/saveinformation?eid=' + eid,
159
-    method: 'Post',
162
+    url: "/api/manage/saveinformation?eid=" + eid,
163
+    method: "Post",
160 164
     data: data
161
-  })
165
+  });
162 166
 }
163 167
 
164 168
 export function getPatientInfo(id, params) {
165 169
   return request({
166
-    url: '/api/manage/getpatientinfo?id=' + id,
167
-    method: 'Get',
170
+    url: "/api/manage/getpatientinfo?id=" + id,
171
+    method: "Get",
168 172
     params: params
169
-  })
173
+  });
170 174
 }
171 175
 
172 176
 export function ChangeClass(equitid, id) {
173 177
   const params = {
174 178
     equitid: equitid,
175 179
     id: id
176
-  }
180
+  };
177 181
   return request({
178
-    url: '/api/manage/changeclass',
179
-    method: 'Get',
182
+    url: "/api/manage/changeclass",
183
+    method: "Get",
180 184
     params: params
181
-  })
185
+  });
182 186
 }
183 187
 
184 188
 export function changePatient(equitid, id) {
185 189
   const params = {
186 190
     equitid: equitid,
187 191
     id: id
188
-  }
192
+  };
189 193
   return request({
190
-    url: '/api/manage/changepatient',
191
-    method: 'Get',
194
+    url: "/api/manage/changepatient",
195
+    method: "Get",
192 196
     params: params
193
-  })
197
+  });
194 198
 }
195 199
 
196 200
 export function getAllOrganization(params) {
197 201
   return request({
198
-    url: '/api/manage/getallorganization',
199
-    method: 'Get',
202
+    url: "/api/manage/getallorganization",
203
+    method: "Get",
200 204
     params: params
201
-  })
205
+  });
202 206
 }
203 207
 
204 208
 export function getUserRegister(id, params) {
205 209
   return request({
206
-    url: '/api/manage/getregisterinfo?id=' + id,
207
-    method: 'Get',
210
+    url: "/api/manage/getregisterinfo?id=" + id,
211
+    method: "Get",
208 212
     params: params
209
-  })
213
+  });
210 214
 }
211 215
 
212 216
 export function getInformationData(limit, page) {
213 217
   const params = {
214 218
     limit: limit,
215 219
     page: page
216
-  }
220
+  };
217 221
   return request({
218
-    url: '/api/manage/getinformationdata',
219
-    method: 'Get',
222
+    url: "/api/manage/getinformationdata",
223
+    method: "Get",
220 224
     params: params
221
-  })
225
+  });
222 226
 }
223 227
 
224 228
 export function SaveBacteria(id, data) {
225 229
   return request({
226
-    url: '/api/manage/savebacteria?id=' + id,
227
-    method: 'Post',
230
+    url: "/api/manage/savebacteria?id=" + id,
231
+    method: "Post",
228 232
     data: data
229
-  })
233
+  });
230 234
 }
231 235
 
232 236
 export function SaveLincomycin(id, data) {
233 237
   return request({
234
-    url: '/api/manage/savelincomycin?id=' + id,
235
-    method: 'Post',
238
+    url: "/api/manage/savelincomycin?id=" + id,
239
+    method: "Post",
236 240
     data: data
237
-  })
241
+  });
238 242
 }
239 243
 
240 244
 export function SaveQualityControl(id, data) {
241 245
   return request({
242
-    url: '/api/manage/savequalitycontrol?id=' + id,
243
-    method: 'Post',
246
+    url: "/api/manage/savequalitycontrol?id=" + id,
247
+    method: "Post",
244 248
     data: data
245
-  })
249
+  });
246 250
 }
247 251
 
248 252
 export function getOrgName(params) {
249 253
   return request({
250
-    url: '/api/manage/getorgname',
251
-    method: 'Get',
254
+    url: "/api/manage/getorgname",
255
+    method: "Get",
252 256
     params: params
253
-  })
257
+  });
254 258
 }
255 259
 
256 260
 export function getAllQulityInfo(params) {
257 261
   return request({
258
-    url: '/api/manage/getallqulityinfo',
259
-    method: 'Get',
262
+    url: "/api/manage/getallqulityinfo",
263
+    method: "Get",
260 264
     params: params
261
-  })
265
+  });
262 266
 }
263 267
 
264 268
 export function EditCulture(id, userid) {
265 269
   const params = {
266 270
     id: id,
267 271
     userid: userid
268
-  }
272
+  };
269 273
   return request({
270
-    url: '/api/manage/editculture',
271
-    method: 'Get',
274
+    url: "/api/manage/editculture",
275
+    method: "Get",
272 276
     params: params
273
-  })
277
+  });
274 278
 }
275 279
 
276 280
 export function UpdateCulture(data) {
277 281
   return request({
278
-    url: '/api/manage/updateculture',
279
-    method: 'Post',
282
+    url: "/api/manage/updateculture",
283
+    method: "Post",
280 284
     data: data
281
-  })
285
+  });
282 286
 }
283 287
 
284 288
 export function DeleteCultrue(data) {
285 289
   return request({
286
-    url: '/api/manage/deletecultrue',
287
-    method: 'delete',
290
+    url: "/api/manage/deletecultrue",
291
+    method: "delete",
288 292
     data: data
289
-  })
293
+  });
290 294
 }
291 295
 
292 296
 export function EditDialyState(id, params) {
293 297
   return request({
294
-    url: '/api/manage/editdialystate?id=' + id,
295
-    method: 'Get',
298
+    url: "/api/manage/editdialystate?id=" + id,
299
+    method: "Get",
296 300
     params: params
297
-  })
301
+  });
298 302
 }
299 303
 
300 304
 export function UpdateDialyState(data) {
301 305
   return request({
302
-    url: '/api/manage/updatedialystate',
303
-    method: 'post',
306
+    url: "/api/manage/updatedialystate",
307
+    method: "post",
304 308
     data: data
305
-  })
309
+  });
306 310
 }
307 311
 
308 312
 export function DeleteDialystate(data) {
309 313
   return request({
310
-    url: '/api/manage/deletedialystate',
311
-    method: 'delete',
314
+    url: "/api/manage/deletedialystate",
315
+    method: "delete",
312 316
     data: data
313
-  })
317
+  });
314 318
 }
315 319
 
316 320
 export function EditIon(id, params) {
317 321
   return request({
318
-    url: '/api/manage/edition?id=' + id,
319
-    method: 'Get',
322
+    url: "/api/manage/edition?id=" + id,
323
+    method: "Get",
320 324
     params: params
321
-  })
325
+  });
322 326
 }
323 327
 
324 328
 export function UpdateIon(data) {
325 329
   return request({
326
-    url: '/api/manage/updateion',
327
-    method: 'Post',
330
+    url: "/api/manage/updateion",
331
+    method: "Post",
328 332
     data: data
329
-  })
333
+  });
330 334
 }
331 335
 
332 336
 export function DeleteIon(data) {
333 337
   return request({
334
-    url: '/api/manage/deleteion',
335
-    method: 'delete',
338
+    url: "/api/manage/deleteion",
339
+    method: "delete",
336 340
     data: data
337
-  })
341
+  });
338 342
 }
339 343
 
340 344
 export function queryTable(bedid, startime, endtime) {
@@ -342,56 +346,56 @@ export function queryTable(bedid, startime, endtime) {
342 346
     bedid: bedid,
343 347
     startime: startime,
344 348
     endtime: endtime
345
-  }
349
+  };
346 350
   return request({
347
-    url: '/api/manage/query',
348
-    method: 'Get',
351
+    url: "/api/manage/query",
352
+    method: "Get",
349 353
     params: params
350
-  })
354
+  });
351 355
 }
352 356
 
353 357
 export function SaveRepair(id, data) {
354 358
   return request({
355
-    url: '/api/manage/saverepair?id=' + id,
356
-    method: 'post',
359
+    url: "/api/manage/saverepair?id=" + id,
360
+    method: "post",
357 361
     data: data
358
-  })
362
+  });
359 363
 }
360 364
 
361 365
 export function getAllRepair(limit, page) {
362 366
   const params = {
363 367
     limit: limit,
364 368
     page: page
365
-  }
369
+  };
366 370
   return request({
367
-    url: '/api/manage/getallrepair',
368
-    method: 'Get',
371
+    url: "/api/manage/getallrepair",
372
+    method: "Get",
369 373
     params: params
370
-  })
374
+  });
371 375
 }
372 376
 
373 377
 export function EditRepair(id, params) {
374 378
   return request({
375
-    url: '/api/manage/editrepair?id=' + id,
376
-    method: 'Get',
379
+    url: "/api/manage/editrepair?id=" + id,
380
+    method: "Get",
377 381
     params: params
378
-  })
382
+  });
379 383
 }
380 384
 
381 385
 export function UpdateRepair(data) {
382 386
   return request({
383
-    url: '/api/manage/updaterepair',
384
-    method: 'Post',
387
+    url: "/api/manage/updaterepair",
388
+    method: "Post",
385 389
     data: data
386
-  })
390
+  });
387 391
 }
388 392
 
389 393
 export function DeleteRepair(data) {
390 394
   return request({
391
-    url: '/api/manage/deleterepair',
392
-    method: 'delete',
395
+    url: "/api/manage/deleterepair",
396
+    method: "delete",
393 397
     data: data
394
-  })
398
+  });
395 399
 }
396 400
 
397 401
 export function queryRepair(bedid, startime, endtime) {
@@ -399,41 +403,41 @@ export function queryRepair(bedid, startime, endtime) {
399 403
     bedid: bedid,
400 404
     startime: startime,
401 405
     endtime: endtime
402
-  }
406
+  };
403 407
 
404 408
   return request({
405
-    url: '/api/manage/queryrepair',
406
-    method: 'Get',
409
+    url: "/api/manage/queryrepair",
410
+    method: "Get",
407 411
     params: params
408
-  })
412
+  });
409 413
 }
410 414
 
411 415
 export function EditUser(id, patientid) {
412 416
   const params = {
413 417
     id: id,
414 418
     patientid: patientid
415
-  }
419
+  };
416 420
   return request({
417
-    url: '/api/manage/edituser',
418
-    method: 'Get',
421
+    url: "/api/manage/edituser",
422
+    method: "Get",
419 423
     params: params
420
-  })
424
+  });
421 425
 }
422 426
 
423 427
 export function DeleteUserform(data) {
424 428
   return request({
425
-    url: '/api/manage/deleteform',
426
-    method: 'delete',
429
+    url: "/api/manage/deleteform",
430
+    method: "delete",
427 431
     data: data
428
-  })
432
+  });
429 433
 }
430 434
 
431 435
 export function UpdateForm(data) {
432 436
   return request({
433
-    url: '/api/manage/updateform',
434
-    method: 'post',
437
+    url: "/api/manage/updateform",
438
+    method: "post",
435 439
     data: data
436
-  })
440
+  });
437 441
 }
438 442
 
439 443
 export function queryInfo(zone, bed, startime, endtime, limit, page) {
@@ -444,28 +448,28 @@ export function queryInfo(zone, bed, startime, endtime, limit, page) {
444 448
     endtime: endtime,
445 449
     limit: limit,
446 450
     page: page
447
-  }
451
+  };
448 452
   return request({
449
-    url: '/api/manage/queryinfo',
450
-    method: 'Get',
453
+    url: "/api/manage/queryinfo",
454
+    method: "Get",
451 455
     params: params
452
-  })
456
+  });
453 457
 }
454 458
 
455 459
 export function getAutoData(id, params) {
456 460
   return request({
457
-    url: '/api/manage/insertautodata?id=' + id,
458
-    method: 'Get',
461
+    url: "/api/manage/insertautodata?id=" + id,
462
+    method: "Get",
459 463
     params: params
460
-  })
464
+  });
461 465
 }
462 466
 
463 467
 export function getAllEquitType(params) {
464 468
   return request({
465
-    url: '/api/manage/getallequittype',
466
-    method: 'Get',
469
+    url: "/api/manage/getallequittype",
470
+    method: "Get",
467 471
     params: params
468
-  })
472
+  });
469 473
 }
470 474
 
471 475
 export function getUserForm(id, limit, page) {
@@ -473,147 +477,187 @@ export function getUserForm(id, limit, page) {
473 477
     id: id,
474 478
     limit: limit,
475 479
     page: page
476
-  }
480
+  };
477 481
   return request({
478
-    url: '/api/manage/getuserform',
479
-    method: 'Get',
482
+    url: "/api/manage/getuserform",
483
+    method: "Get",
480 484
     params: params
481
-  })
485
+  });
482 486
 }
483 487
 
484 488
 export function UpdateMacheineTwo(data) {
485 489
   return request({
486
-    url: '/api/manage/updatemacheinettwo',
487
-    method: 'post',
490
+    url: "/api/manage/updatemacheinettwo",
491
+    method: "post",
488 492
     data: data
489
-  })
493
+  });
490 494
 }
491 495
 
492 496
 export function getBedForm(id, params) {
493 497
   return request({
494
-    url: '/api/manage/getbedform?id=' + id,
495
-    method: 'get',
498
+    url: "/api/manage/getbedform?id=" + id,
499
+    method: "get",
496 500
     params: params
497
-  })
501
+  });
498 502
 }
499 503
 
500 504
 export function getTotalCount(params) {
501 505
   return request({
502
-    url: '/api/manage/gettotalcount',
503
-    method: 'Get',
506
+    url: "/api/manage/gettotalcount",
507
+    method: "Get",
504 508
     params: params
505
-  })
509
+  });
506 510
 }
507 511
 
508 512
 export function getTotalNumber(id, params) {
509 513
   return request({
510
-    url: '/api/manage/getotalnumber?id=' + id,
511
-    method: 'Get',
514
+    url: "/api/manage/getotalnumber?id=" + id,
515
+    method: "Get",
512 516
     params: params
513
-  })
517
+  });
514 518
 }
515 519
 
516 520
 export function getTimeWarning(id, params) {
517 521
   return request({
518
-    url: '/api/manage/gettimewarning?id=' + id,
519
-    method: 'Get',
522
+    url: "/api/manage/gettimewarning?id=" + id,
523
+    method: "Get",
520 524
     params: params
521
-  })
525
+  });
522 526
 }
523 527
 
524 528
 export function SaveManageInfoTwo(data, beds) {
525
-  console.log('data', beds)
529
+  console.log("data", beds);
526 530
   return request({
527
-    url: '/api/manage/savemanageinfotwo?beds=' + beds,
528
-    method: 'post',
531
+    url: "/api/manage/savemanageinfotwo?beds=" + beds,
532
+    method: "post",
529 533
     data: data
530
-  })
534
+  });
531 535
 }
532 536
 
533 537
 export function getAllpatient(params) {
534 538
   return request({
535
-    url: '/api/manage/getallpatient',
536
-    method: 'get',
539
+    url: "/api/manage/getallpatient",
540
+    method: "get",
537 541
     params: params
538
-  })
542
+  });
539 543
 }
540 544
 
541 545
 export function changeBed(id, params) {
542 546
   return request({
543
-    url: '/api/manage/changebed?id=' + id,
544
-    method: 'get',
547
+    url: "/api/manage/changebed?id=" + id,
548
+    method: "get",
545 549
     params: params
546
-  })
550
+  });
547 551
 }
548 552
 
549 553
 export function getPatientDetail(id, params) {
550 554
   return request({
551
-    url: '/api/manage/getpatientdetail?id=' + id,
552
-    method: 'get',
555
+    url: "/api/manage/getpatientdetail?id=" + id,
556
+    method: "get",
553 557
     params: params
554
-  })
558
+  });
555 559
 }
556 560
 
557 561
 export function changeRun(id, data) {
558 562
   return request({
559
-    url: '/api/manage/changrun?id=' + id,
560
-    method: 'post',
563
+    url: "/api/manage/changrun?id=" + id,
564
+    method: "post",
561 565
     data: data
562
-  })
566
+  });
563 567
 }
564 568
 
565 569
 export function getRemanderData(params) {
566 570
   return request({
567
-    url: '/api/manage/getremanderdata',
568
-    method: 'get',
571
+    url: "/api/manage/getremanderdata",
572
+    method: "get",
569 573
     params: params
570
-  })
574
+  });
571 575
 }
572 576
 
573 577
 export function openDelete(id, params) {
574 578
   return request({
575
-    url: '/api/manage/opendelete?id=' + id,
576
-    method: 'delete',
579
+    url: "/api/manage/opendelete?id=" + id,
580
+    method: "delete",
577 581
     params: params
578
-  })
582
+  });
579 583
 }
580 584
 
581 585
 export function DeleteUserLogin(id, params) {
582 586
   return request({
583
-    url: '/api/manage/deleteuserlogin?id=' + id,
584
-    method: 'delete',
587
+    url: "/api/manage/deleteuserlogin?id=" + id,
588
+    method: "delete",
585 589
     params: params
586
-  })
590
+  });
587 591
 }
588 592
 
589 593
 export function DeleteCultrues(id, params) {
590 594
   return request({
591
-    url: '/api/manage/deletecultrues?id=' + id,
592
-    method: 'delete',
595
+    url: "/api/manage/deletecultrues?id=" + id,
596
+    method: "delete",
593 597
     params: params
594
-  })
598
+  });
595 599
 }
596 600
 
597 601
 export function DeleteDialystates(id, params) {
598 602
   return request({
599
-    url: '/api/manage/deletedialystates?id=' + id,
600
-    method: 'delete',
603
+    url: "/api/manage/deletedialystates?id=" + id,
604
+    method: "delete",
601 605
     params: params
602
-  })
606
+  });
603 607
 }
604 608
 
605 609
 export function DeleteIons(id, params) {
606 610
   return request({
607
-    url: '/api/manage/deleteions?id=' + id,
608
-    method: 'delete',
611
+    url: "/api/manage/deleteions?id=" + id,
612
+    method: "delete",
609 613
     params: params
610
-  })
614
+  });
611 615
 }
612 616
 
613 617
 export function DeleteRepairs(id, params) {
614 618
   return request({
615
-    url: '/api/manage/deleterepairs?id=' + id,
616
-    method: 'delete',
619
+    url: "/api/manage/deleterepairs?id=" + id,
620
+    method: "delete",
621
+    params: params
622
+  });
623
+}
624
+
625
+export function SaveMode(data) {
626
+  return request({
627
+    url: "/api/manage/savemode",
628
+    method: "post",
629
+    data: data
630
+  });
631
+}
632
+
633
+export function getAllMode(params) {
634
+  return request({
635
+    url: "/api/manage/getallmode",
636
+    method: "get",
637
+    params: params
638
+  });
639
+}
640
+
641
+export function EditMode(id, params) {
642
+  return request({
643
+    url: "/api/manage/editmode?id=" + id,
644
+    method: "get",
645
+    params: params
646
+  });
647
+}
648
+
649
+export function UpdateMode(id, data) {
650
+  return request({
651
+    url: "/api/manage/updatemode?id=" + id,
652
+    method: "post",
653
+    data: data
654
+  });
655
+}
656
+
657
+export function DeleteMode(id, params) {
658
+  return request({
659
+    url: "/api/manage/deletemode?id=" + id,
660
+    method: "delete",
617 661
     params: params
618
-  })
662
+  });
619 663
 }

+ 1 - 0
src/lang/zh.js Ver arquivo

@@ -94,6 +94,7 @@ export default {
94 94
     dryWeight: '干体重',
95 95
     device: '设备',
96 96
     deviceManage: '设备管理',
97
+    modemanagement:'型号管理',
97 98
     dialysisMachineManage: '设备管理',
98 99
     workforce: '排班管理',
99 100
     appointment: '排班管理',

+ 39 - 29
src/router/modules/device.js Ver arquivo

@@ -1,59 +1,69 @@
1
-import Layout from "@/views/layout/Layout";
2
-import { S_IFMT } from "constants";
1
+import Layout from '@/views/layout/Layout'
2
+import {
3
+  S_IFMT
4
+} from 'constants'
3 5
 
4 6
 export default {
5
-  path: "/device",
7
+  path: '/device',
6 8
   component: Layout,
7
-  redirect: "/device/main",
8
-  name: "device",
9
+  redirect: '/device/main',
10
+  name: 'device',
9 11
   alwaysShow: true,
10 12
   meta: {
11
-    title: "deviceManage",
12
-    icon: "shebei"
13
+    title: 'deviceManage',
14
+    icon: 'shebei'
13 15
   },
14
-  children: [
16
+  children: [{
17
+      path: '/device/zones',
18
+      component: () => import('@/xt_pages/device/zone_main'),
19
+      name: 'deviceZoneManage',
20
+      meta: {
21
+        title: 'deviceZoneManage'
22
+      }
23
+    },
15 24
     {
16
-      path: "/device/zones",
17
-      component: () => import("@/xt_pages/device/zone_main"),
18
-      name: "deviceZoneManage",
25
+      path: '/device/groups',
26
+      component: () => import('@/xt_pages/device/group_main'),
27
+      name: 'deviceGroupManage',
19 28
       meta: {
20
-        title: "deviceZoneManage"
29
+        title: 'deviceGroupManage'
21 30
       }
22 31
     },
23 32
     {
24
-      path: "/device/groups",
25
-      component: () => import("@/xt_pages/device/group_main"),
26
-      name: "deviceGroupManage",
33
+      path: '/device/numbers',
34
+      component: () => import('@/xt_pages/device/number_main'),
35
+      name: 'deviceNumberManage',
27 36
       meta: {
28
-        title: "deviceGroupManage"
37
+        title: 'deviceNumberManage'
29 38
       }
30 39
     },
31 40
     {
32
-      path: "/device/numbers",
33
-      component: () => import("@/xt_pages/device/number_main"),
34
-      name: "deviceNumberManage",
41
+      path: '/device/mode',
42
+      component: () => import('@/xt_pages/mode/index'),
43
+      name: 'modemanagement',
35 44
       meta: {
36
-        title: "deviceNumberManage"
45
+        title: 'modemanagement'
37 46
       }
38 47
     },
39 48
     {
40
-      path: "/device/main",
41
-      component: () => import("@/xt_pages/management/index"),
49
+      path: '/device/main',
50
+      component: () => import('@/xt_pages/management/index'),
42 51
       // component: () => import("@/xt_pages/device/main"),
43
-      name: "dialysisMachineManage",
52
+      name: 'dialysisMachineManage',
44 53
       meta: {
45
-        title: "dialysisMachineManage"
54
+        title: 'dialysisMachineManage'
46 55
       }
47 56
     },
48 57
     {
49
-      path: "/device/home",
50
-      component: () => import("@/xt_pages/management/home"),
51
-      name: "managementHome",
58
+      path: '/device/home',
59
+      component: () => import('@/xt_pages/management/home'),
60
+      name: 'managementHome',
52 61
       is_menu: false,
53 62
       hidden: true,
54 63
       meta: {
55
-        title: "设备管理详情页"
64
+        title: '设备管理详情页'
56 65
       }
57 66
     }
67
+
58 68
   ]
59
-};
69
+}

+ 37 - 12
src/xt_pages/management/components/ManageForm.vue Ver arquivo

@@ -38,7 +38,7 @@
38 38
             <el-form-item
39 39
               label="机位号:"
40 40
               v-show="bedShow"
41
-              required 
41
+              required
42 42
               prop="bed_number"
43 43
             >
44 44
               <el-select style="width:135px" v-model="form.bed_number">
@@ -52,10 +52,7 @@
52 52
             </el-form-item>
53 53
 
54 54
             <el-form-item label="机位号:" v-show="bedShowTwo">
55
-              <el-input
56
-                v-model="forms.beds"
57
-                style="width:135px"
58
-              ></el-input>
55
+              <el-input v-model="forms.beds" style="width:135px"></el-input>
59 56
             </el-form-item>
60 57
           </el-col>
61 58
         </el-row>
@@ -88,7 +85,14 @@
88 85
         <el-row>
89 86
           <el-col :span="8">
90 87
             <el-form-item label="设备型号:" required prop="unit_type">
91
-              <el-input style="width:135px" v-model="form.unit_type"></el-input>
88
+              <el-select style="width:135px" v-model="form.unit_type">
89
+                <el-option
90
+                  v-for="item in this.deviceMode"
91
+                  :key="item.id"
92
+                  :label="item.device_mode"
93
+                  :value="item.id"
94
+                ></el-option>
95
+              </el-select>
92 96
             </el-form-item>
93 97
           </el-col>
94 98
           <el-col :span="8">
@@ -308,20 +312,33 @@
308 312
       </el-form>
309 313
       <span slot="footer" class="dialog-footer">
310 314
         <el-button @click="dialogVisible = false">取 消</el-button>
311
-        <el-button type="primary" @click="SaveManageInfo('form')" v-show="buttonShow"
315
+        <el-button
316
+          type="primary"
317
+          @click="SaveManageInfo('form')"
318
+          v-show="buttonShow"
319
+          >保存</el-button
320
+        >
321
+        <el-button
322
+          type="primary"
323
+          @click="SaveManageInfoTwo('form')"
324
+          v-show="buttonShowTwo"
312 325
           >保存</el-button
313 326
         >
314
-         <el-button type="primary" @click="SaveManageInfoTwo('form')" v-show="buttonShowTwo"
327
+        <el-button @click="SaveManageInfoThree('form')" v-show="buttonShowThree"
315 328
           >保存</el-button
316 329
         >
317
-        <el-button @click="SaveManageInfoThree('form')" v-show="buttonShowThree">保存</el-button>
318 330
       </span>
319 331
     </el-dialog>
320 332
   </div>
321 333
 </template>
322 334
 
323 335
 <script>
324
-import { getAllSubregion, SaveManageInfo, SaveManageInfoTwo } from '@/api/manage'
336
+import {
337
+  getAllSubregion,
338
+  SaveManageInfo,
339
+  SaveManageInfoTwo,
340
+  getAllMode
341
+} from '@/api/manage'
325 342
 const treatmentmodes = [
326 343
   'HD',
327 344
   'HDF',
@@ -432,7 +449,8 @@ export default {
432 449
       disa: true,
433 450
       buttonShow: true,
434 451
       buttonShowTwo: false,
435
-      buttonShowThree: false
452
+      buttonShowThree: false,
453
+      deviceMode: []
436 454
     }
437 455
   },
438 456
   methods: {
@@ -799,17 +817,24 @@ export default {
799 817
           })
800 818
         }
801 819
       })
820
+    },
821
+    getAllMode() {
822
+      getAllMode().then(response => {
823
+        var mode = response.data.data.mode
824
+        this.deviceMode = mode
825
+        console.log('mode', mode)
826
+      })
802 827
     }
803 828
   },
804 829
   created() {
805 830
     this.getAllSubregion()
831
+    this.getAllMode()
806 832
   }
807 833
 }
808 834
 </script>
809 835
 
810 836
 <style lang="scss">
811 837
 .el-form-item__label {
812
-  width: 100px;
813 838
   font-size: 14px;
814 839
 }
815 840
 // .el-form-item {

+ 76 - 79
src/xt_pages/management/components/PlanForm.vue Ver arquivo

@@ -14,7 +14,7 @@
14 14
                 <el-option
15 15
                   v-for="item in this.DeviceType"
16 16
                   :key="item.id"
17
-                  :label="item.equitment_name"
17
+                  :label="item.device_mode"
18 18
                   :value="item.id"
19 19
                 ></el-option>
20 20
               </el-select>
@@ -137,9 +137,9 @@
137 137
 </template>
138 138
 
139 139
 <script>
140
-import { getAllEquimentName, savePlan, getAllEquitType } from '@/api/manage'
140
+import { getAllEquimentName, savePlan, getAllEquitType } from "@/api/manage";
141 141
 export default {
142
-  name: 'PlanForm',
142
+  name: "PlanForm",
143 143
   props: {
144 144
     equimentid: Number
145 145
   },
@@ -147,8 +147,8 @@ export default {
147 147
     return {
148 148
       dialogVisible: false,
149 149
       form: {
150
-        device_type: '',
151
-        disinfec_time: '',
150
+        device_type: "",
151
+        disinfec_time: "",
152 152
         time: [],
153 153
         class_time: [],
154 154
         way: 0,
@@ -158,130 +158,127 @@ export default {
158 158
       },
159 159
       value: [],
160 160
       timeType: [
161
-        { id: 1, name: '周一' },
162
-        { id: 2, name: '周二' },
163
-        { id: 3, name: '周三' },
164
-        { id: 4, name: '周四' },
165
-        { id: 5, name: '周五' },
166
-        { id: 6, name: '周六' },
167
-        { id: 7, name: '周日' }
161
+        { id: 1, name: "周一" },
162
+        { id: 2, name: "周二" },
163
+        { id: 3, name: "周三" },
164
+        { id: 4, name: "周四" },
165
+        { id: 5, name: "周五" },
166
+        { id: 6, name: "周六" },
167
+        { id: 7, name: "周日" }
168 168
       ],
169 169
       classType: [
170
-        { id: 1, name: '上午' },
171
-        { id: 2, name: '下午' },
172
-        { id: 3, name: '晚上' }
170
+        { id: 1, name: "上午" },
171
+        { id: 2, name: "下午" },
172
+        { id: 3, name: "晚上" }
173 173
       ],
174 174
       // 机表消毒方式
175 175
       disinfectType: [
176
-        { id: 0, name: '/' },
177
-        { id: 1, name: '擦拭' },
178
-        { id: 2, name: '化学消毒' }
176
+        { id: 0, name: "/" },
177
+        { id: 1, name: "擦拭" },
178
+        { id: 2, name: "化学消毒" }
179 179
       ],
180 180
       // 基表消毒液
181 181
       disinfectantType: [
182
-        { id: 0, name: '/' },
183
-        { id: 1, name: '0.22%季铵盐' },
184
-        { id: 2, name: '500mg/l含氯消毒剂' },
185
-        { id: 3, name: '1000mg/l含氯消毒剂' },
186
-        { id: 4, name: '1500mg/l含氯消毒剂' }
182
+        { id: 0, name: "/" },
183
+        { id: 1, name: "0.22%季铵盐" },
184
+        { id: 2, name: "500mg/l含氯消毒剂" },
185
+        { id: 3, name: "1000mg/l含氯消毒剂" },
186
+        { id: 4, name: "1500mg/l含氯消毒剂" }
187 187
       ],
188 188
       // 夜路消毒方式
189 189
       sterilizeType: [
190
-        { id: 0, name: '/' },
191
-        { id: 1, name: '热化学消毒' },
192
-        { id: 2, name: '化学消毒 + 除钙' },
193
-        { id: 3, name: '热化学消毒 + 除钙' },
194
-        { id: 4, name: '热消毒' },
195
-        { id: 5, name: '化学消毒' },
196
-        { id: 6, name: '除钙' },
197
-        { id: 7, name: '清洗' }
190
+        { id: 0, name: "/" },
191
+        { id: 1, name: "热化学消毒" },
192
+        { id: 2, name: "化学消毒 + 除钙" },
193
+        { id: 3, name: "热化学消毒 + 除钙" },
194
+        { id: 4, name: "热消毒" },
195
+        { id: 5, name: "化学消毒" },
196
+        { id: 6, name: "除钙" },
197
+        { id: 7, name: "清洗" }
198 198
       ],
199 199
       // 夜路消毒液
200 200
       fluidPathType: [
201
-        { id: 0, name: '/' },
202
-        { id: 1, name: '20%柠檬酸' },
203
-        { id: 2, name: '25%柠檬酸' },
204
-        { id: 3, name: '50%柠檬酸' },
205
-        { id: 4, name: '50%柠檬酸 + 5%次氯酸钠' },
206
-        { id: 5, name: '20%柠檬酸 + 10%冰醋酸' },
207
-        { id: 6, name: '0.2%过氧化乙酸' },
208
-        { id: 7, name: '10%冰醋酸' },
209
-        { id: 8, name: '50%冰醋酸' },
210
-        { id: 9, name: '5%次氯酸钠' }
201
+        { id: 0, name: "/" },
202
+        { id: 1, name: "20%柠檬酸" },
203
+        { id: 2, name: "25%柠檬酸" },
204
+        { id: 3, name: "50%柠檬酸" },
205
+        { id: 4, name: "50%柠檬酸 + 5%次氯酸钠" },
206
+        { id: 5, name: "20%柠檬酸 + 10%冰醋酸" },
207
+        { id: 6, name: "0.2%过氧化乙酸" },
208
+        { id: 7, name: "10%冰醋酸" },
209
+        { id: 8, name: "50%冰醋酸" },
210
+        { id: 9, name: "5%次氯酸钠" }
211 211
       ],
212 212
       DeviceType: [],
213 213
       planid: 0,
214 214
       plandata: 0
215
-    }
215
+    };
216 216
   },
217 217
   methods: {
218 218
     open: function() {
219
-      this.dialogVisible = true
219
+      this.dialogVisible = true;
220 220
     },
221 221
     getAllEquimentName() {
222 222
       getAllEquimentName().then(response => {
223 223
         if (response.data.state === 1) {
224
-          var equit = response.data.data.equit
224
+          var equit = response.data.data.equit;
225 225
           // console.log('equit', equit);
226 226
           // this.DeviceType = equit;
227 227
         }
228
-      })
228
+      });
229 229
     },
230 230
     savePlan(formName) {
231
-      var equimentid = this.equimentid
231
+      var equimentid = this.equimentid;
232 232
       // console.log('equimentid', equimentid);
233
-      var devicetype = this.form.device_type
234
-      var devicetypes = parseInt(devicetype)
235
-      this.form.device_type = devicetypes
233
+      var devicetype = this.form.device_type;
234
+      var devicetypes = parseInt(devicetype);
235
+      this.form.device_type = devicetypes;
236 236
 
237
-      var ways = this.form.way
238
-      var way = parseInt(ways)
239
-      this.form.way = way
237
+      var ways = this.form.way;
238
+      var way = parseInt(ways);
239
+      this.form.way = way;
240 240
 
241
-      var machinedisinfectant = this.form.machine_disinfectant
242
-      var machinedisinfectants = parseInt(machinedisinfectant)
243
-      this.form.machine_disinfectant = machinedisinfectants
241
+      var machinedisinfectant = this.form.machine_disinfectant;
242
+      var machinedisinfectants = parseInt(machinedisinfectant);
243
+      this.form.machine_disinfectant = machinedisinfectants;
244 244
 
245
-      var disinfectantways = this.form.disinfectant_way
246
-      var disinfectantway = parseInt(disinfectantways)
247
-      this.form.disinfectant_way = disinfectantway
245
+      var disinfectantways = this.form.disinfectant_way;
246
+      var disinfectantway = parseInt(disinfectantways);
247
+      this.form.disinfectant_way = disinfectantway;
248 248
 
249
-      var disinfectants = this.form.disinfectant
250
-      var disinfectant = parseInt(disinfectants)
251
-      this.form.disinfectant = disinfectant
249
+      var disinfectants = this.form.disinfectant;
250
+      var disinfectant = parseInt(disinfectants);
251
+      this.form.disinfectant = disinfectant;
252 252
       savePlan(this.form, this.equimentid).then(response => {
253 253
         if (response.data.state === 1) {
254
-          var msg = response.data.data.msg
254
+          var msg = response.data.data.msg;
255 255
           // console.log('msg', msg);
256
-          this.$message.success('保存成功')
257
-          this.dialogVisible = false
258
-          this.$emit('getAllPlan')
259
-          this.$emit('getAllPlanDetail')
256
+          this.$message.success("保存成功");
257
+          this.dialogVisible = false;
258
+          this.$emit("getAllPlan");
259
+          this.$emit("getAllPlanDetail");
260 260
           // 如果保存成功通过状态值改变父组键表格的值
261
-          this.plandata = 1
262
-          this.$emit('func', this.plandata)
261
+          this.plandata = 1;
262
+          this.$emit("func", this.plandata);
263 263
         } else {
264
-          this.$message.error('该消毒计划已存在')
264
+          this.$message.error("该消毒计划已存在");
265 265
         }
266
-      })
266
+      });
267 267
     },
268 268
     getAllEquitType() {
269 269
       getAllEquitType().then(response => {
270 270
         if (response.data.state === 1) {
271
-          var equitname = response.data.data.equitname
272
-          var name = response.data.data.name
273
-          console.log('name', name)
274
-          // console.log('equitname', equitname)
275
-          this.DeviceType = equitname
271
+          var equitname = response.data.data.mode;
272
+          this.DeviceType = equitname;
276 273
         }
277
-      })
274
+      });
278 275
     }
279 276
   },
280 277
   created() {
281
-    this.getAllEquimentName()
282
-    this.getAllEquitType()
278
+    this.getAllEquimentName();
279
+    this.getAllEquitType();
283 280
   }
284
-}
281
+};
285 282
 </script>
286 283
 
287 284
 <style scoped></style>

Diferenças do arquivo suprimidas por serem muito extensas
+ 816 - 480
src/xt_pages/management/components/QualityForm.vue


+ 188 - 182
src/xt_pages/management/components/RepairForm.vue Ver arquivo

@@ -1,15 +1,7 @@
1 1
 <template>
2 2
   <div>
3
-    <el-row>
4
-      <el-col :span="2">
5
-        <el-checkbox v-model="checkAllStatus" @change="changeCheck"
6
-          >全选</el-checkbox
7
-        >
8
-      </el-col>
9
-      <el-col :span="2" class="a">
10
-        <el-button size="small" @click="BatchDelete">批量删除</el-button>
11
-      </el-col>
12
-      <el-col :span="4" class="a">
3
+    <el-row class="row">
4
+      <el-col :span="4">
13 5
         <span class="machineClass">机号:</span>
14 6
         <el-select style="width:100px" v-model="forms.bed">
15 7
           <el-option
@@ -20,7 +12,7 @@
20 12
           ></el-option>
21 13
         </el-select>
22 14
       </el-col>
23
-      <el-col :span="10" class="a">
15
+      <el-col :span="11">
24 16
         <span class="machineClass">日期查询:</span>
25 17
         <el-date-picker
26 18
           v-model="forms.start_time"
@@ -46,6 +38,16 @@
46 38
         <el-button @click="queryRepair()">查询</el-button>
47 39
       </el-col>
48 40
     </el-row>
41
+    <el-row>
42
+        <el-col :span="2">
43
+        <el-checkbox v-model="checkAllStatus" @change="changeCheck"
44
+          >全选</el-checkbox
45
+        >
46
+      </el-col>
47
+      <el-col :span="2" class="a">
48
+        <el-button size="small" @click="BatchDelete">批量删除</el-button>
49
+      </el-col>
50
+    </el-row>
49 51
     <el-row>
50 52
       <el-table
51 53
         ref="multipleTable"
@@ -418,141 +420,141 @@ import {
418 420
   DeleteRepair,
419 421
   queryRepair,
420 422
   DeleteRepairs
421
-} from "@/api/manage";
422
-import { uParseTime } from "@/utils/tools";
423
-import { getFileExtension } from "@/utils/tools";
423
+} from '@/api/manage'
424
+import { uParseTime } from '@/utils/tools'
425
+import { getFileExtension } from '@/utils/tools'
424 426
 export default {
425
-  name: "RepairForm",
427
+  name: 'RepairForm',
426 428
   data() {
427 429
     return {
428 430
       dialogVisible: false,
429 431
       selectCulture: [],
430 432
       forms: {
431
-        bed: "",
433
+        bed: '',
432 434
         sename: 1,
433
-        start_time: "",
434
-        end_time: ""
435
+        start_time: '',
436
+        end_time: ''
435 437
       },
436 438
       guaForm: {
437
-        id: "",
438
-        guarantee_date: "",
439
-        start_time: "",
440
-        arrive_time: "",
441
-        finish_time: "",
442
-        total_distance: "",
443
-        failure_stage: "",
444
-        fault_description: "",
445
-        cause_analysis: "",
446
-        treatment_process: "",
447
-        images: "",
448
-        exclude: "",
449
-        reason: "",
450
-        code_information: "",
451
-        image_name: ""
439
+        id: '',
440
+        guarantee_date: '',
441
+        start_time: '',
442
+        arrive_time: '',
443
+        finish_time: '',
444
+        total_distance: '',
445
+        failure_stage: '',
446
+        fault_description: '',
447
+        cause_analysis: '',
448
+        treatment_process: '',
449
+        images: '',
450
+        exclude: '',
451
+        reason: '',
452
+        code_information: '',
453
+        image_name: ''
452 454
       },
453 455
       isIndeterminate: false,
454 456
       checkAllStatus: false,
455 457
       bedNumber: [],
456 458
       tableData: [],
457
-      qiniuDomain: "https://images.shengws.com/",
458
-      uploadFileData: { token: "", key: "" },
459
+      qiniuDomain: 'https://images.shengws.com/',
460
+      uploadFileData: { token: '', key: '' },
459 461
       faultPhase: [
460
-        { id: 1, name: "开机启动" },
461
-        { id: 2, name: "自检" },
462
-        { id: 3, name: "准备" },
463
-        { id: 4, name: "治疗" },
464
-        { id: 5, name: "消毒" }
462
+        { id: 1, name: '开机启动' },
463
+        { id: 2, name: '自检' },
464
+        { id: 3, name: '准备' },
465
+        { id: 4, name: '治疗' },
466
+        { id: 5, name: '消毒' }
465 467
       ],
466 468
       breakDown: [
467
-        { id: 1, name: "是" },
468
-        { id: 2, name: "待观察" },
469
-        { id: 3, name: "未解决" }
469
+        { id: 1, name: '是' },
470
+        { id: 2, name: '待观察' },
471
+        { id: 3, name: '未解决' }
470 472
       ],
471 473
       repirRules: {
472
-        guarantee_date: [{ required: true, message: "请填写保修日期" }],
473
-        fault_description: [{ required: true, message: "请填写故障描述" }]
474
+        guarantee_date: [{ required: true, message: '请填写保修日期' }],
475
+        fault_description: [{ required: true, message: '请填写故障描述' }]
474 476
       },
475
-      filename: "",
477
+      filename: '',
476 478
       limit: 10,
477 479
       page: 1,
478 480
       total: 0,
479
-      filename: ""
480
-    };
481
+      filename: ''
482
+    }
481 483
   },
482 484
   methods: {
483 485
     changeCheck() {
484
-      this.$refs.multipleTable.clearSelection();
486
+      this.$refs.multipleTable.clearSelection()
485 487
       if (this.checkAllStatus) {
486
-        this.$refs.multipleTable.toggleAllSelection();
488
+        this.$refs.multipleTable.toggleAllSelection()
487 489
       }
488 490
     },
489 491
     getAllSubregion() {
490 492
       getAllSubregion().then(response => {
491
-        var zones = response.data.data.zones;
492
-        var numbers = response.data.data.numbers;
493
-        var number = [{ id: 0, number: "全部" }];
493
+        var zones = response.data.data.zones
494
+        var numbers = response.data.data.numbers
495
+        var number = [{ id: 0, number: '全部' }]
494 496
         for (let index = 0; index < numbers.length; index++) {
495
-          const item = numbers[index];
496
-          number.push({ id: item.id, number: item.number });
497
+          const item = numbers[index]
498
+          number.push({ id: item.id, number: item.number })
497 499
         }
498
-        this.bedNumber = number;
499
-      });
500
+        this.bedNumber = number
501
+      })
500 502
     },
501 503
     handleSelectionChange(val) {
502
-      this.selectCulture = val;
504
+      this.selectCulture = val
503 505
     },
504 506
     getAllRepair() {
505 507
       getAllRepair(this.limit, this.page).then(response => {
506 508
         if (response.data.state === 1) {
507
-          var repair = response.data.data.repair;
509
+          var repair = response.data.data.repair
508 510
           // console.log('repair是', repair)
509 511
           // eslint-disable-next-line no-unused-vars
510
-          var total = response.data.data.total;
511
-          this.total = total;
512
+          var total = response.data.data.total
513
+          this.total = total
512 514
           for (let index = 0; index < repair.length; index++) {
513 515
             if (repair[index].failure_stage === 0) {
514
-              repair[index].failure_stage = "";
516
+              repair[index].failure_stage = ''
515 517
             }
516 518
 
517 519
             if (repair[index].failure_stage === 1) {
518
-              repair[index].failure_stage = "开机启动";
520
+              repair[index].failure_stage = '开机启动'
519 521
             }
520 522
             if (repair[index].failure_stage === 2) {
521
-              repair[index].failure_stage = "自检";
523
+              repair[index].failure_stage = '自检'
522 524
             }
523 525
             if (repair[index].failure_stage === 3) {
524
-              repair[index].failure_stage = "准备";
526
+              repair[index].failure_stage = '准备'
525 527
             }
526 528
             if (repair[index].failure_stage === 4) {
527
-              repair[index].failure_stage = "治疗";
529
+              repair[index].failure_stage = '治疗'
528 530
             }
529 531
             if (repair[index].failure_stage === 5) {
530
-              repair[index].failure_stage = "消毒";
532
+              repair[index].failure_stage = '消毒'
531 533
             }
532 534
 
533 535
             if (repair[index].exclude === 0) {
534
-              repair[index].exclude = "";
536
+              repair[index].exclude = ''
535 537
             }
536 538
 
537 539
             if (repair[index].exclude === 1) {
538
-              repair[index].exclude = "是";
540
+              repair[index].exclude = '是'
539 541
             }
540 542
             if (repair[index].exclude === 2) {
541
-              repair[index].exclude = "待观察";
543
+              repair[index].exclude = '待观察'
542 544
             }
543 545
             if (repair[index].exclude === 3) {
544
-              repair[index].exclude = "未解决";
546
+              repair[index].exclude = '未解决'
545 547
             }
546 548
           }
547
-          this.tableData = repair;
549
+          this.tableData = repair
548 550
         }
549
-      });
551
+      })
550 552
     },
551 553
     getTime(time) {
552
-      return uParseTime(time, "{y}-{m}-{d}");
554
+      return uParseTime(time, '{y}-{m}-{d}')
553 555
     },
554 556
     getTimes(time) {
555
-      return uParseTime(time, "{y}-{m}-{d} {h}:{i}");
557
+      return uParseTime(time, '{y}-{m}-{d} {h}:{i}')
556 558
     },
557 559
     handleExceed(file) {
558 560
       // console.log(file)
@@ -561,62 +563,62 @@ export default {
561 563
       // console.log(file)
562 564
     },
563 565
     EditRepair(id) {
564
-      this.dialogVisible = true;
566
+      this.dialogVisible = true
565 567
       EditRepair(id).then(response => {
566 568
         if (response.data.state === 1) {
567
-          var repair = response.data.data.repair;
568
-          console.log("repair", repair);
569
+          var repair = response.data.data.repair
570
+          console.log('repair', repair)
569 571
           this.guaForm.guarantee_date = uParseTime(
570 572
             repair.guarantee_date,
571
-            "{y}-{m}-{d}"
572
-          );
573
+            '{y}-{m}-{d}'
574
+          )
573 575
           this.guaForm.start_time = uParseTime(
574 576
             repair.start_time,
575
-            "{y}-{m}-{d} {h}:{i}"
576
-          );
577
+            '{y}-{m}-{d} {h}:{i}'
578
+          )
577 579
           this.guaForm.arrive_time = uParseTime(
578 580
             repair.arrive_time,
579
-            "{y}-{m}-{d} {h}:{i}"
580
-          );
581
+            '{y}-{m}-{d} {h}:{i}'
582
+          )
581 583
           this.guaForm.finish_time = uParseTime(
582 584
             repair.finish_time,
583
-            "{y}-{m}-{d} {h}:{i}"
584
-          );
585
-          this.guaForm.total_distance = repair.total_distance;
586
-          this.guaForm.failure_stage = repair.failure_stage;
587
-          this.guaForm.fault_description = repair.fault_description;
588
-          this.guaForm.cause_analysis = repair.cause_analysis;
589
-          this.guaForm.treatment_process = repair.treatment_process;
590
-          this.guaForm.images = repair.images;
591
-          this.guaForm.exclude = repair.exclude;
592
-          this.guaForm.reason = repair.reason;
593
-          this.guaForm.code_information = repair.code_information;
594
-          this.guaForm.id = repair.id;
595
-          this.filename = repair.image_name;
585
+            '{y}-{m}-{d} {h}:{i}'
586
+          )
587
+          this.guaForm.total_distance = repair.total_distance
588
+          this.guaForm.failure_stage = repair.failure_stage
589
+          this.guaForm.fault_description = repair.fault_description
590
+          this.guaForm.cause_analysis = repair.cause_analysis
591
+          this.guaForm.treatment_process = repair.treatment_process
592
+          this.guaForm.images = repair.images
593
+          this.guaForm.exclude = repair.exclude
594
+          this.guaForm.reason = repair.reason
595
+          this.guaForm.code_information = repair.code_information
596
+          this.guaForm.id = repair.id
597
+          this.filename = repair.image_name
596 598
         }
597
-      });
599
+      })
598 600
     },
599 601
     handleSuccess(res, file, fileList) {
600
-      this.guaForm.images = this.qiniuDomain + res.url;
601
-      console.log("图片上传", this.guaForm.images);
602
-      this.$refs.upload.clearFiles();
603
-      this.filename = file.name;
604
-      this.guaForm.image_name = file.name;
602
+      this.guaForm.images = this.qiniuDomain + res.url
603
+      console.log('图片上传', this.guaForm.images)
604
+      this.$refs.upload.clearFiles()
605
+      this.filename = file.name
606
+      this.guaForm.image_name = file.name
605 607
     },
606 608
     beforeUploadFile(file) {
607
-      this.filename = file.name;
608
-      this.guaForm.image_name = file.name;
609
-      const isLt2M = file.size / 1024 / 1024 <= 2048;
610
-      console.log("filename", file);
609
+      this.filename = file.name
610
+      this.guaForm.image_name = file.name
611
+      const isLt2M = file.size / 1024 / 1024 <= 2048
612
+      console.log('filename', file)
611 613
       // console.log('视频大小', file.size / 1024 / 1024)
612 614
       // console.log('isLt2M是什么', isLt2M)
613 615
 
614 616
       if (!isLt2M) {
615
-        this.$message.error("上传视频大小不能超过 2G!");
616
-        return false;
617
+        this.$message.error('上传视频大小不能超过 2G!')
618
+        return false
617 619
       }
618
-      var date = new Date();
619
-      var ext = getFileExtension(file.name);
620
+      var date = new Date()
621
+      var ext = getFileExtension(file.name)
620 622
       var key =
621 623
         date.getFullYear() +
622 624
         (date.getMonth() + 1) +
@@ -624,104 +626,104 @@ export default {
624 626
         date.getHours() +
625 627
         date.getMinutes() +
626 628
         date.getSeconds() +
627
-        "_o_" +
629
+        '_o_' +
628 630
         file.uid +
629
-        "." +
630
-        ext;
631
-      const _self = this;
631
+        '.' +
632
+        ext
633
+      const _self = this
632 634
       return new Promise((resolve, reject) => {
633 635
         // eslint-disable-next-line no-undef
634 636
         getToken()
635 637
           .then(response => {
636
-            const token = response.data.data.uptoken;
637
-            console.log("token2是什么?", token);
638
-            _self._data.uploadFileData.token = token;
639
-            _self._data.uploadFileData.key = key;
640
-            resolve(true);
638
+            const token = response.data.data.uptoken
639
+            console.log('token2是什么?', token)
640
+            _self._data.uploadFileData.token = token
641
+            _self._data.uploadFileData.key = key
642
+            resolve(true)
641 643
           })
642 644
           // eslint-disable-next-line handle-callback-err
643 645
           .catch(err => {
644
-            reject(false);
645
-          });
646
-      });
646
+            reject(false)
647
+          })
648
+      })
647 649
     },
648 650
     toLink() {
649
-      window.location.href = this.guaForm.images;
651
+      window.location.href = this.guaForm.images
650 652
     },
651 653
     UpdateRepair(formName) {
652 654
       this.$refs[formName].validate(valid => {
653 655
         this.guaForm.start_time = uParseTime(
654 656
           this.guaForm.start_time,
655
-          "{y}-{m}-{d} {h}:{i}"
656
-        );
657
+          '{y}-{m}-{d} {h}:{i}'
658
+        )
657 659
         this.guaForm.arrive_time = uParseTime(
658 660
           this.guaForm.arrive_time,
659
-          "{y}-{m}-{d} {h}:{i}"
660
-        );
661
+          '{y}-{m}-{d} {h}:{i}'
662
+        )
661 663
         this.guaForm.finish_time = uParseTime(
662 664
           this.guaForm.finish_time,
663
-          "{y}-{m}-{d} {h}:{i}"
664
-        );
665
+          '{y}-{m}-{d} {h}:{i}'
666
+        )
665 667
 
666
-        if (this.guaForm.failure_stage === "") {
667
-          this.guaForm.failure_stage = 0;
668
+        if (this.guaForm.failure_stage === '') {
669
+          this.guaForm.failure_stage = 0
668 670
         }
669 671
 
670
-        var failurestages = this.guaForm.failure_stage;
671
-        var falur = parseInt(failurestages);
672
-        this.guaForm.failure_stage = falur;
672
+        var failurestages = this.guaForm.failure_stage
673
+        var falur = parseInt(failurestages)
674
+        this.guaForm.failure_stage = falur
673 675
 
674
-        if (this.guaForm.exclude === "") {
675
-          this.guaForm.exclude = 0;
676
+        if (this.guaForm.exclude === '') {
677
+          this.guaForm.exclude = 0
676 678
         }
677
-        var excludes = this.guaForm.exclude;
678
-        var exclude = parseInt(excludes);
679
-        this.guaForm.exclude = exclude;
679
+        var excludes = this.guaForm.exclude
680
+        var exclude = parseInt(excludes)
681
+        this.guaForm.exclude = exclude
680 682
         if (valid) {
681 683
           UpdateRepair(this.guaForm).then(response => {
682 684
             if (response.data.state === 1) {
683
-              var repair = response.data.data.repair;
684
-              this.dialogVisible = false;
685
-              this.$message.success("修改成功");
685
+              var repair = response.data.data.repair
686
+              this.dialogVisible = false
687
+              this.$message.success('修改成功')
686 688
             }
687
-          });
689
+          })
688 690
         }
689
-      });
691
+      })
690 692
     },
691 693
     BatchDelete() {
692 694
       if (this.selectCulture.length == 0) {
693
-        this.$message.error("请选择要删除的信息");
694
-        return false;
695
+        this.$message.error('请选择要删除的信息')
696
+        return false
695 697
       }
696 698
       this.$confirm(
697
-        "确认要删除所选记录吗? <br>删除后,信息将无法恢复",
698
-        "删除提示",
699
+        '确认要删除所选记录吗? <br>删除后,信息将无法恢复',
700
+        '删除提示',
699 701
         {
700 702
           dangerouslyUseHTMLString: true,
701
-          confirmButtonText: "确定",
702
-          cancelButtonText: "取消",
703
-          type: "warning"
703
+          confirmButtonText: '确定',
704
+          cancelButtonText: '取消',
705
+          type: 'warning'
704 706
         }
705 707
       ).then(() => {
706
-        var ids = [];
707
-        var idMap = {};
708
+        var ids = []
709
+        var idMap = {}
708 710
         for (const index in this.selectCulture) {
709
-          ids.push(this.selectCulture[index].id);
710
-          idMap[this.selectCulture[index].id] = this.selectCulture[index].id;
711
+          ids.push(this.selectCulture[index].id)
712
+          idMap[this.selectCulture[index].id] = this.selectCulture[index].id
711 713
         }
712 714
         DeleteRepair({ ids: ids }).then(response => {
713 715
           if (response.data.state === 1) {
714
-            var msg = response.data.data.msg;
715
-            var planDataLength = this.tableData.length;
716
+            var msg = response.data.data.msg
717
+            var planDataLength = this.tableData.length
716 718
             for (let index = planDataLength - 1; index >= 0; index--) {
717 719
               if (this.tableData[index].id in idMap) {
718
-                this.tableData.splice(index, 1);
720
+                this.tableData.splice(index, 1)
719 721
               }
720 722
             }
721
-            this.$message.success("删除成功");
723
+            this.$message.success('删除成功')
722 724
           }
723
-        });
724
-      });
725
+        })
726
+      })
725 727
     },
726 728
     queryRepair() {
727 729
       queryRepair(
@@ -730,44 +732,48 @@ export default {
730 732
         this.forms.end_time
731 733
       ).then(response => {
732 734
         if (response.data.state === 1) {
733
-          var repair = response.data.data.repair;
734
-          this.tableData = repair;
735
+          var repair = response.data.data.repair
736
+          this.tableData = repair
735 737
         }
736
-      });
738
+      })
737 739
     },
738 740
     handleSizeChange(limit) {
739
-      this.limit = limit;
740
-      this.getAllRepair();
741
+      this.limit = limit
742
+      this.getAllRepair()
741 743
     },
742 744
     handleCurrentChange(page) {
743
-      this.page = page;
744
-      this.getAllRepair();
745
+      this.page = page
746
+      this.getAllRepair()
745 747
     },
746 748
     DeleteRepairs(id, index) {
747 749
       this.$confirm(
748
-        "确认要删除所选记录吗? <br>删除后,信息将无法恢复",
749
-        "删除提示",
750
+        '确认要删除所选记录吗? <br>删除后,信息将无法恢复',
751
+        '删除提示',
750 752
         {
751 753
           dangerouslyUseHTMLString: true,
752
-          confirmButtonText: "确定",
753
-          cancelButtonText: "取消",
754
-          type: "warning"
754
+          confirmButtonText: '确定',
755
+          cancelButtonText: '取消',
756
+          type: 'warning'
755 757
         }
756 758
       ).then(() => {
757 759
         DeleteRepairs(id, index).then(response => {
758 760
           if (response.data.state === 1) {
759
-            var msg = response.data.data.msg;
760
-            this.tableData.splice(index, 1);
761
+            var msg = response.data.data.msg
762
+            this.tableData.splice(index, 1)
761 763
           }
762
-        });
763
-      });
764
+        })
765
+      })
764 766
     }
765 767
   },
766 768
   created() {
767
-    this.getAllSubregion();
768
-    this.getAllRepair();
769
+    this.getAllSubregion()
770
+    this.getAllRepair()
769 771
   }
770
-};
772
+}
771 773
 </script>
772 774
 
773
-<style scoped></style>
775
+<style scoped>
776
+  .row{
777
+    margin-bottom:10px;
778
+  }
779
+</style>

+ 43 - 38
src/xt_pages/management/components/UserForm.vue Ver arquivo

@@ -1,20 +1,31 @@
1 1
 <template>
2 2
   <div id="user-form">
3
-    <el-row>
4
-      <el-col :span="2" class="a">
5
-        <el-checkbox
6
-          :indeterminate="isIndeterminate"
7
-          v-model="checkAllStatus"
8
-          @change="changeCheck"
9
-          >全选</el-checkbox
10
-        >
11
-      </el-col>
12
-      <el-col :span="2" class="a">
13
-        <el-button size="small" @click="BatchDelete">批量删除</el-button>
3
+    <el-row class="c">
4
+      <el-col :span="11">
5
+        <span class="machineClass">日期查询:</span>
6
+        <el-date-picker
7
+          v-model="form.start_time"
8
+          prefix-icon="none"
9
+          type="date"
10
+          placeholder="请选择"
11
+          format="yyyy-MM-dd"
12
+          value-format="yyyy-MM-dd"
13
+          style="width:145px"
14
+        ></el-date-picker
15
+        >-
16
+        <el-date-picker
17
+          v-model="form.end_time"
18
+          prefix-icon="none"
19
+          type="date"
20
+          placeholder="请选择"
21
+          format="yyyy-MM-dd"
22
+          value-format="yyyy-MM-dd"
23
+          style="width:145px"
24
+        ></el-date-picker>
14 25
       </el-col>
15
-      <el-col :span="3" class="a">
26
+       <el-col :span="4">
16 27
         <span class="machineClass">分区:</span>
17
-        <el-select style="width:80px" v-model="form.zone" @change="changeBed">
28
+        <el-select style="width:90px" v-model="form.zone" @change="changeBed">
18 29
           <el-option
19 30
             v-for="item in this.zones"
20 31
             :key="item.id"
@@ -23,7 +34,7 @@
23 34
           ></el-option>
24 35
         </el-select>
25 36
       </el-col>
26
-      <el-col :span="4" class="a">
37
+      <el-col :span="4">
27 38
         <span class="machineClass">机位号:</span>
28 39
         <el-select style="width:80px" v-model="form.bed">
29 40
           <el-option
@@ -34,32 +45,23 @@
34 45
           ></el-option>
35 46
         </el-select>
36 47
       </el-col>
37
-      <el-col :span="8" class="a">
38
-        <span class="machineClass">日期查询:</span>
39
-        <el-date-picker
40
-          v-model="form.start_time"
41
-          prefix-icon="none"
42
-          type="date"
43
-          placeholder="请选择"
44
-          format="yyyy-MM-dd"
45
-          value-format="yyyy-MM-dd"
46
-          style="width:120px"
47
-        ></el-date-picker
48
-        >-
49
-        <el-date-picker
50
-          v-model="form.end_time"
51
-          prefix-icon="none"
52
-          type="date"
53
-          placeholder="请选择"
54
-          format="yyyy-MM-dd"
55
-          value-format="yyyy-MM-dd"
56
-          style="width:120px"
57
-        ></el-date-picker>
58
-      </el-col>
59
-      <el-col :span="2" class="a">
48
+      <el-col :span="5">
60 49
         <el-button @click="queryInfo()">查询</el-button>
61 50
       </el-col>
62
-      <el-col :span="2" class="a">
51
+    </el-row>
52
+    <el-row :span="24">
53
+      <el-col :span="2">
54
+        <el-checkbox
55
+          :indeterminate="isIndeterminate"
56
+          v-model="checkAllStatus"
57
+          @change="changeCheck"
58
+          >全选</el-checkbox
59
+        >
60
+      </el-col>
61
+      <el-col :span="3">
62
+        <el-button size="small" @click="BatchDelete">批量删除</el-button>
63
+      </el-col>
64
+       <el-col :span="6" class="a">
63 65
         <el-button @click="printCard">打印</el-button>
64 66
       </el-col>
65 67
     </el-row>
@@ -2238,4 +2240,7 @@ export default {
2238 2240
 .machineClass {
2239 2241
   font-size: 14px;
2240 2242
 }
2243
+.c{
2244
+  margin-bottom:10px;
2245
+}
2241 2246
 </style>

+ 122 - 71
src/xt_pages/management/home.vue Ver arquivo

@@ -9,7 +9,7 @@
9 9
                  <el-row>
10 10
                    <el-col :span="24">
11 11
                      <span class="zone">分&nbsp;&nbsp;&nbsp;&nbsp;区:</span>
12
-                      <el-select v-model="forms.zone_id" placeholder="请选择" class="a" @change="changeBedNumber" style="width:125px">
12
+                      <el-select v-model="forms.zone_id" placeholder="请选择" class="a" @change="changeBedNumber" style="width:125px" :disabled="zoneDisabled">
13 13
                         <el-option
14 14
                          v-for="item in bedZone"
15 15
                          :key="item.id"
@@ -20,19 +20,19 @@
20 20
                       </el-select>
21 21
                      </el-col>
22 22
                   </el-row>
23
-                  <el-row>
24
-                   <el-col>
25
-                    <span class="zone">班&nbsp;&nbsp;&nbsp;&nbsp;次:</span>
26
-                      <el-select v-model="forms.class_id" placeholder="请选择" class="a" @change="changeClassId" style="width:125px">
27
-                        <el-option
28
-                         v-for="item in Classes"
29
-                         :key="item.id"
30
-                         :label="item.name"
31
-                         :value="item.id">
32
-                        </el-option>
33
-                      </el-select>
34
-                     </el-col>
35
-                  </el-row>
23
+<!--                  <el-row>-->
24
+<!--                   <el-col>-->
25
+<!--                    <span class="zone">班&nbsp;&nbsp;&nbsp;&nbsp;次:</span>-->
26
+<!--                      <el-select v-model="forms.class_id" placeholder="请选择" class="a" @change="changeClassId" style="width:125px">-->
27
+<!--                        <el-option-->
28
+<!--                         v-for="item in Classes"-->
29
+<!--                         :key="item.id"-->
30
+<!--                         :label="item.name"-->
31
+<!--                         :value="item.id">-->
32
+<!--                        </el-option>-->
33
+<!--                      </el-select>-->
34
+<!--                     </el-col>-->
35
+<!--                  </el-row>-->
36 36
                   <el-row>
37 37
                      <el-col>
38 38
                      <span>设备类型:</span>
@@ -62,7 +62,7 @@
62 62
                       align="center"
63 63
                       >
64 64
                       <template slot-scope="scope">
65
-                         <div @click="handleIndex(scope.$index)">{{scope.row.device_name}}</div> 
65
+                         <div @click="handleIndex(scope.$index)">{{scope.row.device_name}}</div>
66 66
                       </template>
67 67
                     </el-table-column>
68 68
                      <el-table-column
@@ -71,7 +71,7 @@
71 71
                       width="90"
72 72
                       align="center">
73 73
                       <template slot-scope="scope">
74
-                        <div @click="handleIndex(scope.$index)">{{scope.row.unit_type}}</div> 
74
+                        <div @click="handleIndex(scope.$index)">{{scope.row.device_mode}}</div>
75 75
                       </template>
76 76
                      </el-table-column>
77 77
                       <el-table-column
@@ -152,7 +152,14 @@
152 152
                              <el-row>
153 153
                                <el-col :span="7">
154 154
                                    <el-form-item label="设备型号:" required prop="unit_type">
155
-                                       <el-input style="width:150px" v-model="form.unit_type" :disabled="disableThree"></el-input>
155
+                                        <el-select style="width:135px" v-model="form.unit_type" :disabled="disableThree">
156
+                                           <el-option
157
+                                             v-for="item in this.deviceMode"
158
+                                             :key="item.id"
159
+                                             :label="item.device_mode"
160
+                                             :value="item.id"
161
+                                           ></el-option>
162
+                                          </el-select>
156 163
                                    </el-form-item>
157 164
                                </el-col>
158 165
                                <el-col :span="7">
@@ -353,7 +360,14 @@
353 360
                              <el-row>
354 361
                                <el-col :span="7">
355 362
                                    <el-form-item label="设备型号:" required prop="unit_type">
356
-                                       <el-input style="width:150px" v-model="form.unit_type" :disabled="disableFour"></el-input>
363
+                                       <el-select style="width:135px" v-model="form.unit_type" :disabled="disableFour">
364
+                                        <el-option
365
+                                            v-for="item in this.deviceMode"
366
+                                            :key="item.id"
367
+                                            :label="item.device_mode"
368
+                                            :value="item.id"
369
+                                             ></el-option>
370
+                                           </el-select>
357 371
                                    </el-form-item>
358 372
                                </el-col>
359 373
                                <el-col :span="7">
@@ -563,9 +577,16 @@
563 577
                               <el-row>
564 578
                                <el-col :span="7">
565 579
                                    <el-form-item label="设备型号:" required prop="unit_type">
566
-                                       <el-input style="width:150px" v-model="form.unit_type" :disabled="disableFive"></el-input>
567
-                                   </el-form-item>
568
-                               </el-col>
580
+                                       <el-select style="width:135px" v-model="form.unit_type" :disabled="disableFive">
581
+                                        <el-option
582
+                                            v-for="item in this.deviceMode"
583
+                                            :key="item.id"
584
+                                            :label="item.device_mode"
585
+                                            :value="item.id"
586
+                                             ></el-option>
587
+                                           </el-select>
588
+                                       </el-form-item>
589
+                                    </el-col>
569 590
                                <el-col :span="7">
570 591
                                   <el-form-item label="使用科室:">
571 592
                                        <el-input style="width:150px" v-model="form.use_section" :disabled="disableFive"></el-input>
@@ -779,7 +800,7 @@
779 800
                                                     {{scope.row.disinfec_time}}
780 801
                                                  </template>
781 802
                                         </el-table-column>
782
-                                         <el-table-column label="操作" align="center" min-width="120px">
803
+                                         <el-table-column label="操作" align="center" min-width="130px">
783 804
                                              <template slot-scope="scope">
784 805
                                                  <el-tooltip class="item" effect="dark" content="编辑" placement="top">
785 806
                                                   <el-button
@@ -827,7 +848,7 @@
827 848
                                         <el-table-column align="center" type="selection" width="55"></el-table-column>
828 849
                                         <el-table-column label="型号" align="center" min-width="70px">
829 850
                                                 <template slot-scope="scope">
830
-                                                    {{scope.row.equitment_name}}
851
+                                                    {{scope.row.device_mode}}
831 852
                                                  </template>
832 853
                                         </el-table-column>
833 854
                                          <el-table-column label="时间" align="center" min-width="70px" >
@@ -865,7 +886,7 @@
865 886
                                                     {{scope.row.disinfec_time}}
866 887
                                                  </template>
867 888
                                         </el-table-column>
868
-                                         <el-table-column label="操作" align="center" min-width="130px">
889
+                                         <el-table-column label="操作" align="center" width="130px">
869 890
                                              <template slot-scope="scope">
870 891
                                                  <el-tooltip class="item" effect="dark" content="编辑" placement="top">
871 892
                                                   <el-button
@@ -910,7 +931,7 @@
910 931
                              <el-form :model="userform" ref="userform" :rules="userRules">
911 932
                                 <el-row>
912 933
                                   <el-col :span="8">
913
-                                     <el-form-item label="日期:" required prop="date">
934
+                                     <el-form-item label="日期:" required prop="date" class="st">
914 935
                                          <el-date-picker
915 936
                                            v-model="userform.date"
916 937
                                            prefix-icon="none"
@@ -923,7 +944,7 @@
923 944
                                      </el-form-item>
924 945
                                   </el-col>
925 946
                                   <el-col :span="8">
926
-                                     <el-form-item label="班次:" required prop="classtype">
947
+                                     <el-form-item label="班次:" required prop="classtype" class="st">
927 948
                                        <el-select v-model="userform.classtype" placeholder="请选择" class="a" @change="ChangeClass">
928 949
                                            <el-option
929 950
                                             v-for="item in classType"
@@ -1251,7 +1272,7 @@
1251 1272
                                          <el-radio-group v-model="userform.dialysis_concentration">
1252 1273
                                                 <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in potency" :key="index">{{gender.name}}</el-radio>
1253 1274
                                          </el-radio-group>
1254
-                                      
1275
+
1255 1276
                                       </el-form-item>
1256 1277
                                    </el-col>
1257 1278
                                 </el-row>
@@ -1315,7 +1336,7 @@
1315 1336
                                   </div>
1316 1337
                                 </el-row>
1317 1338
                              </el-form>
1318
-                             
1339
+
1319 1340
                           </el-tab-pane>
1320 1341
                            <el-tab-pane label="使用登记列表" name="second">
1321 1342
                              <user-form ref="userForm" :userdata="userdata"></user-form>
@@ -1911,7 +1932,7 @@
1911 1932
                 <el-option
1912 1933
                   v-for="item in this.DeviceType"
1913 1934
                   :key="item.id"
1914
-                  :label="item.equitment_name"
1935
+                  :label="item.device_mode"
1915 1936
                   :value="item.id"
1916 1937
                 ></el-option>
1917 1938
               </el-select>
@@ -2030,7 +2051,7 @@
2030 2051
   import { getAllSubregion, getAllMachine, getMachineDetailById,
2031 2052
     UpdateMachineInfo, getAllPlan, getAllPlanDetail, DeletePlans,
2032 2053
     getAllEquimentName, EditPlanDetail, UpdatePlanInfo, SaveInformation, getPatientInfo,
2033
-    ChangeClass, getAllOrganization, getUserRegister, SaveQualityControl, getOrgName, SaveRepair, SaveBacteria, SaveLincomycin, getAutoData, getAllEquitType, UpdateMacheineTwo, getTotalNumber, getTimeWarning, getAllpatient, UpdateMachineInfoTwo, getPatientDetail, openDelete } from '@/api/manage'
2054
+    ChangeClass, getAllOrganization, getUserRegister, SaveQualityControl, getOrgName, SaveRepair, SaveBacteria, SaveLincomycin, getAutoData, getAllEquitType, UpdateMacheineTwo, getTotalNumber, getTimeWarning, getAllpatient, UpdateMachineInfoTwo, getPatientDetail, openDelete, getAllMode } from '@/api/manage'
2034 2055
   import { uParseTime } from '@/utils/tools'
2035 2056
   import { getToken } from '@/api/qiniu'
2036 2057
   import PlanForm from './components/PlanForm'
@@ -2157,9 +2178,9 @@ export default {
2157 2178
         bedZone: [],
2158 2179
         bedZoneTwo: [],
2159 2180
         forms: {
2160
-          zone_id: '', // 分区号
2181
+          zone_id: 0, // 分区号
2161 2182
           class_id: '', // 班次
2162
-          device_type: '', // 设备类型
2183
+          device_type: 0, // 设备类型
2163 2184
           date: ''
2164 2185
         },
2165 2186
         currentRow: null,
@@ -2474,6 +2495,7 @@ export default {
2474 2495
           code_information: '',
2475 2496
           imageName: ''
2476 2497
         },
2498
+
2477 2499
         filename: '',
2478 2500
         qiniuDomain: 'https://images.shengws.com/',
2479 2501
         uploadFileData: { token: '', key: '' },
@@ -2505,7 +2527,11 @@ export default {
2505 2527
           { id: 1, name: '单级反渗' },
2506 2528
           { id: 2, name: '双级反渗' }
2507 2529
         ],
2508
-        tabIndex: ''
2530
+        tabIndex: '',
2531
+        deviceMode: [],
2532
+        zoneDisabled: false,
2533
+        bedid: '',
2534
+        unitType: ''
2509 2535
       }
2510 2536
     },
2511 2537
     methods: {
@@ -2581,7 +2607,7 @@ export default {
2581 2607
           this.bedZoneTwo = zones
2582 2608
           this.bedZoneThree = zoness
2583 2609
           this.bedNumber = numbers
2584
-  
2610
+
2585 2611
           // this.Number = devicenumber
2586 2612
         })
2587 2613
       },
@@ -2595,13 +2621,19 @@ export default {
2595 2621
         this.getAllMachine()
2596 2622
       },
2597 2623
       changeDeviceId(val) {
2624
+        if (val === 1) {
2625
+          this.zoneDisabled = false
2626
+        } else {
2627
+          this.zoneDisabled = true
2628
+        }
2598 2629
         this.forms.device_type = val
2599 2630
         this.getAllMachine()
2600 2631
       },
2601 2632
       getAllMachine() {
2602
-        getAllMachine(this.forms.zone_id, this.forms.class_id, this.forms.device_type).then(response => {
2633
+        getAllMachine(this.forms.zone_id, this.forms.device_type).then(response => {
2603 2634
           if (response.data.state === 1) {
2604 2635
             var addmahcer = response.data.data.addmahcer
2636
+            console.log('addmacher是', addmahcer)
2605 2637
             this.tableDatatwo = addmahcer
2606 2638
             this.tabIndex = this.$route.query.index
2607 2639
             this.$refs.singleTable.setCurrentRow(this.tableDatatwo[this.tabIndex])
@@ -2612,13 +2644,14 @@ export default {
2612 2644
         this.tabIndex = index
2613 2645
       },
2614 2646
       handleCurrentChange(val) {
2647
+        this.unitType = val.unit_type
2615 2648
         // console.log('val是什么', val)
2616 2649
         this.currentRow = val
2617 2650
         this.$forceUpdate()
2618 2651
         this.getMachineDetailById(val.id)
2619 2652
         this.equimentid = val.id
2620 2653
         this.userdata = val.id
2621
-        this.getAllPlanDetail(val.unit_type)
2654
+        this.getAllPlanDetail(val.unit_type, val.bed_id)
2622 2655
         this.getPatientInfo(val.id)
2623 2656
         // 获取基本信息
2624 2657
         this.getUserRegister(val.id)
@@ -2638,7 +2671,7 @@ export default {
2638 2671
         getMachineDetailById(id).then(response => {
2639 2672
           if (response.data.state === 1) {
2640 2673
             var addmacher = response.data.data.addmacher
2641
-            // console.log('addmacher', addmacher)
2674
+            console.log('设备详情', addmacher)
2642 2675
             var warning = response.data.data.warning
2643 2676
             // console.log('warning', warning)
2644 2677
             var time = this.getTimestamp(this.userform.date) - warning.stime
@@ -2774,7 +2807,10 @@ export default {
2774 2807
             this.form.device_name = addmacher.device_name
2775 2808
             this.form.manufacture_factory = addmacher.manufacture_factory
2776 2809
             this.form.service_manufacturer = addmacher.service_manufacturer
2777
-            this.form.unit_type = addmacher.unit_type
2810
+
2811
+            // this.form.unit_type = addmacher.unit_type
2812
+  
2813
+            this.form.unit_type = parseInt(addmacher.device_mode)
2778 2814
             this.form.use_section = addmacher.use_section
2779 2815
             this.form.section_number = addmacher.section_number
2780 2816
             if (addmacher.buy_date !== 0) {
@@ -2801,7 +2837,7 @@ export default {
2801 2837
             this.form.rubbish_reason = addmacher.rubbish_reason
2802 2838
             this.form.user_year = addmacher.user_year
2803 2839
             this.form.work_time = addmacher.work_time
2804
-  
2840
+
2805 2841
             // eslint-disable-next-line eqeqeq
2806 2842
             if (addmacher.disinfection_mode == 0) {
2807 2843
               this.form.Disinfection_mode = 0
@@ -2932,7 +2968,7 @@ export default {
2932 2968
         var machine_status = this.form.machine_status
2933 2969
         var machine_statuss = parseInt(machine_status)
2934 2970
         this.form.machine_status = machine_statuss
2935
-  
2971
+
2936 2972
         var revers_mode = this.form.revers_mode
2937 2973
         var revers_modes = parseInt(revers_mode)
2938 2974
         this.form.revers_mode = revers_modes
@@ -2940,7 +2976,7 @@ export default {
2940 2976
         var disinfecction_modes = this.form.Disinfection_mode
2941 2977
         var disinfecction_modess = parseInt(disinfecction_modes)
2942 2978
         this.form.Disinfection_mode = disinfecction_modess
2943
-  
2979
+
2944 2980
         this.$refs[formName].validate(valid => {
2945 2981
           if (valid) {
2946 2982
             UpdateMachineInfoTwo(this.form).then(response => {
@@ -2971,7 +3007,7 @@ export default {
2971 3007
         var machine_status = this.form.machine_status
2972 3008
         var machine_statuss = parseInt(machine_status)
2973 3009
         this.form.machine_status = machine_statuss
2974
-  
3010
+
2975 3011
         this.$refs[formName].validate(valid => {
2976 3012
           UpdateMacheineTwo(this.form).then(response => {
2977 3013
             if (response.data.state === 1) {
@@ -3034,11 +3070,11 @@ export default {
3034 3070
           this.form.rubbish_reason = ''
3035 3071
         }
3036 3072
       },
3037
-      getAllPlan() {
3038
-        getAllPlan().then(response => {
3073
+      getAllPlan(bedid) {
3074
+        getAllPlan(bedid).then(response => {
3039 3075
           if (response.data.state === 1) {
3040 3076
             var plan = response.data.data.plan
3041
-  
3077
+
3042 3078
             for (let index = 0; index < plan.length; index++) {
3043 3079
               if (plan[index].time === 1) {
3044 3080
                 plan[index].time = '周一'
@@ -3168,11 +3204,11 @@ export default {
3168 3204
           }
3169 3205
         })
3170 3206
       },
3171
-      getAllPlanDetail(unit_type) {
3172
-        getAllPlanDetail(unit_type).then(response => {
3207
+      getAllPlanDetail(unit_type, bedid) {
3208
+        getAllPlanDetail(unit_type, bedid).then(response => {
3173 3209
           if (response.data.state === 1) {
3174 3210
             var plandetail = response.data.data.plandetail
3175
-            // console.log('plandetail=====================', plandetail)
3211
+            console.log('plandetail', plandetail)
3176 3212
             for (let index = 0; index < plandetail.length; index++) {
3177 3213
               if (plandetail[index].time === 1) {
3178 3214
                 plandetail[index].time = '周一'
@@ -3316,6 +3352,7 @@ export default {
3316 3352
             this.machineform.machine_disinfectant = plan.machine_disinfectant
3317 3353
             this.machineform.disinfectant_way = plan.disinfectan_way
3318 3354
             this.machineform.disinfectant = plan.disinfectant
3355
+            this.getPatientDetail(this.unitType, this.$route.query.bedid)
3319 3356
           }
3320 3357
         })
3321 3358
       },
@@ -3352,12 +3389,12 @@ export default {
3352 3389
         var disinfectant = parseInt(disinfectants)
3353 3390
         this.machineform.disinfectant = disinfectant
3354 3391
         UpdatePlanInfo(this.machineform).then(response => {
3355
-          if (response.data.state == 1) {
3392
+          if (response.data.state === 1) {
3356 3393
             var plan = response.data.data.plan
3357 3394
             this.dialogVisible = false
3358 3395
             this.$message.success('修改成功')
3359
-            this.getAllPlanDetail(this.equimentid)
3360
-            this.getAllPlan()
3396
+            this.getAllPlanDetail(this.unitType, this.$route.query.bedid)
3397
+            this.getAllPlan(this.$route.query.bedid)
3361 3398
           }
3362 3399
         })
3363 3400
       },
@@ -3512,7 +3549,7 @@ export default {
3512 3549
         ChangeClass(this.equimentid, id).then(response => {
3513 3550
           if (response.data.state === 1) {
3514 3551
             var patients = response.data.data.patients
3515
-  
3552
+
3516 3553
             if (patients.is_infectious === 0) {
3517 3554
               this.userform.contagion = ''
3518 3555
             }
@@ -3659,14 +3696,14 @@ export default {
3659 3696
         var hyperfiltratio = this.userform.hyperfiltratio
3660 3697
         var hyperfiltratios = parseInt(hyperfiltratio)
3661 3698
         this.userform.hyperfiltratio = hyperfiltratios
3662
-  
3699
+
3663 3700
         if (this.userform.weight_loss === '') {
3664 3701
           this.userform.weight_loss = 0
3665 3702
         }
3666 3703
         var weightloss = this.userform.weight_loss
3667 3704
         var weidht = parseInt(weightloss)
3668 3705
         this.userform.weight_loss = weidht
3669
-  
3706
+
3670 3707
         if (this.userform.user_total === '0') {
3671 3708
           this.userform.user_total = 0
3672 3709
         }
@@ -3727,15 +3764,15 @@ export default {
3727 3764
         getUserRegister(id).then(response => {
3728 3765
           if (response.data.state === 1) {
3729 3766
             var information = response.data.data.information
3730
-            // console.log('使用登记', information)
3767
+            console.log('使用登记', information)
3731 3768
             // eslint-disable-next-line no-unused-vars
3732 3769
             var role = response.data.data.role
3733 3770
             // console.log('role', role)
3734 3771
             // eslint-disable-next-line eqeqeq
3735 3772
             var dislysis = response.data.data.dislysis
3736
-  
3773
+
3737 3774
             this.userform.id = information.id
3738
-            if (information.date == 0) {
3775
+            if (information.date === 0) {
3739 3776
               this.userform.date = moment(new Date()).format('YYYY-MM-DD')
3740 3777
             } else {
3741 3778
               this.userform.date = uParseTime(information.date, '{y}-{m}-{d}')
@@ -3796,7 +3833,7 @@ export default {
3796 3833
             this.userform.dialysis_name = information.dialysis_name
3797 3834
             this.userform.norms = information.norms
3798 3835
             this.userform.dialysis_concentration = information.dialysis_concentration
3799
-  
3836
+
3800 3837
             if (information.germ_checked === 0) {
3801 3838
               this.userform.germ_checked = false
3802 3839
             }
@@ -3808,7 +3845,7 @@ export default {
3808 3845
             if (information.germ_checked === 1) {
3809 3846
               this.userform.germ_checked = true
3810 3847
             }
3811
-  
3848
+
3812 3849
             this.userform.germ_name = information.germ_name
3813 3850
             this.userform.germ_number = information.germ_number
3814 3851
             if (information.clean === 1) {
@@ -4136,7 +4173,7 @@ export default {
4136 4173
       getAllEquitType() {
4137 4174
         getAllEquitType().then(response => {
4138 4175
           if (response.data.state === 1) {
4139
-            var equitname = response.data.data.equitname
4176
+            var equitname = response.data.data.mode
4140 4177
             this.DeviceType = equitname
4141 4178
           }
4142 4179
         })
@@ -4158,7 +4195,7 @@ export default {
4158 4195
         getAllpatient().then(response => {
4159 4196
           if (response.data.state === 1) {
4160 4197
             var allpatient = response.data.data.allpatient
4161
-  
4198
+
4162 4199
             this.patientName = allpatient
4163 4200
           }
4164 4201
         })
@@ -4167,9 +4204,9 @@ export default {
4167 4204
         getTimeWarning(id).then(response => {
4168 4205
           if (response.data.state === 1) {
4169 4206
             var information = response.data.data.informations
4170
-            console.log('码字', information)
4171
-            console.log('当前时间', this.getTimestamp(this.userform.date))
4172
-            console.log('存入时间', information.stime)
4207
+            // console.log('码字', information)
4208
+            // console.log('当前时间', this.getTimestamp(this.userform.date))
4209
+            // console.log('存入时间', information.stime)
4173 4210
             var time = this.getTimestamp(this.userform.date) - information.stime
4174 4211
             console.log('时间', time)
4175 4212
             // if (time < 2678400) {
@@ -4181,7 +4218,7 @@ export default {
4181 4218
             // if (timetwo < 2678400) {
4182 4219
             //  this.warnShowTwo = false
4183 4220
             // }
4184
-  
4221
+
4185 4222
             var clean = response.data.data.clean
4186 4223
             // var timethree = this.getTimestamp(this.userform.date) - clean.stime
4187 4224
             // if (timethree < 2678400) {
@@ -4198,23 +4235,32 @@ export default {
4198 4235
       // 通过自组建传值改变表格数据
4199 4236
       getPlanData(data) {
4200 4237
         if (data === 1) {
4201
-          this.getAllPlanDetail(this.equimentid)
4238
+          this.getAllPlanDetail(this.unitType, this.$route.query.bedid)
4202 4239
         }
4240
+      },
4241
+      getAllMode() {
4242
+        getAllMode().then(response => {
4243
+          var mode = response.data.data.mode
4244
+          this.deviceMode = mode
4245
+        })
4203 4246
       }
4204 4247
     },
4205 4248
     created() {
4206 4249
       this.getAllSubregion()
4207 4250
       this.getAllMachine()
4208 4251
       var index = this.$route.query.index
4252
+      var bedid = this.$route.query.bedid
4209 4253
       // var id = this.$route.query.id
4210 4254
       // this.equimentid = id
4211
-      this.getAllPlan()
4255
+      this.bedid = bedid
4256
+      this.getAllPlan(bedid)
4212 4257
       this.getAllEquimentName()
4213 4258
       this.getAllOrganization()
4214 4259
       this.getOrgName()
4215 4260
       this.getAllEquitType()
4216 4261
       this.getAllpatient()
4217
-    }
4262
+      this.getAllMode()
4263
+  }
4218 4264
   }
4219 4265
 </script>
4220 4266
 <style lang="scss" scoped>
@@ -4250,7 +4296,7 @@ export default {
4250 4296
       width: 460px;
4251 4297
       height: 50px;
4252 4298
       // border:solid 1px red;
4253
-      margin-left:780px;
4299
+      margin-left:650px;
4254 4300
     }
4255 4301
 
4256 4302
   .zClass{
@@ -4280,7 +4326,7 @@ export default {
4280 4326
 
4281 4327
    .b{
4282 4328
     .el-button{
4283
-      margin-left: 850px;
4329
+      margin-left: 820px;
4284 4330
       margin-bottom: 10px;
4285 4331
     }
4286 4332
    }
@@ -4290,6 +4336,11 @@ export default {
4290 4336
        width:190px;
4291 4337
      }
4292 4338
    }
4339
+   .st{
4340
+     .el-form-item__label{
4341
+       width:-10px;
4342
+     }
4343
+   }
4293 4344
    .main{
4294 4345
      position: relative;
4295 4346
      .newButtonOne{
@@ -4303,7 +4354,7 @@ export default {
4303 4354
       // border: solid 1px red;
4304 4355
       height: 50px;
4305 4356
       width: 400px;
4306
-      margin-left: 750px;
4357
+      margin-left: 650px;
4307 4358
     }
4308 4359
   // .el-form-item__label {
4309 4360
   //   width: 130px;

+ 64 - 62
src/xt_pages/management/index.vue Ver arquivo

@@ -101,7 +101,7 @@
101 101
           <template slot-scope="scope">{{ scope.row.device_name }}</template>
102 102
         </el-table-column>
103 103
         <el-table-column label="设备型号" align="center">
104
-          <template slot-scope="scope">{{ scope.row.unit_type }}</template>
104
+          <template slot-scope="scope">{{ scope.row.device_mode }}</template>
105 105
         </el-table-column>
106 106
 
107 107
         <el-table-column label="分区" align="center">
@@ -123,7 +123,7 @@
123 123
         <el-table-column label="操作" align="center">
124 124
           <template slot-scope="scope">
125 125
             <el-button
126
-              @click="handleClick(scope.row.id, scope.$index)"
126
+              @click="handleClick(scope.row.id, scope.$index, scope.row.bed_id)"
127 127
               type="text"
128 128
               size="small"
129 129
               >查看
@@ -152,12 +152,12 @@
152 152
 </template>
153 153
 
154 154
 <script>
155
-import BreadCrumb from "../components/bread-crumb";
156
-import { getAllMachineInfo, getAllSubregion } from "@/api/manage";
157
-import ManageForm from "./components/ManageForm";
155
+import BreadCrumb from '../components/bread-crumb'
156
+import { getAllMachineInfo, getAllSubregion } from '@/api/manage'
157
+import ManageForm from './components/ManageForm'
158 158
 
159 159
 export default {
160
-  name: "index.vue",
160
+  name: 'index.vue',
161 161
   components: {
162 162
     BreadCrumb,
163 163
     ManageForm
@@ -165,75 +165,75 @@ export default {
165 165
   data() {
166 166
     return {
167 167
       crumbs: [
168
-        { path: false, name: "设备管理" },
169
-        { path: false, name: "设备管理" }
168
+        { path: false, name: '设备管理' },
169
+        { path: false, name: '设备管理' }
170 170
       ],
171
-      searchKey: "",
172
-      zones: [{ id: 0, name: "全部" }],
171
+      searchKey: '',
172
+      zones: [{ id: 0, name: '全部' }],
173 173
       schedulType: 0,
174 174
       schedulTypeone: 0,
175 175
       schedulTypetwo: 0,
176 176
       DeviceType: [
177
-        { id: 0, name: "全部" },
178
-        { id: 1, name: "透析机" },
179
-        { id: 2, name: "水处理机" },
180
-        { id: 3, name: "其他" }
177
+        { id: 0, name: '全部' },
178
+        { id: 1, name: '透析机' },
179
+        { id: 2, name: '水处理机' },
180
+        { id: 3, name: '其他' }
181 181
       ],
182 182
 
183 183
       AllStatus: [
184
-        { id: 0, name: "全部" },
185
-        { id: 1, name: "使用机" },
186
-        { id: 2, name: "备用机" },
187
-        { id: 3, name: "急诊机" },
188
-        { id: 4, name: "报废机" }
184
+        { id: 0, name: '全部' },
185
+        { id: 1, name: '使用机' },
186
+        { id: 2, name: '备用机' },
187
+        { id: 3, name: '急诊机' },
188
+        { id: 4, name: '报废机' }
189 189
       ],
190 190
       tableData: [],
191 191
       listQuery: {
192 192
         page: 1,
193 193
         limit: 10,
194
-        searchKey: "",
195
-        zoneid: "",
196
-        equipmentid: "",
197
-        statusid: ""
194
+        searchKey: '',
195
+        zoneid: '',
196
+        equipmentid: '',
197
+        statusid: ''
198 198
       },
199 199
       total: 0
200
-    };
200
+    }
201 201
   },
202 202
   methods: {
203 203
     getAllSubregion() {
204 204
       getAllSubregion().then(response => {
205 205
         if (response.data.state === 1) {
206
-          var zone = response.data.data.zones;
207
-          var zones = [{ id: 0, name: "全部" }];
206
+          var zone = response.data.data.zones
207
+          var zones = [{ id: 0, name: '全部' }]
208 208
           for (let i = 0; i < zone.length; i++) {
209
-            const item = zone[i];
210
-            zones.push({ id: item.id, name: item.name });
209
+            const item = zone[i]
210
+            zones.push({ id: item.id, name: item.name })
211 211
           }
212 212
           // console.log('zones', zones)
213
-          this.zones = zones;
213
+          this.zones = zones
214 214
         }
215
-      });
215
+      })
216 216
     },
217 217
     selectSchedulType(scheduleType) {
218
-      this.schedulType = scheduleType;
219
-      this.listQuery.zoneid = scheduleType;
220
-      this.getAllMachineInfo();
218
+      this.schedulType = scheduleType
219
+      this.listQuery.zoneid = scheduleType
220
+      this.getAllMachineInfo()
221 221
     },
222 222
     selectSchedulTypeOne(scheduleType) {
223
-      this.schedulTypeone = scheduleType;
224
-      this.listQuery.equipmentid = scheduleType;
225
-      this.getAllMachineInfo();
223
+      this.schedulTypeone = scheduleType
224
+      this.listQuery.equipmentid = scheduleType
225
+      this.getAllMachineInfo()
226 226
     },
227 227
     selectSchedulTypeTwo(scheduleType) {
228
-      this.schedulTypetwo = scheduleType;
229
-      this.listQuery.statusid = scheduleType;
230
-      this.getAllMachineInfo();
228
+      this.schedulTypetwo = scheduleType
229
+      this.listQuery.statusid = scheduleType
230
+      this.getAllMachineInfo()
231 231
     },
232 232
     seahcerMacherInfo() {
233
-      this.getAllMachineInfo();
233
+      this.getAllMachineInfo()
234 234
     },
235 235
     AddManage() {
236
-      this.$refs.manageForm.open();
236
+      this.$refs.manageForm.open()
237 237
     },
238 238
     getAllMachineInfo() {
239 239
       getAllMachineInfo(
@@ -245,59 +245,61 @@ export default {
245 245
         this.listQuery.statusid
246 246
       ).then(response => {
247 247
         if (response.data.state === 1) {
248
-          var addmahcer = response.data.data.addmahcer;
248
+          var addmahcer = response.data.data.addmahcer
249 249
           for (let index = 0; index < addmahcer.length; index++) {
250 250
             if (addmahcer[index].device_type === 1) {
251
-              addmahcer[index].device_type = "透析机";
251
+              addmahcer[index].device_type = '透析机'
252 252
             }
253 253
             if (addmahcer[index].device_type === 2) {
254
-              addmahcer[index].device_type = "水处理机";
254
+              addmahcer[index].device_type = '水处理机'
255 255
             }
256 256
 
257 257
             if (addmahcer[index].device_type === 3) {
258
-              addmahcer[index].device_type = "其他";
258
+              addmahcer[index].device_type = '其他'
259 259
             }
260 260
 
261 261
             if (addmahcer[index].machine_status === 1) {
262
-              addmahcer[index].machine_status = "使用机";
262
+              addmahcer[index].machine_status = '使用机'
263 263
             }
264 264
             if (addmahcer[index].machine_status === 2) {
265
-              addmahcer[index].machine_status = "备用机";
265
+              addmahcer[index].machine_status = '备用机'
266 266
             }
267 267
             if (addmahcer[index].machine_status === 3) {
268
-              addmahcer[index].machine_status = "急诊机";
268
+              addmahcer[index].machine_status = '急诊机'
269 269
             }
270 270
             if (addmahcer[index].machine_status === 4) {
271
-              addmahcer[index].machine_status = "报废机";
271
+              addmahcer[index].machine_status = '报废机'
272 272
             }
273 273
           }
274
-          this.tableData = addmahcer;
274
+          this.tableData = addmahcer
275 275
           // console.log('addmacher', addmahcer)
276
-          var total = response.data.data.total;
276
+          var total = response.data.data.total
277 277
           // console.log('total', total)
278
-          this.total = total;
278
+          this.total = total
279 279
         }
280
-      });
280
+      })
281 281
     },
282 282
     handleSizeChange(limit) {
283
-      this.listQuery.limit = limit;
284
-      this.getAllMachineInfo();
283
+      this.listQuery.limit = limit
284
+      this.getAllMachineInfo()
285 285
     },
286 286
     handleCurrentChange(page) {
287
-      this.listQuery.page = page;
288
-      this.getAllMachineInfo();
287
+      this.listQuery.page = page
288
+      this.getAllMachineInfo()
289 289
     },
290
-    handleClick(id, index) {
291
-      this.$router.push({ path: '/device/home?index=' + index })
290
+    handleClick(id, index, bedid) {
291
+      this.$router.push({
292
+        path: '/device/home?index=' + index + '&' + 'bedid=' + bedid + '&' + 'id=' + id
293
+      })
292 294
       // this.$router.push({ path: '/device/home?index=' + index + '&' + 'id=' + id })
293 295
     }
294 296
   },
295 297
   created() {
296 298
     // 获取所有的分区
297
-    this.getAllSubregion();
298
-    this.getAllMachineInfo();
299
+    this.getAllSubregion()
300
+    this.getAllMachineInfo()
299 301
   }
300
-};
302
+}
301 303
 </script>
302 304
 
303 305
 <style scoped></style>

Diferenças do arquivo suprimidas por serem muito extensas
+ 3431 - 2709
src/xt_pages/user/doctorAdvice.vue


Diferenças do arquivo suprimidas por serem muito extensas
+ 1551 - 1095
src/xt_pages/workforce/components/tableData.vue