see999 3 years ago
parent
commit
88471d4578

+ 66 - 20
src/xt_pages/data/components/addDrugs.vue View File

@@ -31,11 +31,11 @@
31 31
                             </el-select>
32 32
                         </el-form-item>
33 33
                         <div style="width:100%;">
34
-                          <div><span style="color:red;">*</span>单位&规格: <span style="color:#999">例如:0.75 g * 60 粒 / 盒</span></div>
34
+                          <div><span style="width:120px;text-align:right;display:inline-block"><span style="color:red;">*</span>单位&规格:</span><span style="color:#999">例如:0.75 g * 60 粒 / 盒</span></div>
35 35
                         </div>
36
-                        <div style="width:100%;display:flex;align-items:center;">
36
+                        <div style="width:100%;display:flex;align-items:center;margin-left:120px;">
37 37
                             <el-form-item prop="dose" class="noMargin">
38
-                              <el-input v-model="form.dose" type="number" style="width:100px" placeholder="剂量" :disabled="dosageShow"></el-input>  
38
+                              <el-input v-model="form.dose" type="number" style="width:100px;margin-right:5px;" placeholder="剂量" :disabled="dosageShow"></el-input>  
39 39
                             </el-form-item>
40 40
                             <el-form-item prop="dose_unit" class="noMargin">
41 41
                               <el-select v-model="form.dose_unit" style="width:160px;" placeholder="剂量单位" @change="changeMaxUnit">
@@ -45,11 +45,11 @@
45 45
                                   :label="item.name"
46 46
                                   :value="item.name">
47 47
                                 </el-option>
48
-                            </el-select>
49
-                          </el-form-item>
50
-                            *
48
+                              </el-select>
49
+                            </el-form-item>
50
+                            <span style="margin-bottom:20px;font-size:20px;">*</span>
51 51
                             <el-form-item prop="min_number" class="noMargin">
52
-                              <el-input v-model="form.min_number" style="width:100px" type="number" placeholder="拆零"> </el-input>
52
+                              <el-input v-model="form.min_number" style="width:100px;margin-right:5px;" :disabled="dosageShow" type="number" placeholder="拆零"> </el-input>
53 53
                             </el-form-item>
54 54
                             <el-form-item prop="min_unit" class="noMargin">
55 55
                               <el-select v-model="form.min_unit" style="width:160px;"  placeholder="拆零单位"  @change="changeMinUnit">
@@ -60,8 +60,8 @@
60 60
                                   :value="item.name">
61 61
                                 </el-option>
62 62
                               </el-select>
63
-                          </el-form-item>
64
-                          /
63
+                            </el-form-item>
64
+                          <span style="margin-bottom:20px;font-size:20px;">/</span>
65 65
                           <el-form-item prop="max_unit" class="noMargin">
66 66
                             <el-select v-model="form.max_unit" style="width:160px;" placeholder="包装单位">
67 67
                               <el-option
@@ -295,13 +295,14 @@
295 295
                         </el-form-item>
296 296
 
297 297
                         <el-form-item label="社保目录编码">
298
-                            <el-input v-model="form.social_security_directory_code" style="width:180px"></el-input>
298
+                            <el-input v-model="form.social_security_directory_code" style="width:160px"></el-input>
299 299
                         </el-form-item>
300 300
 
301 301
 
302 302
 
303 303
                         <el-form-item label="备案日期:">
304 304
                             <el-date-picker
305
+                                    style="width:160px"
305 306
                                     value-format="yyyy-MM-dd"
306 307
                                     v-model="form.record_date"
307 308
                                     type="date"
@@ -310,7 +311,7 @@
310 311
                         </el-form-item>
311 312
 
312 313
                         <el-form-item label="药品备注:">
313
-                            <el-input v-model="form.drug_remark" style="width:180px"></el-input>
314
+                            <el-input v-model="form.drug_remark" style="width:160px"></el-input>
314 315
                         </el-form-item>
315 316
                       
316 317
                         <el-form-item label="经销商: " style="width:100%">
@@ -652,6 +653,7 @@
652 653
               this.unitList.push(arr[i])
653 654
             }
654 655
         }
656
+        console.log('this.unitList',this.unitList)
655 657
         this.getInitializtion()
656 658
         this.getlist()
657 659
         this.GetAllConfig()
@@ -838,38 +840,82 @@
838 840
       changeMaxUnit(val){
839 841
         if(val == this.form.min_unit){
840 842
           this.form.dose = 1
843
+          this.form.min_number = this.form.dose
841 844
           this.dosageShow = true
842 845
         }
843 846
         if(val !=this.form.min_unit){
844 847
           this.dosageShow = false 
845 848
         } 
846
-       var arr =  getDataConfig('hemodialysis','units')
847
-      
848
-       for(let i=0;i<arr.length;i++){
849
+        var arr =  getDataConfig('hemodialysis','units')
850
+        this.unitList = []
851
+        for(let i=0;i<arr.length;i++){
852
+            
853
+          if(this.form.min_unit == arr[i].name){
854
+            this.unitList.push(arr[i])
855
+          }
849 856
           if(val == arr[i].name){
850
-             this.unitList.push(arr[i])
857
+            this.unitList.push(arr[i])
851 858
           }
852
-       }
859
+          let idArr = []
860
+          this.unitList.map(item => {
861
+            idArr.push(item.id)
862
+          })
863
+          if(idArr.indexOf(this.form.drug_dose_unit) == -1){
864
+            if(this.form.drug_dose_unit == arr[i].id){
865
+              this.unitList.push(arr[i])
866
+            }
867
+          }
868
+          
869
+        }
870
+        let ojb = {};
871
+        this.unitList = this.unitList.reduce(function(prevArr, currentItem) {
872
+            //利用对象的键名无法重复的特点,mch_id是唯一区别的属性值
873
+            ojb[currentItem.name] ? '' : ojb[currentItem.name] = true && prevArr.push(currentItem);
874
+            return prevArr
875
+        }, [])
853 876
                
854 877
       },
855 878
       changeMinUnit(val){
856 879
         if(val == this.form.max_unit){
857 880
           this.form.dose = 1
881
+          this.form.min_number = this.form.dose
858 882
           this.dosageShow = true
859 883
         }
860 884
         if(val != this.form.max_unit){
861 885
           this.dosageShow = false
862 886
         }
863 887
         
864
-        if(this.form.dosage == "" || this.form.max_unit == ""){
865
-           this.form.min_number = 1
866
-        } 
867
-        var arr =  getDataConfig('hemodialysis','units')
888
+        // if(this.form.dosage == "" || this.form.max_unit == ""){
889
+        //    this.form.min_number = 1
890
+        // } 
891
+        var arr = getDataConfig('hemodialysis','units')
892
+        this.unitList = []
868 893
         for(let i=0;i<arr.length;i++){
869 894
             if(val == arr[i].name){
870 895
               this.unitList.push(arr[i])
871 896
             }
897
+            if(this.form.max_unit == arr[i].name){
898
+              this.unitList.push(arr[i])
899
+            }
900
+            if(this.form.drug_dose_unit == arr[i].id){
901
+              this.unitList.push(arr[i])
902
+            }
903
+            let idArr = []
904
+            this.unitList.map(item => {
905
+              idArr.push(item.id)
906
+            })
907
+            if(idArr.indexOf(this.form.drug_dose_unit) == -1){
908
+              if(this.form.drug_dose_unit == arr[i].id){
909
+                this.unitList.push(arr[i])
910
+              }
911
+            }
872 912
         }
913
+        let ojb = {};
914
+        this.unitList = this.unitList.reduce(function(prevArr, currentItem) {
915
+          //利用对象的键名无法重复的特点,mch_id是唯一区别的属性值
916
+          ojb[currentItem.name] ? '' : ojb[currentItem.name] = true && prevArr.push(currentItem);
917
+          return prevArr
918
+        }, [])
873 919
        
874 920
       }
875 921
     }, watch: {

+ 6 - 1
src/xt_pages/dialysis/details/NavIgation.vue View File

@@ -90,6 +90,7 @@
90 90
       :schedual="temp_schedual"
91 91
       :stockType="stockType"
92 92
       :lastAssessment="lastAssessment"
93
+      :mode_id="mode_id"
93 94
     ></dialysis-prescription-dialog>
94 95
 
95 96
     <double-check-dialog
@@ -209,12 +210,16 @@ export default {
209 210
 
210 211
   data() {
211 212
     return {
212
-      temp_schedual: {}
213
+      temp_schedual: {},
214
+      mode_id:1
213 215
     };
214 216
   },
215 217
   mounted() {},
216 218
 
217 219
   props: {
220
+    mode_id:{
221
+      type:Number
222
+    },
218 223
     longAdvices: {
219 224
       // 临时医嘱
220 225
       type: Array,

+ 5 - 1
src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue View File

@@ -804,6 +804,9 @@
804 804
     name: 'dialysisPrescriptionDialog',
805 805
     components: { MsgTip,multiSelectBox },
806 806
     props: {
807
+      mode_id:{
808
+        type:Number
809
+      },
807 810
       schedual: {
808 811
         type: Object
809 812
       },
@@ -1815,7 +1818,8 @@
1815 1818
 
1816 1819
         // 入口
1817 1820
         var pre = pre
1818
-        this.dialysisPrescription.mode_id = this.$route.query.mode_id
1821
+        this.dialysisPrescription.mode_id = this.$route.query.mode_id ? this.$route.query.mode_id : this.mode_id
1822
+        console.log('this.dialysisPrescription.mode_id',this.dialysisPrescription.mode_id)
1819 1823
         if (pre.mode_id == 2 || pre.mode_id == 5 || pre.mode_id == 12 || this.schedual.mode_id == 2 || this.schedual.mode_id == 5 || this.schedual.mode_id == 12) {
1820 1824
           this.zhiShow = true
1821 1825
           this.huShow = true

+ 1 - 1
src/xt_pages/dialysis/details/dialysisMonitoring.vue View File

@@ -15,7 +15,7 @@
15 15
           <th v-if="isShow('血流量')" width="92px">血流量(ml/min)</th>
16 16
           <th v-if="isShow('跨膜压')" width="76px">跨膜压({{monitores[0]&&monitores[0]['transmembrane_pressure_type'] == 2 ? 'kpa' : 'mmHg'}})</th>
17 17
           <th v-if=" isShow('超滤量') &&(template_id == 6 || template_id == 9 || template_id == 10 || template_id == 11 || template_id == 13 || template_id == 17 || template_id == 18 || template_id == 19 || template_id == 20 || template_id == 21 || template_id == 22 || template_id == 23 || template_id == 24 || template_id == 26 || template_id == 27 || template_id == 28 || template_id == 29 || template_id == 30 || template_id == 31 || template_id == 32 || template_id == 34 || template_id == 35 || template_id == 36 || template_id == 38 || template_id == 39 || template_id == 40 || this.$store.getters.xt_user.template_info.org_id == 9555)" width="76px" > 超滤量(ml)</th>
18
-          <th v-if=" isShow('超滤量') && template_id != 6 && template_id != 9 && template_id != 10 && template_id != 11 && template_id != 13 && template_id != 17 && template_id != 18 && template_id != 19 && template_id != 20 && template_id != 21 && template_id != 22 && template_id != 23 && template_id != 24 && template_id != 26 && template_id !=27 && template_id!=28 && template_id!=29 && template_id!=30 && template_id!=31 && template_id!=32 && template_id!=34 && template_id!=35 && template_id!=36 && template_id!=38 && template_id != 39 && template_id == 40 && this.$store.getters.xt_user.template_info.org_id != 9555"  width="76px"> 超滤量(L) </th>
18
+          <th v-if=" isShow('超滤量') && template_id != 6 && template_id != 9 && template_id != 10 && template_id != 11 && template_id != 13 && template_id != 17 && template_id != 18 && template_id != 19 && template_id != 20 && template_id != 21 && template_id != 22 && template_id != 23 && template_id != 24 && template_id != 26 && template_id !=27 && template_id!=28 && template_id!=29 && template_id!=30 && template_id!=31 && template_id!=32 && template_id!=34 && template_id!=35 && template_id!=36 && template_id!=38 && template_id != 39 && template_id != 40 && this.$store.getters.xt_user.template_info.org_id != 9555"  width="76px"> 超滤量(L) </th>
19 19
           <th v-if="isShow('超滤率') && (template_id ==6 || template_id == 10 || template_id == 11 || template_id == 12 || template_id == 13 || template_id == 17 || template_id == 18 || template_id == 19 || template_id == 20 || template_id == 21 || template_id == 22 || template_id == 23 || template_id == 24 || template_id == 26 || template_id == 29 || template_id == 30 || template_id == 31 || template_id == 34 || template_id == 35 || template_id == 38)" width="50px"> 超滤率 <br />(ml/h) </th>
20 20
           <th v-if="isShow('超滤率') && template_id !=6 && template_id !=10 && template_id !=11 && template_id !=12 && template_id !=13 && template_id !=17 && template_id !=18 && template_id !=19 && template_id !=20 && template_id !=21 && template_id !=22 && template_id !=23 && template_id !=24 && template_id !=26 && template_id !=29 && template_id !=30 && template_id !=31 && template_id !=34 && template_id !=35 && template_id !=38" width="50px"> 超滤率 <br />(L/h) </th>
21 21
           <th v-if="isShow('钠浓度')" width="92px">钠浓度(mmol/L)</th>

+ 6 - 1
src/xt_pages/outpatientDoctorStation/components/dialysisIndex.vue View File

@@ -61,6 +61,7 @@
61 61
           :his_is_open="his_is_open"
62 62
           :lastAssessment="lastAssessment"
63 63
           :stockType="stockType"
64
+          :mode_id="mode_id"
64 65
         >
65 66
         </nav-igation>
66 67
 
@@ -309,7 +310,8 @@ export default {
309 310
       queueConfig:{},
310 311
       stockType:[],
311 312
       preparestock:[],
312
-      dialysisShow:false
313
+      dialysisShow:false,
314
+      mode_id:1
313 315
     }
314 316
   },
315 317
   created() {
@@ -326,6 +328,8 @@ export default {
326 328
         schedules.map(item => {
327 329
           if(item.patient_id == this.patient_id){
328 330
             arr.push(item.patient_id)
331
+            console.log('item',item)
332
+            this.mode_id = item.mode_id
329 333
           }
330 334
         })
331 335
         if(arr.length > 0){
@@ -362,6 +366,7 @@ export default {
362 366
                   schedules.map(item => {
363 367
                     if(item.patient_id == this.patient_id){
364 368
                       arr.push(item.patient_id)
369
+                      this.mode_id = item.mode_id
365 370
                     }
366 371
                   })
367 372
                   if(arr.length > 0){

+ 2 - 2
src/xt_pages/outpatientDoctorStation/components/prescriptionTable.vue View File

@@ -411,7 +411,7 @@
411 411
           scope.row.prescribing_number = 1
412 412
         }
413 413
         if(scope.row.prescribing_number_unit == scope.row.drug.min_unit){
414
-          scope.row.retail_price = scope.row.drug.min_price * scope.row.prescribing_number
414
+          // scope.row.retail_price = scope.row.drug.min_price * scope.row.prescribing_number
415 415
           if(scope.row.prescribing_number > scope.row.drug.total){
416 416
             this.$message.error(scope.row.drug_name + '库存不足')
417 417
           }
@@ -419,7 +419,7 @@
419 419
           if((parseInt(scope.row.prescribing_number) * scope.row.drug.min_number) > scope.row.drug.total){
420 420
             this.$message.error(scope.row.drug_name + '库存不足')
421 421
           }
422
-          scope.row.retail_price = scope.row.drug.retail_price * scope.row.prescribing_number
422
+          // scope.row.retail_price = scope.row.drug.retail_price * scope.row.prescribing_number
423 423
         }
424 424
         
425 425
       },