|
@@ -3,7 +3,7 @@
|
3
|
3
|
<el-dialog
|
4
|
4
|
title="新增设备"
|
5
|
5
|
:visible.sync="dialogVisible"
|
6
|
|
- width="52%"
|
|
6
|
+ width="70%"
|
7
|
7
|
align="center"
|
8
|
8
|
>
|
9
|
9
|
<el-form ref="form" :model="form" :rules="rules">
|
|
@@ -122,7 +122,7 @@
|
122
|
122
|
placeholder="请选择"
|
123
|
123
|
format="yyyy-MM-dd"
|
124
|
124
|
value-format="yyyy-MM-dd"
|
125
|
|
- style="width:140px"
|
|
125
|
+ style="width:135px"
|
126
|
126
|
></el-date-picker>
|
127
|
127
|
</el-form-item>
|
128
|
128
|
</el-col>
|
|
@@ -338,80 +338,80 @@ import {
|
338
|
338
|
SaveManageInfo,
|
339
|
339
|
SaveManageInfoTwo,
|
340
|
340
|
getAllMode
|
341
|
|
-} from '@/api/manage'
|
|
341
|
+} from "@/api/manage";
|
342
|
342
|
const treatmentmodes = [
|
343
|
|
- 'HD',
|
344
|
|
- 'HDF',
|
345
|
|
- 'HD+HP',
|
346
|
|
- 'HP',
|
347
|
|
- 'HF',
|
348
|
|
- 'SCUF',
|
349
|
|
- 'IUF',
|
350
|
|
- 'HFHD',
|
351
|
|
- 'HFHD+HP',
|
352
|
|
- 'PHF',
|
353
|
|
- 'HFR',
|
354
|
|
- 'HDF+HP',
|
355
|
|
- 'CRRT',
|
356
|
|
- '腹水回输'
|
357
|
|
-]
|
|
343
|
+ "HD",
|
|
344
|
+ "HDF",
|
|
345
|
+ "HD+HP",
|
|
346
|
+ "HP",
|
|
347
|
+ "HF",
|
|
348
|
+ "SCUF",
|
|
349
|
+ "IUF",
|
|
350
|
+ "HFHD",
|
|
351
|
+ "HFHD+HP",
|
|
352
|
+ "PHF",
|
|
353
|
+ "HFR",
|
|
354
|
+ "HDF+HP",
|
|
355
|
+ "CRRT",
|
|
356
|
+ "腹水回输"
|
|
357
|
+];
|
358
|
358
|
export default {
|
359
|
|
- name: 'ManageForm',
|
|
359
|
+ name: "ManageForm",
|
360
|
360
|
data() {
|
361
|
361
|
return {
|
362
|
362
|
dialogVisible: false,
|
363
|
|
- checked1: '',
|
|
363
|
+ checked1: "",
|
364
|
364
|
form: {
|
365
|
|
- serial_number: '', // 序列号
|
|
365
|
+ serial_number: "", // 序列号
|
366
|
366
|
device_type: 1, // 设备类型
|
367
|
|
- bed_number: '', // 床位号
|
368
|
|
- device_name: '', // 设备名称
|
369
|
|
- manufacture_factory: '', // 生产厂家
|
370
|
|
- service_manufacturer: '', // 维修厂家
|
371
|
|
- unit_type: '', // 设备型号
|
372
|
|
- use_section: '', // 使用科室
|
373
|
|
- section_number: '', // 科室编号
|
374
|
|
- buy_date: '', // 购买日期
|
375
|
|
- install_date: '', // 安装日期
|
376
|
|
- start_date: '', // 启用日期
|
377
|
|
- maintenance_engineer: '', // 维修工程师
|
378
|
|
- telephone: '', // 联系电话
|
379
|
|
- guarantee_date: '', // 保修日期
|
|
367
|
+ bed_number: "", // 床位号
|
|
368
|
+ device_name: "", // 设备名称
|
|
369
|
+ manufacture_factory: "", // 生产厂家
|
|
370
|
+ service_manufacturer: "", // 维修厂家
|
|
371
|
+ unit_type: "", // 设备型号
|
|
372
|
+ use_section: "", // 使用科室
|
|
373
|
+ section_number: "", // 科室编号
|
|
374
|
+ buy_date: "", // 购买日期
|
|
375
|
+ install_date: "", // 安装日期
|
|
376
|
+ start_date: "", // 启用日期
|
|
377
|
+ maintenance_engineer: "", // 维修工程师
|
|
378
|
+ telephone: "", // 联系电话
|
|
379
|
+ guarantee_date: "", // 保修日期
|
380
|
380
|
machine_status: 1, // 机器状态
|
381
|
|
- user_total: '', // 初次使用次数
|
382
|
|
- Disinfection_mode: '', // 消毒方式
|
383
|
|
- remarks: '', // 备注
|
384
|
|
- rubbish_date: '', // 报废日期
|
385
|
|
- rubbish_reason: '', // 报废原因
|
386
|
|
- user_year: '', // 使用年限
|
387
|
|
- work_time: '', // 工作时长
|
388
|
|
- revers_mode: '', // 反渗模式
|
|
381
|
+ user_total: "", // 初次使用次数
|
|
382
|
+ Disinfection_mode: "", // 消毒方式
|
|
383
|
+ remarks: "", // 备注
|
|
384
|
+ rubbish_date: "", // 报废日期
|
|
385
|
+ rubbish_reason: "", // 报废原因
|
|
386
|
+ user_year: "", // 使用年限
|
|
387
|
+ work_time: "", // 工作时长
|
|
388
|
+ revers_mode: "", // 反渗模式
|
389
|
389
|
treat_mode: [],
|
390
|
390
|
treat_type: [], // 治疗模式
|
391
|
|
- beds: ''
|
|
391
|
+ beds: ""
|
392
|
392
|
},
|
393
|
393
|
forms: {
|
394
|
|
- beds: ''
|
|
394
|
+ beds: ""
|
395
|
395
|
},
|
396
|
396
|
deviceType: [],
|
397
|
397
|
bedNumber: [],
|
398
|
398
|
machineStatus: [
|
399
|
|
- { id: 1, name: '使用机' },
|
400
|
|
- { id: 2, name: '备用机' },
|
401
|
|
- { id: 3, name: '急诊机' },
|
402
|
|
- { id: 4, name: '报废机' }
|
|
399
|
+ { id: 1, name: "使用机" },
|
|
400
|
+ { id: 2, name: "备用机" },
|
|
401
|
+ { id: 3, name: "急诊机" },
|
|
402
|
+ { id: 4, name: "报废机" }
|
403
|
403
|
],
|
404
|
404
|
DisinfectionMode: [
|
405
|
|
- { id: 0, name: '请选择' },
|
406
|
|
- { id: 1, name: '化学消毒' },
|
407
|
|
- { id: 2, name: '热消毒' },
|
408
|
|
- { id: 3, name: '化学消毒+热消毒' }
|
|
405
|
+ { id: 0, name: "请选择" },
|
|
406
|
+ { id: 1, name: "化学消毒" },
|
|
407
|
+ { id: 2, name: "热消毒" },
|
|
408
|
+ { id: 3, name: "化学消毒+热消毒" }
|
409
|
409
|
],
|
410
|
410
|
DisCardResion: [
|
411
|
|
- { id: 0, name: '请选择' },
|
412
|
|
- { id: 1, name: '超期限报废' },
|
413
|
|
- { id: 2, name: '故障报废' },
|
414
|
|
- { id: 3, name: '核定报废' }
|
|
411
|
+ { id: 0, name: "请选择" },
|
|
412
|
+ { id: 1, name: "超期限报废" },
|
|
413
|
+ { id: 2, name: "故障报废" },
|
|
414
|
+ { id: 3, name: "核定报废" }
|
415
|
415
|
],
|
416
|
416
|
checkAll: false,
|
417
|
417
|
isIndeterminate: true,
|
|
@@ -422,21 +422,21 @@ export default {
|
422
|
422
|
// { id: 3, name: 'ww' }
|
423
|
423
|
// ],
|
424
|
424
|
DeviceType: [
|
425
|
|
- { id: 1, name: '透析机' },
|
426
|
|
- { id: 2, name: '水处理机' },
|
427
|
|
- { id: 3, name: '其他' }
|
|
425
|
+ { id: 1, name: "透析机" },
|
|
426
|
+ { id: 2, name: "水处理机" },
|
|
427
|
+ { id: 3, name: "其他" }
|
428
|
428
|
],
|
429
|
429
|
reverseMode: [
|
430
|
|
- { id: 0, name: '请选择' },
|
431
|
|
- { id: 1, name: '单级反渗' },
|
432
|
|
- { id: 2, name: '双级反渗' }
|
|
430
|
+ { id: 0, name: "请选择" },
|
|
431
|
+ { id: 1, name: "单级反渗" },
|
|
432
|
+ { id: 2, name: "双级反渗" }
|
433
|
433
|
],
|
434
|
434
|
rules: {
|
435
|
|
- serial_number: [{ required: true, message: '请填写序列号' }],
|
436
|
|
- device_name: [{ required: true, message: '请填写设备名称' }],
|
437
|
|
- device_type: [{ required: true, message: '请填写设备类型' }],
|
438
|
|
- unit_type: [{ required: true, message: '请填写设备型号' }],
|
439
|
|
- bed_number: [{ required: true, message: '请填写机位号' }]
|
|
435
|
+ serial_number: [{ required: true, message: "请填写序列号" }],
|
|
436
|
+ device_name: [{ required: true, message: "请填写设备名称" }],
|
|
437
|
+ device_type: [{ required: true, message: "请填写设备类型" }],
|
|
438
|
+ unit_type: [{ required: true, message: "请填写设备型号" }],
|
|
439
|
+ bed_number: [{ required: true, message: "请填写机位号" }]
|
440
|
440
|
// treat_mode: [{ required: true, message: "请选择至少一种治疗模式" }]
|
441
|
441
|
},
|
442
|
442
|
DisinfectionShow: false,
|
|
@@ -451,155 +451,155 @@ export default {
|
451
|
451
|
buttonShowTwo: false,
|
452
|
452
|
buttonShowThree: false,
|
453
|
453
|
deviceMode: []
|
454
|
|
- }
|
|
454
|
+ };
|
455
|
455
|
},
|
456
|
456
|
methods: {
|
457
|
457
|
open: function() {
|
458
|
|
- this.dialogVisible = true
|
|
458
|
+ this.dialogVisible = true;
|
459
|
459
|
// this.resetForm("form");
|
460
|
460
|
},
|
461
|
461
|
changetreatmentmode(val) {
|
462
|
|
- const checkedCount = val.length
|
463
|
|
- this.checkAll = checkedCount === 14
|
464
|
|
- this.isIndeterminate = checkedCount > 0 && checkedCount < 14
|
|
462
|
+ const checkedCount = val.length;
|
|
463
|
+ this.checkAll = checkedCount === 14;
|
|
464
|
+ this.isIndeterminate = checkedCount > 0 && checkedCount < 14;
|
465
|
465
|
},
|
466
|
466
|
handleCheckAllChange(val) {
|
467
|
|
- this.form.treat_mode = val ? this.treatmentmode : []
|
468
|
|
- this.isIndeterminate = false
|
|
467
|
+ this.form.treat_mode = val ? this.treatmentmode : [];
|
|
468
|
+ this.isIndeterminate = false;
|
469
|
469
|
},
|
470
|
470
|
getAllSubregion() {
|
471
|
471
|
getAllSubregion().then(response => {
|
472
|
472
|
if (response.data.state === 1) {
|
473
|
|
- var zones = response.data.data.zones
|
474
|
|
- this.deviceType = zones
|
475
|
|
- var numbers = response.data.data.numbers
|
476
|
|
- var devicenumber = response.data.data.devicenumber
|
|
473
|
+ var zones = response.data.data.zones;
|
|
474
|
+ this.deviceType = zones;
|
|
475
|
+ var numbers = response.data.data.numbers;
|
|
476
|
+ var devicenumber = response.data.data.devicenumber;
|
477
|
477
|
// console.log('devicenumber$', devicenumber)
|
478
|
478
|
// var device = [{ bed_id: 0, bed_number: '请选择' }]
|
479
|
479
|
// for (let index = 0; index < devicenumber.length; index++) {
|
480
|
480
|
// const item = devicenumber[index]
|
481
|
481
|
// device.push({ bed_id: item.bed_id, bed_number: item.bed_number })
|
482
|
482
|
// }
|
483
|
|
- this.bedNumber = devicenumber
|
|
483
|
+ this.bedNumber = devicenumber;
|
484
|
484
|
}
|
485
|
|
- })
|
|
485
|
+ });
|
486
|
486
|
},
|
487
|
487
|
|
488
|
488
|
changeDeviceType(val) {
|
489
|
489
|
if (val === 1) {
|
490
|
|
- this.bedShow = true
|
491
|
|
- this.totalShow = true
|
492
|
|
- this.treatShow = true
|
493
|
|
- this.allShow = true
|
494
|
|
- this.bedShowTwo = false
|
495
|
|
- this.buttonShow = true
|
496
|
|
- this.buttonShowTwo = false
|
497
|
|
- this.buttonShowThree = false
|
|
490
|
+ this.bedShow = true;
|
|
491
|
+ this.totalShow = true;
|
|
492
|
+ this.treatShow = true;
|
|
493
|
+ this.allShow = true;
|
|
494
|
+ this.bedShowTwo = false;
|
|
495
|
+ this.buttonShow = true;
|
|
496
|
+ this.buttonShowTwo = false;
|
|
497
|
+ this.buttonShowThree = false;
|
498
|
498
|
}
|
499
|
499
|
|
500
|
500
|
if (val === 2) {
|
501
|
|
- this.totalShow = false
|
502
|
|
- this.DisinfectionShow = true
|
503
|
|
- this.allShow = false
|
504
|
|
- this.treatShow = false
|
505
|
|
- this.reverseShow = true
|
506
|
|
- this.bedShow = false
|
507
|
|
- this.bedShowTwo = true
|
508
|
|
- this.buttonShow = false
|
509
|
|
- this.buttonShowTwo = true
|
510
|
|
- this.buttonShowThree = false
|
|
501
|
+ this.totalShow = false;
|
|
502
|
+ this.DisinfectionShow = true;
|
|
503
|
+ this.allShow = false;
|
|
504
|
+ this.treatShow = false;
|
|
505
|
+ this.reverseShow = true;
|
|
506
|
+ this.bedShow = false;
|
|
507
|
+ this.bedShowTwo = true;
|
|
508
|
+ this.buttonShow = false;
|
|
509
|
+ this.buttonShowTwo = true;
|
|
510
|
+ this.buttonShowThree = false;
|
511
|
511
|
}
|
512
|
512
|
|
513
|
513
|
if (val === 3) {
|
514
|
|
- this.bedShow = false
|
515
|
|
- this.totalShow = false
|
516
|
|
- this.reverseShow = false
|
517
|
|
- this.allShow = false
|
518
|
|
- this.treatShow = false
|
519
|
|
- this.DisinfectionShow = false
|
520
|
|
- this.bedShowTwo = false
|
521
|
|
- this.buttonShow = false
|
522
|
|
- this.buttonShowTwo = false
|
523
|
|
- this.buttonShowThree = true
|
|
514
|
+ this.bedShow = false;
|
|
515
|
+ this.totalShow = false;
|
|
516
|
+ this.reverseShow = false;
|
|
517
|
+ this.allShow = false;
|
|
518
|
+ this.treatShow = false;
|
|
519
|
+ this.DisinfectionShow = false;
|
|
520
|
+ this.bedShowTwo = false;
|
|
521
|
+ this.buttonShow = false;
|
|
522
|
+ this.buttonShowTwo = false;
|
|
523
|
+ this.buttonShowThree = true;
|
524
|
524
|
}
|
525
|
525
|
},
|
526
|
526
|
changeMachineStatus(val) {
|
527
|
527
|
if (val === 4) {
|
528
|
|
- this.disa = false
|
|
528
|
+ this.disa = false;
|
529
|
529
|
} else {
|
530
|
|
- this.disa = true
|
531
|
|
- this.form.rubbish_date = ''
|
532
|
|
- this.form.rubbish_reason = ''
|
|
530
|
+ this.disa = true;
|
|
531
|
+ this.form.rubbish_date = "";
|
|
532
|
+ this.form.rubbish_reason = "";
|
533
|
533
|
}
|
534
|
534
|
},
|
535
|
535
|
SaveManageInfoThree(formName) {
|
536
|
|
- if (this.form.bed_number === '') {
|
537
|
|
- this.form.bed_number = 0
|
|
536
|
+ if (this.form.bed_number === "") {
|
|
537
|
+ this.form.bed_number = 0;
|
538
|
538
|
}
|
539
|
|
- const arr1 = []
|
|
539
|
+ const arr1 = [];
|
540
|
540
|
this.form.treat_mode.map((item, index) => {
|
541
|
|
- const obj = {}
|
542
|
|
- if (item === 'HD') {
|
543
|
|
- obj.id = 1
|
|
541
|
+ const obj = {};
|
|
542
|
+ if (item === "HD") {
|
|
543
|
+ obj.id = 1;
|
544
|
544
|
}
|
545
|
|
- if (item === 'HDF') {
|
546
|
|
- obj.id = 2
|
|
545
|
+ if (item === "HDF") {
|
|
546
|
+ obj.id = 2;
|
547
|
547
|
}
|
548
|
|
- if (item === 'HD+HP') {
|
549
|
|
- obj.id = 3
|
|
548
|
+ if (item === "HD+HP") {
|
|
549
|
+ obj.id = 3;
|
550
|
550
|
}
|
551
|
|
- if (item === 'HP') {
|
552
|
|
- obj.id = 4
|
|
551
|
+ if (item === "HP") {
|
|
552
|
+ obj.id = 4;
|
553
|
553
|
}
|
554
|
|
- if (item === 'HF') {
|
555
|
|
- obj.id = 5
|
|
554
|
+ if (item === "HF") {
|
|
555
|
+ obj.id = 5;
|
556
|
556
|
}
|
557
|
|
- if (item === 'SCUF') {
|
558
|
|
- obj.id = 6
|
|
557
|
+ if (item === "SCUF") {
|
|
558
|
+ obj.id = 6;
|
559
|
559
|
}
|
560
|
|
- if (item === 'IUF') {
|
561
|
|
- obj.id = 7
|
|
560
|
+ if (item === "IUF") {
|
|
561
|
+ obj.id = 7;
|
562
|
562
|
}
|
563
|
|
- if (item === 'HFHD') {
|
564
|
|
- obj.id = 8
|
|
563
|
+ if (item === "HFHD") {
|
|
564
|
+ obj.id = 8;
|
565
|
565
|
}
|
566
|
|
- if (item === 'HFHD+HP') {
|
567
|
|
- obj.id = 9
|
|
566
|
+ if (item === "HFHD+HP") {
|
|
567
|
+ obj.id = 9;
|
568
|
568
|
}
|
569
|
|
- if (item === 'PHF') {
|
570
|
|
- obj.id = 10
|
|
569
|
+ if (item === "PHF") {
|
|
570
|
+ obj.id = 10;
|
571
|
571
|
}
|
572
|
|
- if (item === 'HFR') {
|
573
|
|
- obj.id = 11
|
|
572
|
+ if (item === "HFR") {
|
|
573
|
+ obj.id = 11;
|
574
|
574
|
}
|
575
|
|
- if (item === 'HDF+HP') {
|
576
|
|
- obj.id = 12
|
|
575
|
+ if (item === "HDF+HP") {
|
|
576
|
+ obj.id = 12;
|
577
|
577
|
}
|
578
|
|
- if (item === 'CRRT') {
|
579
|
|
- obj.id = 13
|
|
578
|
+ if (item === "CRRT") {
|
|
579
|
+ obj.id = 13;
|
580
|
580
|
}
|
581
|
|
- if (item === '腹水回输') {
|
582
|
|
- obj.id = 14
|
|
581
|
+ if (item === "腹水回输") {
|
|
582
|
+ obj.id = 14;
|
583
|
583
|
}
|
584
|
|
- arr1.push(obj.id)
|
585
|
|
- })
|
|
584
|
+ arr1.push(obj.id);
|
|
585
|
+ });
|
586
|
586
|
// console.log('arrr1', arr1)
|
587
|
|
- this.form.treat_type = arr1
|
|
587
|
+ this.form.treat_type = arr1;
|
588
|
588
|
|
589
|
|
- var device_type = this.form.device_type
|
590
|
|
- var device_types = parseInt(device_type)
|
591
|
|
- this.form.device_type = device_types
|
|
589
|
+ var device_type = this.form.device_type;
|
|
590
|
+ var device_types = parseInt(device_type);
|
|
591
|
+ this.form.device_type = device_types;
|
592
|
592
|
|
593
|
|
- if (this.form.rubbish_reason === '') {
|
594
|
|
- this.form.rubbish_reason = 0
|
|
593
|
+ if (this.form.rubbish_reason === "") {
|
|
594
|
+ this.form.rubbish_reason = 0;
|
595
|
595
|
}
|
596
|
|
- var rubbish_reason = this.form.rubbish_reason
|
597
|
|
- var rubbish_reasons = parseInt(rubbish_reason)
|
598
|
|
- this.form.rubbish_reason = rubbish_reasons
|
|
596
|
+ var rubbish_reason = this.form.rubbish_reason;
|
|
597
|
+ var rubbish_reasons = parseInt(rubbish_reason);
|
|
598
|
+ this.form.rubbish_reason = rubbish_reasons;
|
599
|
599
|
|
600
|
|
- var machine_status = this.form.machine_status
|
601
|
|
- var machine_statuss = parseInt(machine_status)
|
602
|
|
- this.form.machine_status = machine_statuss
|
|
600
|
+ var machine_status = this.form.machine_status;
|
|
601
|
+ var machine_statuss = parseInt(machine_status);
|
|
602
|
+ this.form.machine_status = machine_statuss;
|
603
|
603
|
|
604
|
604
|
// if (this.form.bed_number === '') {
|
605
|
605
|
// this.form.bed_number = 0
|
|
@@ -607,116 +607,116 @@ export default {
|
607
|
607
|
// var bed_numbers = this.form.bed_number
|
608
|
608
|
// var bed_numberss = parseInt(bed_numbers)
|
609
|
609
|
// this.form.bed_number = bed_numberss
|
610
|
|
- console.log('购买日期', this.form.buy_date)
|
|
610
|
+ console.log("购买日期", this.form.buy_date);
|
611
|
611
|
|
612
|
|
- if (this.form.Disinfection_mode === '') {
|
613
|
|
- this.form.Disinfection_mode = 0
|
|
612
|
+ if (this.form.Disinfection_mode === "") {
|
|
613
|
+ this.form.Disinfection_mode = 0;
|
614
|
614
|
}
|
615
|
|
- var disinfecction_modes = this.form.Disinfection_mode
|
616
|
|
- var disinfecction_modess = parseInt(disinfecction_modes)
|
617
|
|
- this.form.Disinfection_mode = disinfecction_modess
|
|
615
|
+ var disinfecction_modes = this.form.Disinfection_mode;
|
|
616
|
+ var disinfecction_modess = parseInt(disinfecction_modes);
|
|
617
|
+ this.form.Disinfection_mode = disinfecction_modess;
|
618
|
618
|
|
619
|
|
- if (this.form.revers_mode === '') {
|
620
|
|
- this.form.revers_mode = 0
|
|
619
|
+ if (this.form.revers_mode === "") {
|
|
620
|
+ this.form.revers_mode = 0;
|
621
|
621
|
}
|
622
|
622
|
|
623
|
623
|
this.$refs[formName].validate(valid => {
|
624
|
624
|
if (valid) {
|
625
|
625
|
SaveManageInfo(this.form).then(response => {
|
626
|
626
|
if (response.data.state === 1) {
|
627
|
|
- var addmacher = response.data.data.addmacher
|
628
|
|
- this.dialogVisible = false
|
629
|
|
- this.$message.success('保存成功')
|
630
|
|
- this.form.bed_number = ''
|
631
|
|
- this.form.serial_number = ''
|
632
|
|
- this.form.device_name = ''
|
633
|
|
- this.form.manufacture_factory = ''
|
634
|
|
- this.form.service_manufacturer = ''
|
635
|
|
- this.form.use_section = ''
|
636
|
|
- this.form.section_number = ''
|
637
|
|
- this.form.maintenance_engineer = ''
|
638
|
|
- this.form.telephone = ''
|
639
|
|
- this.form.user_total = ''
|
640
|
|
- this.form.remarks = ''
|
641
|
|
- this.form.user_year = ''
|
642
|
|
- this.form.work_time = ''
|
643
|
|
- this.form.unit_type = ''
|
644
|
|
- this.getAllSubregion()
|
645
|
|
- this.$emit('getAllMachineInfo')
|
646
|
|
- this.$forceUpdate()
|
|
627
|
+ var addmacher = response.data.data.addmacher;
|
|
628
|
+ this.dialogVisible = false;
|
|
629
|
+ this.$message.success("保存成功");
|
|
630
|
+ this.form.bed_number = "";
|
|
631
|
+ this.form.serial_number = "";
|
|
632
|
+ this.form.device_name = "";
|
|
633
|
+ this.form.manufacture_factory = "";
|
|
634
|
+ this.form.service_manufacturer = "";
|
|
635
|
+ this.form.use_section = "";
|
|
636
|
+ this.form.section_number = "";
|
|
637
|
+ this.form.maintenance_engineer = "";
|
|
638
|
+ this.form.telephone = "";
|
|
639
|
+ this.form.user_total = "";
|
|
640
|
+ this.form.remarks = "";
|
|
641
|
+ this.form.user_year = "";
|
|
642
|
+ this.form.work_time = "";
|
|
643
|
+ this.form.unit_type = "";
|
|
644
|
+ this.getAllSubregion();
|
|
645
|
+ this.$emit("getAllMachineInfo");
|
|
646
|
+ this.$forceUpdate();
|
647
|
647
|
} else {
|
648
|
|
- this.$message.error('添加失败')
|
|
648
|
+ this.$message.error("添加失败");
|
649
|
649
|
}
|
650
|
|
- })
|
|
650
|
+ });
|
651
|
651
|
}
|
652
|
|
- })
|
|
652
|
+ });
|
653
|
653
|
},
|
654
|
654
|
|
655
|
655
|
SaveManageInfo(formName) {
|
656
|
|
- const arr1 = []
|
|
656
|
+ const arr1 = [];
|
657
|
657
|
this.form.treat_mode.map((item, index) => {
|
658
|
|
- const obj = {}
|
659
|
|
- if (item === 'HD') {
|
660
|
|
- obj.id = 1
|
|
658
|
+ const obj = {};
|
|
659
|
+ if (item === "HD") {
|
|
660
|
+ obj.id = 1;
|
661
|
661
|
}
|
662
|
|
- if (item === 'HDF') {
|
663
|
|
- obj.id = 2
|
|
662
|
+ if (item === "HDF") {
|
|
663
|
+ obj.id = 2;
|
664
|
664
|
}
|
665
|
|
- if (item === 'HD+HP') {
|
666
|
|
- obj.id = 3
|
|
665
|
+ if (item === "HD+HP") {
|
|
666
|
+ obj.id = 3;
|
667
|
667
|
}
|
668
|
|
- if (item === 'HP') {
|
669
|
|
- obj.id = 4
|
|
668
|
+ if (item === "HP") {
|
|
669
|
+ obj.id = 4;
|
670
|
670
|
}
|
671
|
|
- if (item === 'HF') {
|
672
|
|
- obj.id = 5
|
|
671
|
+ if (item === "HF") {
|
|
672
|
+ obj.id = 5;
|
673
|
673
|
}
|
674
|
|
- if (item === 'SCUF') {
|
675
|
|
- obj.id = 6
|
|
674
|
+ if (item === "SCUF") {
|
|
675
|
+ obj.id = 6;
|
676
|
676
|
}
|
677
|
|
- if (item === 'IUF') {
|
678
|
|
- obj.id = 7
|
|
677
|
+ if (item === "IUF") {
|
|
678
|
+ obj.id = 7;
|
679
|
679
|
}
|
680
|
|
- if (item === 'HFHD') {
|
681
|
|
- obj.id = 8
|
|
680
|
+ if (item === "HFHD") {
|
|
681
|
+ obj.id = 8;
|
682
|
682
|
}
|
683
|
|
- if (item === 'HFHD+HP') {
|
684
|
|
- obj.id = 9
|
|
683
|
+ if (item === "HFHD+HP") {
|
|
684
|
+ obj.id = 9;
|
685
|
685
|
}
|
686
|
|
- if (item === 'PHF') {
|
687
|
|
- obj.id = 10
|
|
686
|
+ if (item === "PHF") {
|
|
687
|
+ obj.id = 10;
|
688
|
688
|
}
|
689
|
|
- if (item === 'HFR') {
|
690
|
|
- obj.id = 11
|
|
689
|
+ if (item === "HFR") {
|
|
690
|
+ obj.id = 11;
|
691
|
691
|
}
|
692
|
|
- if (item === 'HDF+HP') {
|
693
|
|
- obj.id = 12
|
|
692
|
+ if (item === "HDF+HP") {
|
|
693
|
+ obj.id = 12;
|
694
|
694
|
}
|
695
|
|
- if (item === 'CRRT') {
|
696
|
|
- obj.id = 13
|
|
695
|
+ if (item === "CRRT") {
|
|
696
|
+ obj.id = 13;
|
697
|
697
|
}
|
698
|
|
- if (item === '腹水回输') {
|
699
|
|
- obj.id = 14
|
|
698
|
+ if (item === "腹水回输") {
|
|
699
|
+ obj.id = 14;
|
700
|
700
|
}
|
701
|
|
- arr1.push(obj.id)
|
702
|
|
- })
|
|
701
|
+ arr1.push(obj.id);
|
|
702
|
+ });
|
703
|
703
|
// console.log('arrr1', arr1)
|
704
|
|
- this.form.treat_type = arr1
|
|
704
|
+ this.form.treat_type = arr1;
|
705
|
705
|
|
706
|
|
- var device_type = this.form.device_type
|
707
|
|
- var device_types = parseInt(device_type)
|
708
|
|
- this.form.device_type = device_types
|
|
706
|
+ var device_type = this.form.device_type;
|
|
707
|
+ var device_types = parseInt(device_type);
|
|
708
|
+ this.form.device_type = device_types;
|
709
|
709
|
|
710
|
|
- if (this.form.rubbish_reason === '') {
|
711
|
|
- this.form.rubbish_reason = 0
|
|
710
|
+ if (this.form.rubbish_reason === "") {
|
|
711
|
+ this.form.rubbish_reason = 0;
|
712
|
712
|
}
|
713
|
|
- var rubbish_reason = this.form.rubbish_reason
|
714
|
|
- var rubbish_reasons = parseInt(rubbish_reason)
|
715
|
|
- this.form.rubbish_reason = rubbish_reasons
|
|
713
|
+ var rubbish_reason = this.form.rubbish_reason;
|
|
714
|
+ var rubbish_reasons = parseInt(rubbish_reason);
|
|
715
|
+ this.form.rubbish_reason = rubbish_reasons;
|
716
|
716
|
|
717
|
|
- var machine_status = this.form.machine_status
|
718
|
|
- var machine_statuss = parseInt(machine_status)
|
719
|
|
- this.form.machine_status = machine_statuss
|
|
717
|
+ var machine_status = this.form.machine_status;
|
|
718
|
+ var machine_statuss = parseInt(machine_status);
|
|
719
|
+ this.form.machine_status = machine_statuss;
|
720
|
720
|
|
721
|
721
|
// if (this.form.bed_number === '') {
|
722
|
722
|
// this.form.bed_number = 0
|
|
@@ -724,113 +724,113 @@ export default {
|
724
|
724
|
// var bed_numbers = this.form.bed_number
|
725
|
725
|
// var bed_numberss = parseInt(bed_numbers)
|
726
|
726
|
// this.form.bed_number = bed_numberss
|
727
|
|
- console.log('购买日期', this.form.buy_date)
|
|
727
|
+ console.log("购买日期", this.form.buy_date);
|
728
|
728
|
|
729
|
|
- if (this.form.Disinfection_mode === '') {
|
730
|
|
- this.form.Disinfection_mode = 0
|
|
729
|
+ if (this.form.Disinfection_mode === "") {
|
|
730
|
+ this.form.Disinfection_mode = 0;
|
731
|
731
|
}
|
732
|
|
- var disinfecction_modes = this.form.Disinfection_mode
|
733
|
|
- var disinfecction_modess = parseInt(disinfecction_modes)
|
734
|
|
- this.form.Disinfection_mode = disinfecction_modess
|
|
732
|
+ var disinfecction_modes = this.form.Disinfection_mode;
|
|
733
|
+ var disinfecction_modess = parseInt(disinfecction_modes);
|
|
734
|
+ this.form.Disinfection_mode = disinfecction_modess;
|
735
|
735
|
|
736
|
|
- if (this.form.revers_mode === '') {
|
737
|
|
- this.form.revers_mode = 0
|
|
736
|
+ if (this.form.revers_mode === "") {
|
|
737
|
+ this.form.revers_mode = 0;
|
738
|
738
|
}
|
739
|
739
|
this.$refs[formName].validate(valid => {
|
740
|
740
|
if (valid) {
|
741
|
741
|
SaveManageInfo(this.form).then(response => {
|
742
|
742
|
if (response.data.state === 1) {
|
743
|
|
- var addmacher = response.data.data.addmacher
|
744
|
|
- this.dialogVisible = false
|
745
|
|
- this.$message.success('保存成功')
|
746
|
|
- this.form.bed_number = ''
|
747
|
|
- this.form.serial_number = ''
|
748
|
|
- this.form.device_name = ''
|
749
|
|
- this.form.manufacture_factory = ''
|
750
|
|
- this.form.service_manufacturer = ''
|
751
|
|
- this.form.use_section = ''
|
752
|
|
- this.form.section_number = ''
|
753
|
|
- this.form.maintenance_engineer = ''
|
754
|
|
- this.form.telephone = ''
|
755
|
|
- this.form.user_total = ''
|
756
|
|
- this.form.remarks = ''
|
757
|
|
- this.form.user_year = ''
|
758
|
|
- this.form.work_time = ''
|
759
|
|
- this.form.unit_type = ''
|
760
|
|
- this.getAllSubregion()
|
761
|
|
- this.$emit('getAllMachineInfo')
|
762
|
|
- this.$forceUpdate()
|
|
743
|
+ var addmacher = response.data.data.addmacher;
|
|
744
|
+ this.dialogVisible = false;
|
|
745
|
+ this.$message.success("保存成功");
|
|
746
|
+ this.form.bed_number = "";
|
|
747
|
+ this.form.serial_number = "";
|
|
748
|
+ this.form.device_name = "";
|
|
749
|
+ this.form.manufacture_factory = "";
|
|
750
|
+ this.form.service_manufacturer = "";
|
|
751
|
+ this.form.use_section = "";
|
|
752
|
+ this.form.section_number = "";
|
|
753
|
+ this.form.maintenance_engineer = "";
|
|
754
|
+ this.form.telephone = "";
|
|
755
|
+ this.form.user_total = "";
|
|
756
|
+ this.form.remarks = "";
|
|
757
|
+ this.form.user_year = "";
|
|
758
|
+ this.form.work_time = "";
|
|
759
|
+ this.form.unit_type = "";
|
|
760
|
+ this.getAllSubregion();
|
|
761
|
+ this.$emit("getAllMachineInfo");
|
|
762
|
+ this.$forceUpdate();
|
763
|
763
|
} else {
|
764
|
|
- this.$message.error('添加失败')
|
|
764
|
+ this.$message.error("添加失败");
|
765
|
765
|
}
|
766
|
|
- })
|
|
766
|
+ });
|
767
|
767
|
}
|
768
|
|
- })
|
|
768
|
+ });
|
769
|
769
|
},
|
770
|
770
|
SaveManageInfoTwo(formName) {
|
771
|
|
- if (this.form.bed_number === '') {
|
772
|
|
- this.form.bed_number = 0
|
|
771
|
+ if (this.form.bed_number === "") {
|
|
772
|
+ this.form.bed_number = 0;
|
773
|
773
|
}
|
774
|
774
|
|
775
|
|
- var device_type = this.form.device_type
|
776
|
|
- var device_types = parseInt(device_type)
|
777
|
|
- this.form.device_type = device_types
|
|
775
|
+ var device_type = this.form.device_type;
|
|
776
|
+ var device_types = parseInt(device_type);
|
|
777
|
+ this.form.device_type = device_types;
|
778
|
778
|
|
779
|
|
- if (this.form.rubbish_reason === '') {
|
780
|
|
- this.form.rubbish_reason = 0
|
|
779
|
+ if (this.form.rubbish_reason === "") {
|
|
780
|
+ this.form.rubbish_reason = 0;
|
781
|
781
|
}
|
782
|
|
- var rubbish_reason = this.form.rubbish_reason
|
783
|
|
- var rubbish_reasons = parseInt(rubbish_reason)
|
784
|
|
- this.form.rubbish_reason = rubbish_reasons
|
|
782
|
+ var rubbish_reason = this.form.rubbish_reason;
|
|
783
|
+ var rubbish_reasons = parseInt(rubbish_reason);
|
|
784
|
+ this.form.rubbish_reason = rubbish_reasons;
|
785
|
785
|
|
786
|
|
- var machine_status = this.form.machine_status
|
787
|
|
- var machine_statuss = parseInt(machine_status)
|
788
|
|
- this.form.machine_status = machine_statuss
|
|
786
|
+ var machine_status = this.form.machine_status;
|
|
787
|
+ var machine_statuss = parseInt(machine_status);
|
|
788
|
+ this.form.machine_status = machine_statuss;
|
789
|
789
|
|
790
|
|
- if (this.form.revers_mode === '') {
|
791
|
|
- this.form.revers_mode = 0
|
|
790
|
+ if (this.form.revers_mode === "") {
|
|
791
|
+ this.form.revers_mode = 0;
|
792
|
792
|
}
|
793
|
793
|
|
794
|
|
- var revers_mode = this.form.revers_mode
|
795
|
|
- var revers_modes = parseInt(revers_mode)
|
796
|
|
- this.form.revers_mode = revers_modes
|
|
794
|
+ var revers_mode = this.form.revers_mode;
|
|
795
|
+ var revers_modes = parseInt(revers_mode);
|
|
796
|
+ this.form.revers_mode = revers_modes;
|
797
|
797
|
|
798
|
|
- if (this.form.Disinfection_mode === '') {
|
799
|
|
- this.form.Disinfection_mode = 0
|
|
798
|
+ if (this.form.Disinfection_mode === "") {
|
|
799
|
+ this.form.Disinfection_mode = 0;
|
800
|
800
|
}
|
801
|
|
- var disinfecction_modes = this.form.Disinfection_mode
|
802
|
|
- var disinfecction_modess = parseInt(disinfecction_modes)
|
803
|
|
- this.form.Disinfection_mode = disinfecction_modess
|
|
801
|
+ var disinfecction_modes = this.form.Disinfection_mode;
|
|
802
|
+ var disinfecction_modess = parseInt(disinfecction_modes);
|
|
803
|
+ this.form.Disinfection_mode = disinfecction_modess;
|
804
|
804
|
|
805
|
805
|
this.$refs[formName].validate(valid => {
|
806
|
806
|
if (valid) {
|
807
|
807
|
SaveManageInfoTwo(this.form, this.forms.beds).then(response => {
|
808
|
808
|
if (response.data.state === 1) {
|
809
|
|
- var add = response.data.data.addmacher
|
810
|
|
- console.log('add', add)
|
811
|
|
- this.dialogVisible = false
|
812
|
|
- this.$message.success('保存成功')
|
813
|
|
- this.getAllSubregion()
|
814
|
|
- this.$emit('getAllMachineInfo')
|
815
|
|
- this.$forceUpdate()
|
|
809
|
+ var add = response.data.data.addmacher;
|
|
810
|
+ console.log("add", add);
|
|
811
|
+ this.dialogVisible = false;
|
|
812
|
+ this.$message.success("保存成功");
|
|
813
|
+ this.getAllSubregion();
|
|
814
|
+ this.$emit("getAllMachineInfo");
|
|
815
|
+ this.$forceUpdate();
|
816
|
816
|
}
|
817
|
|
- })
|
|
817
|
+ });
|
818
|
818
|
}
|
819
|
|
- })
|
|
819
|
+ });
|
820
|
820
|
},
|
821
|
821
|
getAllMode() {
|
822
|
822
|
getAllMode().then(response => {
|
823
|
|
- var mode = response.data.data.mode
|
824
|
|
- this.deviceMode = mode
|
825
|
|
- console.log('mode', mode)
|
826
|
|
- })
|
|
823
|
+ var mode = response.data.data.mode;
|
|
824
|
+ this.deviceMode = mode;
|
|
825
|
+ console.log("mode", mode);
|
|
826
|
+ });
|
827
|
827
|
}
|
828
|
828
|
},
|
829
|
829
|
created() {
|
830
|
|
- this.getAllSubregion()
|
831
|
|
- this.getAllMode()
|
|
830
|
+ this.getAllSubregion();
|
|
831
|
+ this.getAllMode();
|
832
|
832
|
}
|
833
|
|
-}
|
|
833
|
+};
|
834
|
834
|
</script>
|
835
|
835
|
|
836
|
836
|
<style lang="scss">
|
|
@@ -847,4 +847,21 @@ export default {
|
847
|
847
|
line-height: 26px;
|
848
|
848
|
height: 26px;
|
849
|
849
|
}
|
|
850
|
+#manage-form {
|
|
851
|
+ .el-form-item__label {
|
|
852
|
+ width: 100px;
|
|
853
|
+ padding: 0;
|
|
854
|
+ }
|
|
855
|
+}
|
|
856
|
+.el-checkbox {
|
|
857
|
+ color: #606266;
|
|
858
|
+ font-weight: 500;
|
|
859
|
+ font-size: 14px;
|
|
860
|
+ cursor: pointer;
|
|
861
|
+ -webkit-user-select: none;
|
|
862
|
+ -moz-user-select: none;
|
|
863
|
+ -ms-user-select: none;
|
|
864
|
+ user-select: none;
|
|
865
|
+ margin-right: 26px;
|
|
866
|
+}
|
850
|
867
|
</style>
|