|
@@ -218,7 +218,7 @@
|
218
|
218
|
:rules="isCheckmust('跌倒风险预防措施')"
|
219
|
219
|
v-if="isShow('跌倒风险预防措施')"
|
220
|
220
|
>
|
221
|
|
- <!-- prop="precautionTwo" @change="precautionchange" isCheckmust('跌倒风险预防措施')
|
|
221
|
+ <!-- isFalldown prop="precautionTwo" @change="precautionchange" isCheckmust('跌倒风险预防措施') :prop="isName('跌倒风险预防措施')" :rules="isCheckmust('跌倒风险预防措施')"
|
222
|
222
|
[{required: true, message: '请选择跌倒风险预防措施', trigger: 'change'}]-->
|
223
|
223
|
<el-checkbox-group v-model="precautionTwo" @change="precautionchange">
|
224
|
224
|
<el-checkbox
|
|
@@ -389,7 +389,7 @@ export default {
|
389
|
389
|
tumble: "",
|
390
|
390
|
his_department: "",
|
391
|
391
|
his_bed: "",
|
392
|
|
- // precautionTwo: [],
|
|
392
|
+ falldown:[],
|
393
|
393
|
},
|
394
|
394
|
precautionTwo: [],
|
395
|
395
|
arr:[]
|
|
@@ -456,39 +456,41 @@ export default {
|
456
|
456
|
},
|
457
|
457
|
// 复选框跌倒风险措施
|
458
|
458
|
precautionchange(){
|
459
|
|
- // var arr = [];
|
460
|
|
- console.log('sadffdasfdg',this.precautionTwo);
|
461
|
|
- for (let i = 0; i < this.precaution_arr.length; i++) {
|
462
|
|
- for (let j = 0; j < this.precautionTwo.length; j++) {
|
463
|
|
- if (this.precaution_arr[i].name == this.precautionTwo[j]) {
|
464
|
|
- this.arr.push(this.precaution_arr[i].id);
|
465
|
|
- }
|
466
|
|
- }
|
467
|
|
- }
|
468
|
|
- var obj = this.arr.join(",");
|
469
|
|
- this.receiveTreatmentAsses.precaution = obj;
|
470
|
|
- // if(arr.length>0){
|
471
|
|
- // return this.precautionTwo
|
472
|
|
- // }
|
473
|
|
- // console.log('arr的数据',arr);
|
474
|
|
- // console.log('sadffdasfdg',this.precautionTwo.length);
|
475
|
|
- // console.log('this.precaution_arr',arr.length);
|
476
|
|
- },
|
477
|
|
-
|
478
|
|
- handleComfirm: function (formName) {
|
479
|
|
- // var arr = [];
|
480
|
459
|
// for (let i = 0; i < this.precaution_arr.length; i++) {
|
481
|
460
|
// for (let j = 0; j < this.precautionTwo.length; j++) {
|
482
|
461
|
// if (this.precaution_arr[i].name == this.precautionTwo[j]) {
|
483
|
462
|
// this.arr.push(this.precaution_arr[i].id);
|
484
|
463
|
// }
|
485
|
464
|
// }
|
486
|
|
- // }
|
487
|
|
- this.precautionchange()
|
|
465
|
+ // }
|
488
|
466
|
// var obj = this.arr.join(",");
|
489
|
467
|
// this.receiveTreatmentAsses.precaution = obj;
|
|
468
|
+
|
|
469
|
+ // this.receiveTreatmentAsses.falldown=this.precautionTwo
|
|
470
|
+ // if(this.receiveTreatmentAsses.falldown.length<=0){
|
|
471
|
+ // this.isFalldown('跌倒风险预防措施')
|
|
472
|
+ // }
|
|
473
|
+ console.log('this.precaution_arr',this.precautionTwo);
|
|
474
|
+ // console.log('arr的数据',this.receiveTreatmentAsses.falldown);
|
|
475
|
+ // console.log('sadffdasfdg',this.receiveTreatmentAsses.falldown.length);
|
|
476
|
+
|
|
477
|
+ },
|
|
478
|
+
|
|
479
|
+ handleComfirm: function (formName) {
|
|
480
|
+ // var arr = [];
|
|
481
|
+ for (let i = 0; i < this.precaution_arr.length; i++) {
|
|
482
|
+ for (let j = 0; j < this.precautionTwo.length; j++) {
|
|
483
|
+ if (this.precaution_arr[i].name == this.precautionTwo[j]) {
|
|
484
|
+ this.arr.push(this.precaution_arr[i].id);
|
|
485
|
+ }
|
|
486
|
+ }
|
|
487
|
+ }
|
|
488
|
+ // this.precautionchange()
|
|
489
|
+ var obj = this.arr.join(",");
|
|
490
|
+ this.receiveTreatmentAsses.precaution = obj;
|
490
|
491
|
let ParamsQuery = this.receiveTreatmentAsses;
|
491
|
|
- // console.log("ParamsQuery", ParamsQuery);
|
|
492
|
+
|
|
493
|
+ console.log("ParamsQuery", ParamsQuery);
|
492
|
494
|
ParamsQuery["patient"] = this.patient.id;
|
493
|
495
|
ParamsQuery["record_date"] = this.record_date;
|
494
|
496
|
//console.log(this.receiver_treatment_access);
|
|
@@ -551,14 +553,14 @@ export default {
|
551
|
553
|
isCheckmust(name) {
|
552
|
554
|
let filedList = store.getters.xt_user.fileds;
|
553
|
555
|
for (let i = 0; i < filedList.length; i++) {
|
554
|
|
- // if (
|
555
|
|
- // filedList[i].module == 2){console.log(filedList[i],'filedList[i]')}
|
|
556
|
+
|
556
|
557
|
if (
|
557
|
558
|
filedList[i].module == 2 &&
|
558
|
559
|
filedList[i].filed_name_cn == name &&
|
559
|
560
|
filedList[i].is_write == 1
|
560
|
561
|
) {
|
561
|
|
- if (name == "风险程度"||name == "病人情况"||name == '心理评估' ) {
|
|
562
|
+ // name == '跌倒风险预防措施' && this.precautionTwo.length<=0
|
|
563
|
+ if (name == "风险程度"||name == "病人情况"||name == '心理评估') {
|
562
|
564
|
return [
|
563
|
565
|
{ required: true, message: `请输入${name}`,trigger: ['blur','change'] },
|
564
|
566
|
{
|
|
@@ -569,26 +571,35 @@ export default {
|
569
|
571
|
},
|
570
|
572
|
];
|
571
|
573
|
}
|
572
|
|
- // else if(name == '跌倒风险预防措施' && this.precautionTwo.length <= 0){
|
573
|
|
- // return [
|
574
|
|
- // { type:'array',required: true, message: `请选择${name}`,trigger: ['blur','change'] },
|
575
|
|
- // {
|
576
|
|
- // required: true,
|
577
|
|
- // pattern: /^[1-9]\d*$/,
|
578
|
|
- // message: `请选择${name}`,
|
579
|
|
- // trigger: ['blur','change']
|
580
|
|
- // },
|
581
|
|
- // ];
|
582
|
|
- // }
|
583
|
574
|
else{
|
584
|
575
|
return [{ required: true, message: `请输入${name}`,trigger: ['blur','change'] }];
|
585
|
576
|
}
|
586
|
577
|
|
587
|
578
|
}
|
588
|
|
-
|
589
|
|
-
|
590
|
579
|
}
|
591
|
580
|
},
|
|
581
|
+ // isFalldown(name){
|
|
582
|
+ // let filedList = store.getters.xt_user.fileds;
|
|
583
|
+ // for (let i = 0; i < filedList.length; i++) {
|
|
584
|
+ // if (
|
|
585
|
+ // filedList[i].module == 2 &&
|
|
586
|
+ // filedList[i].filed_name_cn == name &&
|
|
587
|
+ // filedList[i].is_write == 1
|
|
588
|
+ // ) {
|
|
589
|
+ // if (name == "跌倒风险预防措施" && this.precautionTwo.length<=0) {
|
|
590
|
+ // return [
|
|
591
|
+ // { required: true, message: `请选择${name}`,trigger: ['blur','change'] },
|
|
592
|
+ // {
|
|
593
|
+ // required: true,
|
|
594
|
+ // pattern: /^[1-9]\d*$/,
|
|
595
|
+ // message: `请选择${name}`,
|
|
596
|
+ // trigger: ['blur','change']
|
|
597
|
+ // },
|
|
598
|
+ // ];
|
|
599
|
+ // }
|
|
600
|
+ // }
|
|
601
|
+ // }
|
|
602
|
+ // },
|
592
|
603
|
getPermission() {
|
593
|
604
|
request
|
594
|
605
|
.get("/api/func_per/get", {
|
|
@@ -658,6 +669,7 @@ export default {
|
658
|
669
|
},
|
659
|
670
|
},
|
660
|
671
|
created() {
|
|
672
|
+
|
661
|
673
|
// console.log("接诊评估", this.receiver_treatment_access);
|
662
|
674
|
var date = this.$route.query && this.$route.query.date;
|
663
|
675
|
this.record_date = date
|
|
@@ -674,7 +686,11 @@ export default {
|
674
|
686
|
// console.log("风险", this.precaution_arr);
|
675
|
687
|
this.intake_arr = getDataConfig("hemodialysis", "intake");
|
676
|
688
|
this.nutrition_arr = getDataConfig("hemodialysis", "nutrition");
|
|
689
|
+
|
677
|
690
|
},
|
|
691
|
+ // mounted(){
|
|
692
|
+ // this.isFalldown()
|
|
693
|
+ // }
|
678
|
694
|
};
|
679
|
695
|
</script>
|
680
|
696
|
|