|
@@ -1476,7 +1476,7 @@
|
1476
|
1476
|
</template>
|
1477
|
1477
|
|
1478
|
1478
|
<script>
|
1479
|
|
- import { CreateGroupAdvice, GetSolution, postPrescription, postSoulution,saveInformation,getPatientRecordList } from '@/api/dialysis'
|
|
1479
|
+ import { CreateGroupAdvice, GetSolution, postPrescription, postSoulution,saveInformation,getPatientRecordList,getPatientBefor } from '@/api/dialysis'
|
1480
|
1480
|
import { getDataConfig } from '@/utils/data'
|
1481
|
1481
|
import { calculateAnticoagulantZL, uParseTime,replacementFlow } from '@/utils/tools'
|
1482
|
1482
|
import store from '@/store'
|
|
@@ -2634,16 +2634,17 @@ mu
|
2634
|
2634
|
}
|
2635
|
2635
|
},
|
2636
|
2636
|
show(pre, schedual, last, his_is_open,is_advice_open,admins) {
|
2637
|
|
-
|
|
2637
|
+ console.log("除非=======================")
|
|
2638
|
+
|
2638
|
2639
|
if(this.$store.getters.xt_user.template_info.org_id==10702 || this.$store.getters.xt_user.template_info.org_id==10635 || this.$store.getters.xt_user.template_info.org_id==0 || this.$store.getters.xt_user.template_info.org_id==10721){
|
2639
|
2640
|
if(this.predialysis!=undefined){
|
2640
|
2641
|
if(this.dialysisPrescription.target_ultrafiltration==0 || this.dialysisPrescription.target_ultrafiltration==""){
|
2641
|
|
- this.dialysisPrescription.target_ultrafiltration = (this.predialysis.weight_before - this.predialysis.dry_weight - this.predialysis.additional_weight).toFixed(2)
|
|
2642
|
+ this.dialysisPrescription.target_ultrafiltration = (this.predialysis.weight_before - this.predialysis.dry_weight - this.predialysis.additional_weight).toFixed(1)
|
2642
|
2643
|
}
|
2643
|
2644
|
|
2644
|
2645
|
if(this.dialysisPrescription.prescription_water==0 || this.dialysisPrescription.prescription_water==""){
|
2645
|
|
- if((this.predialysis.weight_before - this.predialysis.dry_weight - this.predialysis.additional_weight).toFixed(2)>0){
|
2646
|
|
- this.dialysisPrescription.prescription_water = (this.predialysis.weight_before - this.predialysis.dry_weight - this.predialysis.additional_weight).toFixed(2)
|
|
2646
|
+ if((this.predialysis.weight_before - this.predialysis.dry_weight - this.predialysis.additional_weight).toFixed(1)>0){
|
|
2647
|
+ this.dialysisPrescription.prescription_water = (this.predialysis.weight_before - this.predialysis.dry_weight - this.predialysis.additional_weight).toFixed(1)
|
2647
|
2648
|
}
|
2648
|
2649
|
|
2649
|
2650
|
}
|
|
@@ -3100,6 +3101,10 @@ mu
|
3100
|
3101
|
this.pre = pre
|
3101
|
3102
|
// console.log("pre1", pre);
|
3102
|
3103
|
this.getPermission()
|
|
3104
|
+ if(this.$store.getters.xt_user.template_info.org_id==10164 || this.$store.getters.xt_user.template_info.org_id==10721 || this.$store.getters.xt_user.template_info.org_id==10635 || this.$store.getters.xt_user.template_info.org_id==0){
|
|
3105
|
+ this.getPatientBefor()
|
|
3106
|
+ }
|
|
3107
|
+
|
3103
|
3108
|
|
3104
|
3109
|
let last_weight_after = 0
|
3105
|
3110
|
let weight_before = 0
|
|
@@ -4884,6 +4889,53 @@ mu
|
4884
|
4889
|
}
|
4885
|
4890
|
})
|
4886
|
4891
|
},
|
|
4892
|
+ getPatientBefor(){
|
|
4893
|
+
|
|
4894
|
+ var patient_id = 0
|
|
4895
|
+ var record_date =""
|
|
4896
|
+ if(this.$route.query.patient_id!=undefined){
|
|
4897
|
+ patient_id =this.$route.query.patient_id
|
|
4898
|
+ record_date = uParseTime(this.$route.query.date, '{y}-{m}-{d}')
|
|
4899
|
+ }else{
|
|
4900
|
+ patient_id = this.patient.id
|
|
4901
|
+ record_date = this.record_date
|
|
4902
|
+ }
|
|
4903
|
+ var params = {
|
|
4904
|
+ patient_id:patient_id,
|
|
4905
|
+ record_date:record_date
|
|
4906
|
+ }
|
|
4907
|
+ console.log("param----------------",params)
|
|
4908
|
+ getPatientBefor(params).then(response=>{
|
|
4909
|
+ if(response.data.state == 1){
|
|
4910
|
+ var patientBefor = response.data.data.patientBefor
|
|
4911
|
+ var prescription = response.data.data.prescription
|
|
4912
|
+ if(patientBefor!=undefined){
|
|
4913
|
+ if(this.dialysisPrescription.target_ultrafiltration==0 || this.dialysisPrescription.target_ultrafiltration==""){
|
|
4914
|
+ this.dialysisPrescription.target_ultrafiltration = (patientBefor.weight_before - patientBefor.dry_weight - patientBefor.additional_weight).toFixed(1)
|
|
4915
|
+ }
|
|
4916
|
+
|
|
4917
|
+ if(this.dialysisPrescription.prescription_water==0 || this.dialysisPrescription.prescription_water==""){
|
|
4918
|
+ if((patientBefor.weight_before - patientBefor.dry_weight - patientBefor.additional_weight).toFixed(1)>0){
|
|
4919
|
+ this.dialysisPrescription.prescription_water = (patientBefor.weight_before - patientBefor.dry_weight - patientBefor.additional_weight).toFixed(1)
|
|
4920
|
+ }
|
|
4921
|
+
|
|
4922
|
+ }
|
|
4923
|
+
|
|
4924
|
+ // if(this.$store.getters.xt_user.template_info.org_id==10721 || this.$store.getters.xt_user.template_info.org_id==10164 || this.$store.getters.xt_user.template_info.org_id==10635 || this.$store.getters.xt_user.template_info.org_id==0){
|
|
4925
|
+ // this.dialysisPrescription.target_ultrafiltration = prescription.target_ultrafiltration
|
|
4926
|
+ // this.dialysisPrescription.prescription_water = prescription.prescription_water
|
|
4927
|
+
|
|
4928
|
+ // }
|
|
4929
|
+ }
|
|
4930
|
+ if(prescription!=undefined){
|
|
4931
|
+
|
|
4932
|
+ this.dialysisPrescription.target_ultrafiltration = prescription.target_ultrafiltration
|
|
4933
|
+ this.dialysisPrescription.prescription_water = prescription.prescription_water
|
|
4934
|
+ }
|
|
4935
|
+
|
|
4936
|
+ }
|
|
4937
|
+ })
|
|
4938
|
+ },
|
4887
|
4939
|
unique(arr) {
|
4888
|
4940
|
const res = new Map()
|
4889
|
4941
|
return arr.filter((arr) => !res.has(arr.name) && res.set(arr.name, 1))
|