Просмотр исходного кода

Merge remote-tracking branch 'origin/20230223_pc_vue_new_branch' into 20230223_pc_vue_new_branch

yq1 2 дней назад
Родитель
Сommit
c0bb516a19

+ 2 - 2
src/xt_pages/Pharmacy/DispensingDetails.vue Просмотреть файл

@@ -32,7 +32,7 @@
32 32
             align="right"
33 33
             format="yyyy-MM-dd"
34 34
             value-format="yyyy-MM-dd"
35
-            @change="startTimeChange"
35
+           
36 36
           ></el-date-picker
37 37
           >-
38 38
           <el-date-picker
@@ -46,7 +46,7 @@
46 46
             align="right"
47 47
             format="yyyy-MM-dd"
48 48
             value-format="yyyy-MM-dd"
49
-            @change="endTimeChange"
49
+          
50 50
           ></el-date-picker>
51 51
 
52 52
           <el-button

+ 183 - 10
src/xt_pages/Pharmacy/PatientDispensing.vue Просмотреть файл

@@ -398,9 +398,8 @@ export default {
398 398
       currentIndex:0,
399 399
       is_drug_open:"2",
400 400
       textarea:"",
401
-
402
-
403 401
       drug_code_open:0,
402
+      patientList:[]
404 403
 
405 404
     };
406 405
   },
@@ -537,7 +536,7 @@ export default {
537 536
           this.waitmount = res.data.data.itotal;
538 537
           this.alreadmount = res.data.data.wtotal;
539 538
           this.drugList = res.data.data.drug
540
-          this.drug_code_open = response.data.data.config.is_open
539
+          this.drug_code_open = res.data.data.config.is_open
541 540
         }
542 541
       });
543 542
       // console.log("2222222")
@@ -550,10 +549,11 @@ export default {
550 549
         shift: this.shift,
551 550
         partition: this.partition,
552 551
       };
553
-      console.log("班次---------------------",params)
552
+     
554 553
       waitingdrug(params).then((res) => {
555 554
         if (res.data.state == 1) {
556
-          this.waitmount_data = res.data.data.list;
555
+          this.waitmount_data=[]
556
+          var list = res.data.data.list;
557 557
           this.baseList =[]
558 558
           this.baseList = res.data.data.baseList
559 559
           if (this.shift != 0 || this.partition != 0) {
@@ -563,18 +563,105 @@ export default {
563 563
               this.waitmount = this.waitmount_data.length;
564 564
             }
565 565
           }
566
+          this.patientList = []
567
+          this.patientList = res.data.data.patientList
568
+          var listTwo = res.data.data.listTwo
569
+         
570
+          var newArr =[]
571
+          if(listTwo!=null && listTwo.length>0){
572
+             for(let i=0;i<listTwo.length;i++){
573
+              listTwo[i].PatientID = 0
574
+              listTwo[i].Name=""
575
+              listTwo[i].DialysisNo=""
576
+              listTwo[i].PatientID = listTwo[i].patient_id
577
+              listTwo[i].Name = listTwo[i].patient.name
578
+              listTwo[i].DialysisNo = listTwo[i].patient.dialysis_no
579
+              newArr.push(listTwo[i])
580
+             }
581
+          }
582
+        
583
+          if(list!=null && list.length>0){
584
+            for(let i=0;i<list.length;i++){
585
+              this.waitmount_data.push(list[i])
586
+            }
587
+            if(newArr!=null && newArr.length>0){
588
+               for(let i=0;i<newArr.length;i++){
589
+                this.waitmount_data.push(newArr[i]) 
590
+               }
591
+            }
592
+          }
593
+          if(this.waitmount_data==null){
594
+            if(newArr!=null && newArr.length>0){
595
+               for(let i=0;i<newArr.length;i++){
596
+                this.waitmount_data.push(newArr[i]) 
597
+               }
598
+            }
599
+           
600
+          }
601
+          if(list==null){
602
+            if(newArr!=null && newArr.length>0){
603
+               for(let i=0;i<newArr.length;i++){
604
+                this.waitmount_data.push(newArr[i]) 
605
+               }
606
+            }
607
+           
608
+          }
609
+         
566 610
         }
567 611
       });
568 612
       issueddrugs(params).then((res) => {
569 613
         if (res.data.state == 1) {
570
-          this.alreadmount_data = res.data.data.list;
614
+          this.alreadmount_data =[]
615
+          var list = res.data.data.list;
616
+          var listTwo =res.data.data.listTwo
617
+          
571 618
           if (this.shift != 0 || this.partition != 0) {
572
-            if (this.alreadmount_data == null) {
619
+            if (list == null) {
573 620
               this.alreadmount = 0;
574 621
             } else {
575
-              this.alreadmount = this.alreadmount_data.length;
622
+              this.alreadmount = list.length;
576 623
             }
577 624
           }
625
+
626
+          var newArr =[]
627
+          if(listTwo!=null && listTwo.length>0){
628
+             for(let i=0;i<listTwo.length;i++){
629
+              listTwo[i].PatientID = 0
630
+              listTwo[i].Name=""
631
+              listTwo[i].DialysisNo=""
632
+              listTwo[i].PatientID = listTwo[i].patient_id
633
+              listTwo[i].Name = listTwo[i].patient.name
634
+              listTwo[i].DialysisNo = listTwo[i].patient.dialysis_no
635
+              newArr.push(listTwo[i])
636
+             }
637
+          }
638
+        
639
+          if(list!=null && list.length>0){
640
+            for(let i=0;i<list.length;i++){
641
+              this.alreadmount_data.push(list[i])
642
+            }
643
+            if(newArr!=null && newArr.length>0){
644
+               for(let i=0;i<newArr.length;i++){
645
+                this.alreadmount_data.push(newArr[i]) 
646
+               }
647
+            }
648
+          }
649
+          if(this.waitmount_data==null){
650
+            if(newArr!=null && newArr.length>0){
651
+               for(let i=0;i<newArr.length;i++){
652
+                this.alreadmount_data.push(newArr[i]) 
653
+               }
654
+            }
655
+           
656
+          }
657
+          if(list==null){
658
+            if(newArr!=null && newArr.length>0){
659
+               for(let i=0;i<newArr.length;i++){
660
+                this.alreadmount_data.push(newArr[i]) 
661
+               }
662
+            }
663
+           
664
+          }
578 665
         }
579 666
       });
580 667
     },
@@ -589,13 +676,81 @@ export default {
589 676
       };
590 677
       await waitingdrug(params).then((res) => {
591 678
         if (res.data.state == 1) {
592
-          this.waitmount_data = res.data.data.list;
679
+          this.waitmount_data=[]
680
+          var list = res.data.data.list;
681
+          this.patientList = []
682
+          this.patientList = res.data.data.patientList
683
+          var listTwo = res.data.data.listTwo
684
+          var newArr =[]
685
+          if(listTwo!=null && listTwo.length>0){
686
+             for(let i=0;i<listTwo.length;i++){
687
+              listTwo[i].PatientID = 0
688
+              listTwo[i].Name=""
689
+              listTwo[i].DialysisNo=""
690
+              listTwo[i].PatientID = listTwo[i].patient_id
691
+              listTwo[i].Name = listTwo[i].patient.name
692
+              listTwo[i].DialysisNo = listTwo[i].patient.dialysis_no
693
+              newArr.push(listTwo[i])
694
+             }
695
+          }
696
+          if(list!=null && list.length>0){
697
+            for(let i=0;i<list.length;i++){
698
+              this.waitmount_data.push(list[i])
699
+            }
700
+            if(newArr!=null && newArr.length>0){
701
+               for(let i=0;i<newArr.length;i++){
702
+                this.waitmount_data.push(newArr[i]) 
703
+               }
704
+            }
705
+          }
706
+          if(list==null){
707
+            if(newArr!=null && newArr.length>0){
708
+               for(let i=0;i<newArr.length;i++){
709
+                this.waitmount_data.push(newArr[i]) 
710
+               }
711
+            }
712
+           
713
+          }
714
+
593 715
           console.log("1111111");
594 716
         }
595 717
       });
596 718
       await issueddrugs(params).then((res) => {
597 719
         if (res.data.state == 1) {
598
-          this.alreadmount_data = res.data.data.list;
720
+          this.alreadmount_data = []
721
+          var list = res.data.data.list;
722
+          var listTwo = res.data.data.listTwo
723
+          var newArr =[]
724
+          if(listTwo!=null && listTwo.length>0){
725
+             for(let i=0;i<listTwo.length;i++){
726
+              listTwo[i].PatientID = 0
727
+              listTwo[i].Name=""
728
+              listTwo[i].DialysisNo=""
729
+              listTwo[i].PatientID = listTwo[i].patient_id
730
+              listTwo[i].Name = listTwo[i].patient.name
731
+              listTwo[i].DialysisNo = listTwo[i].patient.dialysis_no
732
+              newArr.push(listTwo[i])
733
+             }
734
+          }
735
+          if(list!=null && list.length>0){
736
+            for(let i=0;i<list.length;i++){
737
+              this.alreadmount_data.push(list[i])
738
+            }
739
+            if(newArr!=null && newArr.length>0){
740
+               for(let i=0;i<newArr.length;i++){
741
+                this.alreadmount_data.push(newArr[i]) 
742
+               }
743
+            }
744
+          }
745
+          if(list==null){
746
+            if(newArr!=null && newArr.length>0){
747
+               for(let i=0;i<newArr.length;i++){
748
+                this.alreadmount_data.push(newArr[i]) 
749
+               }
750
+            }
751
+           
752
+          }
753
+
599 754
           console.log("1111111s");
600 755
         }
601 756
       });
@@ -603,6 +758,24 @@ export default {
603 758
 
604 759
       // })
605 760
     },
761
+    getPatientName(patient_id){
762
+      var name = ""
763
+      for(let i=0;i<this.patientList.length;i++){
764
+        if(patient_id == this.patientList[i].id){
765
+           name = this.patientList[i].name
766
+        }
767
+      }
768
+      return name
769
+    },
770
+    getPatientDialysisNo(patient_id){
771
+      var dialysis_no = ""
772
+      for(let i=0;i<this.patientList.length;i++){
773
+        if(patient_id == this.patientList[i].id){
774
+          dialysis_no = this.patientList[i].dialysis_no
775
+        }
776
+      }
777
+      return dialysis_no
778
+    },
606 779
     //获取患者信息详情
607 780
     getpatientdetails(val) {
608 781
       console.log("val2332323223",this.currentRow)

+ 11 - 11
src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue Просмотреть файл

@@ -33,25 +33,25 @@
33 33
                <span v-if="this.$store.getters.xt_user.template_info.org_id==0 || this.$store.getters.xt_user.template_info.org_id==10702">{{last_record&&(last_record.weight_after-last_record.additional_weight).toFixed(2)?(last_record.weight_after-last_record.additional_weight).toFixed(2):""}}kg</span>
34 34
             </span>
35 35
 
36
-            <span style="position: absolute;left:51%;top: 3%">
37
-              4小时超滤量上限(5%):
38
-              <span v-if="predialysis!=null && ((predialysis.dry_weight)*0.05) >0 "></span> {{(predialysis.dry_weight*0.05).toFixed(2)}}
39
-              kg
40
-            </span>
41
-            <span style="position: absolute;left: 70%;top: 3%" v-if="this.$store.getters.xt_user.template_info.org_id!=0&&this.$store.getters.xt_user.template_info.org_id!=10702">
42
-              透前血压:  {{predialysis&&predialysis.systolic_blood_pressure?predialysis.systolic_blood_pressure:""  }} / {{ predialysis&&predialysis.diastolic_blood_pressure?predialysis.diastolic_blood_pressure:"" }} mmHg
43
-            </span>
44
-
45
-            <span style="position: absolute;left: 70%;top: 3%" v-if="this.$store.getters.xt_user.template_info.org_id==0||this.$store.getters.xt_user.template_info.org_id==10702">
36
+            <span style="position: absolute;left: 70%;top: 3%" v-if="this.$store.getters.xt_user.template_info.org_id==0||this.$store.getters.xt_user.template_info.org_id==10702 || this.$store.getters.xt_user.template_info.org_id ==10721">
46 37
              衣物重:{{predialysis&&predialysis.additional_weight?predialysis.additional_weight:"" }} kg
47 38
             </span>
48 39
 
49
-            <span style="position: absolute;left: 80%;top: 3%" v-if="this.$store.getters.xt_user.template_info.org_id == 0 || this.$store.getters.xt_user.template_info.org_id ==10702 || this.$store.getters.xt_user.template_info.org_id ==10598">
40
+            <span style="position: absolute;left: 80%;top: 3%" v-if="this.$store.getters.xt_user.template_info.org_id == 0 || this.$store.getters.xt_user.template_info.org_id ==10702 || this.$store.getters.xt_user.template_info.org_id ==10598 || this.$store.getters.xt_user.template_info.org_id ==10721">
50 41
               体重增长:
51 42
               <span v-if="predialysis!=null && last_record!=null">
52 43
                 {{predialysis&&last_record&&((predialysis.weight_before - predialysis.additional_weight)-(last_record.weight_after-last_record.additional_weight)).toFixed(2)?((predialysis.weight_before - predialysis.additional_weight)-(last_record.weight_after-last_record.additional_weight)).toFixed(2):"" }} kg
53 44
               </span>
54 45
 
46
+              <span style="position: absolute;left:51%;top: 3%">
47
+              4小时超滤量上限(5%):
48
+              <span v-if="predialysis!=null && ((predialysis.dry_weight)*0.05) >0 "></span> {{(predialysis.dry_weight*0.05).toFixed(2)}}
49
+              kg
50
+            </span>
51
+            <span style="position: absolute;left: 70%;top: 3%" v-if="this.$store.getters.xt_user.template_info.org_id!=10702">
52
+              透前血压:  {{predialysis&&predialysis.systolic_blood_pressure?predialysis.systolic_blood_pressure:""  }} / {{ predialysis&&predialysis.diastolic_blood_pressure?predialysis.diastolic_blood_pressure:"" }} mmHg
53
+            </span>
54
+
55 55
 
56 56
             </span>
57 57
             <div class="warnTxt" v-if="showTxt != ''">{{ showTxt }}</div>

+ 13 - 13
src/xt_permission.js Просмотреть файл

@@ -12,19 +12,19 @@ const permissionWhiteList = loginWhiteList.concat(['/']) // 权限验证白名
12 12
 
13 13
 router.beforeEach((to, from, next) => {
14 14
   // 线上注释
15
-  // if (!store.getters.configlist || store.getters.configlist === undefined || store.getters.configlist.length <= 0) {
16
-  //   store.dispatch('VerifyConfigList', []).then(() => {
17
-  //     next()
18
-  //   })
19
-  // }
20
-  // if (store.getters.permission_routers === undefined) {
21
-  //   store.dispatch('xt_GenerateRoutes', []).then(() => {
22
-  //     next()
23
-  //   })
24
-  // } else {
25
-  //   next()
26
-  // }
27
-  // return
15
+  if (!store.getters.configlist || store.getters.configlist === undefined || store.getters.configlist.length <= 0) {
16
+    store.dispatch('VerifyConfigList', []).then(() => {
17
+      next()
18
+    })
19
+  }
20
+  if (store.getters.permission_routers === undefined) {
21
+    store.dispatch('xt_GenerateRoutes', []).then(() => {
22
+      next()
23
+    })
24
+  } else {
25
+    next()
26
+  }
27
+  return
28 28
   // 线上注释
29 29
   NProgress.start()
30 30
   // console.log(store.getters.current_role_urls.indexOf(to.path))