Browse Source

修改移动端bug

XMLWAN 4 years ago
parent
commit
0c1fa31044

+ 5 - 5
src/utils/tools.js View File

153
 }
153
 }
154
 
154
 
155
 export function calculateAnticoagulantZL(type, shouji, shichang, weichi) {
155
 export function calculateAnticoagulantZL(type, shouji, shichang, weichi) {
156
-  console.log(type)
157
-  console.log(shouji)
158
-  console.log(shichang)
159
-  console.log(weichi)
156
+  // console.log(type)
157
+  // console.log('首剂', shouji)
158
+  // console.log('总量', shichang)
159
+  // console.log('维持', weichi)
160
 
160
 
161
   var t = 0.5
161
   var t = 0.5
162
   if (type == 1) {
162
   if (type == 1) {
172
   if (isNaN(shouji) || isNaN(shichang) || isNaN(weichi)) {
172
   if (isNaN(shouji) || isNaN(shichang) || isNaN(weichi)) {
173
     return 0
173
     return 0
174
   }
174
   }
175
-  console.log((shouji + (shichang - t) * weichi).toFixed(1))
175
+  // console.log((shouji + (shichang - t) * weichi).toFixed(1))
176
   return (shouji + (shichang - t) * weichi).toFixed(1)
176
   return (shouji + (shichang - t) * weichi).toFixed(1)
177
 }
177
 }

+ 22 - 12
src/xt_pages/data/prescription.vue View File

930
           return false;
930
           return false;
931
         } else {
931
         } else {
932
            var prescription =  response.data.data.prescription
932
            var prescription =  response.data.data.prescription
933
+           console.log("prescription",prescription)
934
+            prescription.dialysis_duration = parseFloat(prescription.dialysis_duration_hour) + parseFloat((prescription.dialysis_duration_minute / 60).toFixed(2))
935
+           if(prescription.dialysate_formulation == 0){
936
+              prescription.dialysate_formulation = ""
937
+           } 
938
+           if(prescription.body_fluid ==0 ){
939
+             prescription.body_fluid = ""
940
+           }
941
+           if(prescription.anticoagulant == 0){
942
+               prescription.anticoagulant = ""
943
+           }
933
            if(prescription.anticoagulant == 3){
944
            if(prescription.anticoagulant == 3){
934
               prescription.anticoagulant = "低分子肝素"
945
               prescription.anticoagulant = "低分子肝素"
935
            }
946
            }
969
           return false;
980
           return false;
970
         } else {
981
         } else {
971
           this.system_prescription = response.data.data.prescriptions;
982
           this.system_prescription = response.data.data.prescriptions;
972
-          console.log("为什么",this.system_prescription)
973
 
983
 
974
           for (let i = 0; i < this.system_prescription.length; i++) {
984
           for (let i = 0; i < this.system_prescription.length; i++) {
975
             if (this.system_prescription[i].mode == 1) {
985
             if (this.system_prescription[i].mode == 1) {
1017
             this.isEdit = true;
1027
             this.isEdit = true;
1018
             this.system_prescription = [];
1028
             this.system_prescription = [];
1019
             this.system_prescription = response.data.data.prescriptions;
1029
             this.system_prescription = response.data.data.prescriptions;
1020
-            console.log("触发了吗",this.system_prescription)
1021
             this.addPlan.id = response.data.data.prescription.id;
1030
             this.addPlan.id = response.data.data.prescription.id;
1022
             return false;
1031
             return false;
1023
           }
1032
           }
1056
 
1065
 
1057
     this.blood_filters = this.$store.getters.blood_filters;
1066
     this.blood_filters = this.$store.getters.blood_filters;
1058
     this.dialysate_formulation = this.$store.getters.dialysate_formulation;
1067
     this.dialysate_formulation = this.$store.getters.dialysate_formulation;
1068
+   
1059
     this.body_fluid_option = this.$store.getters.body_fluid;
1069
     this.body_fluid_option = this.$store.getters.body_fluid;
1060
     this.special_medicine_option = this.$store.getters.special_medicine;
1070
     this.special_medicine_option = this.$store.getters.special_medicine;
1061
     this.displace_liqui_part_option = this.$store.getters.displace_liqui;
1071
     this.displace_liqui_part_option = this.$store.getters.displace_liqui;
1071
   },
1081
   },
1072
   watch: {
1082
   watch: {
1073
     "addPlan.dialysis_duration": function() {
1083
     "addPlan.dialysis_duration": function() {
1074
-      console.log(this.addPlan.anticoagulant_shouji);
1075
-      console.log(this.addPlan.dialysis_duration);
1076
-      console.log(this.addPlan.anticoagulant_weichi);
1084
+      // console.log(this.addPlan.anticoagulant_shouji);
1085
+      // console.log(this.addPlan.dialysis_duration);
1086
+      // console.log(this.addPlan.anticoagulant_weichi);
1077
 
1087
 
1078
       this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
1088
       this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
1079
         1,
1089
         1,
1083
       );
1093
       );
1084
     },
1094
     },
1085
     "addPlan.anticoagulant_shouji": function() {
1095
     "addPlan.anticoagulant_shouji": function() {
1086
-      console.log("首剂", this.addPlan.anticoagulant_shouji);
1087
-      console.log("维持", this.addPlan.anticoagulant_weichi);
1088
-      console.log("总量", this.addPlan.dialysis_duration);
1096
+      // console.log("首剂", this.addPlan.anticoagulant_shouji);
1097
+      // console.log("维持", this.addPlan.anticoagulant_weichi);
1098
+      // console.log("总量", this.addPlan.dialysis_duration);
1089
       this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
1099
       this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
1090
         1,
1100
         1,
1091
         this.addPlan.anticoagulant_shouji,
1101
         this.addPlan.anticoagulant_shouji,
1092
         this.addPlan.dialysis_duration,
1102
         this.addPlan.dialysis_duration,
1093
         this.addPlan.anticoagulant_weichi
1103
         this.addPlan.anticoagulant_weichi
1094
       );
1104
       );
1095
-      console.log("总量----", this.addPlan.anticoagulant_zongliang);
1105
+      // console.log("总量----", this.addPlan.anticoagulant_zongliang);
1096
     },
1106
     },
1097
     "addPlan.anticoagulant_weichi": function() {
1107
     "addPlan.anticoagulant_weichi": function() {
1098
-      console.log(this.addPlan.anticoagulant_shouji);
1099
-      console.log(this.addPlan.dialysis_duration);
1100
-      console.log(this.addPlan.anticoagulant_weichi);
1108
+      // console.log(this.addPlan.anticoagulant_shouji);
1109
+      // console.log(this.addPlan.dialysis_duration);
1110
+      // console.log(this.addPlan.anticoagulant_weichi);
1101
       this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
1111
       this.addPlan.anticoagulant_zongliang = calculateAnticoagulantZL(
1102
         1,
1112
         1,
1103
         this.addPlan.anticoagulant_shouji,
1113
         this.addPlan.anticoagulant_shouji,

+ 1 - 3
src/xt_pages/dialysis/details/dialog/assessmentBeforeDislysisDialog.vue View File

261
             <el-form-item label="出血: " v-if="isShow('出血')">
261
             <el-form-item label="出血: " v-if="isShow('出血')">
262
               <el-select v-model="assessmentBeforeDislysis.is_hemorrhage">
262
               <el-select v-model="assessmentBeforeDislysis.is_hemorrhage">
263
                 <el-option :key="0" label="请选择" :value="0"></el-option>
263
                 <el-option :key="0" label="请选择" :value="0"></el-option>
264
-
265
                 <el-option label="是" value="1"></el-option>
264
                 <el-option label="是" value="1"></el-option>
266
                 <el-option label="否" value="2"></el-option>
265
                 <el-option label="否" value="2"></el-option>
267
               </el-select>
266
               </el-select>
646
         return false
645
         return false
647
       },
646
       },
648
       show(assessment, lastDryWeightDislysis,last_predialysis_evaluation) {
647
       show(assessment, lastDryWeightDislysis,last_predialysis_evaluation) {
649
-        console.log(last_predialysis_evaluation)
650
-
651
         this.lastPredialysisEvaluation = last_predialysis_evaluation
648
         this.lastPredialysisEvaluation = last_predialysis_evaluation
649
+        console.log("22222222",this.lastPredialysisEvaluation)
652
         this.assessment = assessment
650
         this.assessment = assessment
653
         this.getPermission()
651
         this.getPermission()
654
         this.isVisibility = true
652
         this.isVisibility = true

+ 0 - 2
src/xt_pages/dialysis/details/dialog/dialysisPrescriptionDialog.vue View File

1347
             }
1347
             }
1348
           }
1348
           }
1349
         } else {
1349
         } else {
1350
-          console.log('排班----------', schedual.mode_id)
1351
           if (
1350
           if (
1352
             schedual.mode_id == 2 ||
1351
             schedual.mode_id == 2 ||
1353
             schedual.mode_id == 5 ||
1352
             schedual.mode_id == 5 ||
1354
             schedual.mode_id == 12
1353
             schedual.mode_id == 12
1355
           ) {
1354
           ) {
1356
-            console.log('进来----')
1357
             this.zhiShow = true
1355
             this.zhiShow = true
1358
             this.huShow = true
1356
             this.huShow = true
1359
             this.totalShow = true
1357
             this.totalShow = true

+ 42 - 6
src/xt_pages/user/dialysisSolution.vue View File

353
               ></el-input>
353
               ></el-input>
354
             </el-form-item>
354
             </el-form-item>
355
           </el-col>
355
           </el-col>
356
-          <el-col :span="8" v-if="isShows('置换量')">
356
+          <el-col :span="8" v-if="isShows('置换量')" v-show="zhiShow">
357
             <el-form-item label="置换量(L) : " prop="replacement_total">
357
             <el-form-item label="置换量(L) : " prop="replacement_total">
358
               <el-input
358
               <el-input
359
                 v-model="addPlan.replacement_total"
359
                 v-model="addPlan.replacement_total"
466
                 isShows('置换液') &&
466
                 isShows('置换液') &&
467
                   this.$store.getters.xt_user.template_info.template_id != 6
467
                   this.$store.getters.xt_user.template_info.template_id != 6
468
               "
468
               "
469
+              v-show="huShow"
469
             >
470
             >
470
               <el-select
471
               <el-select
471
                 v-model="addPlan.displace_liqui_part"
472
                 v-model="addPlan.displace_liqui_part"
503
             </el-form-item>
504
             </el-form-item>
504
           </el-col>
505
           </el-col>
505
 
506
 
506
-          <el-col :span="8" v-if="isShows('置换液总量')">
507
+          <el-col :span="8" v-if="isShows('置换液总量')" v-show="totalShow">
507
             <el-form-item label="置换液总量(L)">
508
             <el-form-item label="置换液总量(L)">
508
               <el-input v-model="addPlan.displace_liqui_value"></el-input>
509
               <el-input v-model="addPlan.displace_liqui_value"></el-input>
509
             </el-form-item>
510
             </el-form-item>
647
       callback()
648
       callback()
648
     }
649
     }
649
     return {
650
     return {
651
+      zhiShow:false,
652
+      huShow:false,
653
+      totalShow:false,
650
       InnerDialogProps: {
654
       InnerDialogProps: {
651
         values: [],
655
         values: [],
652
         visibility: false,
656
         visibility: false,
1279
       })
1283
       })
1280
     },
1284
     },
1281
     handleEdit(index, row) {
1285
     handleEdit(index, row) {
1282
-      console.log(index, row)
1286
+      // console.log(index, row)
1283
     },
1287
     },
1284
     handleSizeChange(val) {
1288
     handleSizeChange(val) {
1285
       this.queryParams.limit = val
1289
       this.queryParams.limit = val
1307
         this.addPlan.anticoagulant = '低分子肝素'
1311
         this.addPlan.anticoagulant = '低分子肝素'
1308
       }
1312
       }
1309
       if (row.anticoagulant != 3) {
1313
       if (row.anticoagulant != 3) {
1310
-        this.addPlan.anticoagulant = row.anticoagulant
1314
+        if(row.anticoagulant == 0){
1315
+           this.addPlan.anticoagulant = ""
1316
+        }else{
1317
+          this.addPlan.anticoagulant = row.anticoagulant
1318
+        }
1319
+        
1311
       }
1320
       }
1312
       this.addPlan.replacement_total = row.replacement_total
1321
       this.addPlan.replacement_total = row.replacement_total
1313
 
1322
 
1314
       this.addPlan.target_ktv = row.target_ktv.toString()
1323
       this.addPlan.target_ktv = row.target_ktv.toString()
1315
       this.addPlan.target_ultrafiltration = row.target_ultrafiltration.toString()
1324
       this.addPlan.target_ultrafiltration = row.target_ultrafiltration.toString()
1316
-
1325
+      
1326
+      this.addPlan.dialysis_duration = parseFloat(row.dialysis_duration_hour) + parseFloat((row.dialysis_duration_minute / 60).toFixed(2))
1327
+      this.addPlan.dialysis_duration_hour = row.dialysis_duration_hour
1328
+      this.addPlan.dialysis_duration_minute = row.dialysis_duration_minute
1317
       this.addPlan.anticoagulant_shouji = row.anticoagulant_shouji.toString()
1329
       this.addPlan.anticoagulant_shouji = row.anticoagulant_shouji.toString()
1318
       this.addPlan.anticoagulant_weichi = row.anticoagulant_weichi.toString()
1330
       this.addPlan.anticoagulant_weichi = row.anticoagulant_weichi.toString()
1319
       this.addPlan.anticoagulant_zongliang = row.anticoagulant_zongliang.toString()
1331
       this.addPlan.anticoagulant_zongliang = row.anticoagulant_zongliang.toString()
1330
       this.addPlan.remark = row.remark
1342
       this.addPlan.remark = row.remark
1331
 
1343
 
1332
       this.addPlan.dialyzer_perfusion_apparatus = row.dialyzer_perfusion_apparatus.toString()
1344
       this.addPlan.dialyzer_perfusion_apparatus = row.dialyzer_perfusion_apparatus.toString()
1333
-      this.addPlan.body_fluid = row.body_fluid
1345
+
1346
+     if(row.body_fluid == 0){
1347
+       this.addPlan.body_fluid = ""
1348
+      }else{
1349
+        this.addPlan.body_fluid = row.body_fluid
1350
+      }
1334
       this.addPlan.body_fluid_other = row.body_fluid_other.toString()
1351
       this.addPlan.body_fluid_other = row.body_fluid_other.toString()
1335
       this.addPlan.special_medicine = row.special_medicine
1352
       this.addPlan.special_medicine = row.special_medicine
1336
       this.addPlan.special_medicine_other = row.special_medicine_other.toString()
1353
       this.addPlan.special_medicine_other = row.special_medicine_other.toString()
1343
 
1360
 
1344
       this.dialogVisible = true
1361
       this.dialogVisible = true
1345
       this.isEdit = true
1362
       this.isEdit = true
1363
+      if(row.dialysate_formulation==0){
1364
+        this.addPlan.dialysate_formulation= ""
1365
+      }
1346
       this.addPlan.dialysate_formulation = row.dialysate_formulation
1366
       this.addPlan.dialysate_formulation = row.dialysate_formulation
1347
       this.dialysisTimeShow = new Date(
1367
       this.dialysisTimeShow = new Date(
1348
         2018,
1368
         2018,
1500
 
1520
 
1501
     addPlanModeChange() {
1521
     addPlanModeChange() {
1502
       var thismode = parseInt(this.addPlan.mode)
1522
       var thismode = parseInt(this.addPlan.mode)
1523
+      if(thismode == 2 || thismode == 5 || thismode ==12){
1524
+          this.zhiShow = true
1525
+          this.huShow= true
1526
+          this.totalShow = true
1527
+      }else{
1528
+        this.zhiShow= false
1529
+        this.huShow = false
1530
+        this.totalShow = false
1531
+      }
1503
       if (isNaN(thismode) || thismode <= 0) {
1532
       if (isNaN(thismode) || thismode <= 0) {
1504
         return false
1533
         return false
1505
       }
1534
       }
1517
 
1546
 
1518
       getSystemPrescription(params).then(response => {
1547
       getSystemPrescription(params).then(response => {
1519
         if (response.data.state == 1) {
1548
         if (response.data.state == 1) {
1549
+           var prescription =   response.data.data.prescription
1550
+           if(prescription.anticoagulant == 0){
1551
+              prescription.anticoagulant = ""
1552
+           }
1553
+           if(prescription.body_fluid == 0){
1554
+             prescription.body_fluid = ""
1555
+           }
1520
           if (response.data.data.prescription.id > 0) {
1556
           if (response.data.data.prescription.id > 0) {
1521
             for (const key in response.data.data.prescription) {
1557
             for (const key in response.data.data.prescription) {
1522
               // 因为el-input特性整数类型或者浮点数类型需要转换成字符串,所以加上toString()
1558
               // 因为el-input特性整数类型或者浮点数类型需要转换成字符串,所以加上toString()