|
@@ -5,7 +5,7 @@
|
5
|
5
|
<div class="DialogTit">
|
6
|
6
|
<span @click="close()" class="iconfont"></span>
|
7
|
7
|
<h1 class="name">透析处方</h1>
|
8
|
|
- <button @click="showmsgtip">{{patient.name}} [透析号 {{patient.dialysis_no}} ]</button>
|
|
8
|
+ <button @click="showmsgtip">{{patient.name}} [透析号 {{patient.dialysis_no}} ]</button>
|
9
|
9
|
<span @click="commitInfo" class="success" v-if="isPermission()">完成</span>
|
10
|
10
|
<span @click="commitInfo" class="success" v-if="!isPermission()"></span>
|
11
|
11
|
|
|
@@ -312,27 +312,27 @@
|
312
|
312
|
v-on:menu-comfirm-three="menuComfirmThree" :propsForm="advicePropForm"></long-advice-sub-menu>
|
313
|
313
|
|
314
|
314
|
<msg-tip style="width:500px;" :visibility="msgtip_visibility" :predialysis="predialysis"
|
315
|
|
- :last_predialysis="last_predialysis"
|
316
|
|
- :record="record"
|
317
|
|
- :last_record="last_record"
|
318
|
|
- :patient_prop="patient"
|
319
|
|
- :prescription_prop="prescription_prop"
|
320
|
|
- v-on:menu-msg-tip="menuMsgTip"></msg-tip>
|
|
315
|
+ :last_predialysis="last_predialysis"
|
|
316
|
+ :record="record"
|
|
317
|
+ :last_record="last_record"
|
|
318
|
+ :patient_prop="patient"
|
|
319
|
+ :prescription_prop="prescription_prop"
|
|
320
|
+ v-on:menu-msg-tip="menuMsgTip"></msg-tip>
|
321
|
321
|
|
322
|
322
|
</div>
|
323
|
323
|
</template>
|
324
|
324
|
|
325
|
325
|
<script>
|
326
|
|
-import CheckBoxSubMenu from './subMenu/checkBoxSubMenu'
|
327
|
|
-import MultipleSubMenu from './subMenu/multipleSubMenu'
|
328
|
|
-import {commitDialysisPrescription, CreateGroupAdvice, postSign, postSolution} from '@/api/dialysis'
|
|
326
|
+ import CheckBoxSubMenu from './subMenu/checkBoxSubMenu'
|
|
327
|
+ import MultipleSubMenu from './subMenu/multipleSubMenu'
|
|
328
|
+ import {commitDialysisPrescription, CreateGroupAdvice, postSign, postSolution} from '@/api/dialysis'
|
329
|
329
|
|
330
|
|
-import {Toast} from 'vant'
|
331
|
|
-import {getDataConfig} from '@/utils/data'
|
|
330
|
+ import {Toast} from 'vant'
|
|
331
|
+ import {getDataConfig} from '@/utils/data'
|
332
|
332
|
|
333
|
|
-import {parseTime} from '@/utils'
|
334
|
|
-import LongAdviceSubMenu from './subMenu/LongAdviceSubMenu'
|
335
|
|
-import MsgTip from './subMenu/MsgTip'
|
|
333
|
+ import {parseTime} from '@/utils'
|
|
334
|
+ import LongAdviceSubMenu from './subMenu/LongAdviceSubMenu'
|
|
335
|
+ import MsgTip from './subMenu/MsgTip'
|
336
|
336
|
|
337
|
337
|
export default {
|
338
|
338
|
name: 'PrescriptionDialog',
|
|
@@ -343,17 +343,17 @@ import MsgTip from './subMenu/MsgTip'
|
343
|
343
|
return new Array()
|
344
|
344
|
}
|
345
|
345
|
},
|
346
|
|
- predialysis:{
|
347
|
|
- type:Object
|
|
346
|
+ predialysis: {
|
|
347
|
+ type: Object
|
348
|
348
|
},
|
349
|
349
|
last_predialysis: {
|
350
|
|
- type:Object
|
|
350
|
+ type: Object
|
351
|
351
|
},
|
352
|
|
- record:{
|
353
|
|
- type:Object
|
|
352
|
+ record: {
|
|
353
|
+ type: Object
|
354
|
354
|
},
|
355
|
355
|
last_record: {
|
356
|
|
- type:Object
|
|
356
|
+ type: Object
|
357
|
357
|
},
|
358
|
358
|
patient_prop: {
|
359
|
359
|
type: Object
|
|
@@ -406,7 +406,7 @@ import MsgTip from './subMenu/MsgTip'
|
406
|
406
|
},
|
407
|
407
|
data () {
|
408
|
408
|
return {
|
409
|
|
- is_pre:0,
|
|
409
|
+ is_pre: 0,
|
410
|
410
|
loading: false,
|
411
|
411
|
signUrl: '',
|
412
|
412
|
isShowDesc: true,
|
|
@@ -426,8 +426,8 @@ import MsgTip from './subMenu/MsgTip'
|
426
|
426
|
result: [],
|
427
|
427
|
operators: [],
|
428
|
428
|
|
429
|
|
- },
|
430
|
|
- is_show: false,
|
|
429
|
+ },
|
|
430
|
+ is_show: false,
|
431
|
431
|
|
432
|
432
|
perfusion_apparatus: {},
|
433
|
433
|
replacementWays: [],
|
|
@@ -516,7 +516,7 @@ import MsgTip from './subMenu/MsgTip'
|
516
|
516
|
zhiShow: true,
|
517
|
517
|
totalShow: true,
|
518
|
518
|
huShow: true,
|
519
|
|
- doctorAdvices:[],
|
|
519
|
+ doctorAdvices: [],
|
520
|
520
|
propForm: {
|
521
|
521
|
title: '',
|
522
|
522
|
list: [],
|
|
@@ -529,22 +529,21 @@ import MsgTip from './subMenu/MsgTip'
|
529
|
529
|
}
|
530
|
530
|
},
|
531
|
531
|
|
532
|
|
-
|
533
|
|
- methods: {
|
534
|
|
- showmsgtip(){
|
|
532
|
+ methods: {
|
|
533
|
+ showmsgtip () {
|
535
|
534
|
this.msgtip_visibility = true
|
536
|
535
|
this.isShowDialog = false
|
537
|
536
|
|
538
|
|
- },
|
539
|
|
- isPermission () {
|
540
|
|
- if (this.$store.getters.user.user.user_type == 3 && (this.$store.getters.user.template_info.template_id == 2 || this.$store.getters.user.template_info.template_id == 6)) {
|
541
|
|
- return false
|
542
|
|
- } else{
|
543
|
|
- return true
|
544
|
|
- }
|
545
|
|
- },
|
546
|
|
- isShow (name) {
|
547
|
|
- var filedList = this.$store.getters.user.fileds
|
|
537
|
+ },
|
|
538
|
+ isPermission () {
|
|
539
|
+ if (this.$store.getters.user.user.user_type == 3 && (this.$store.getters.user.template_info.template_id == 2 || this.$store.getters.user.template_info.template_id == 6)) {
|
|
540
|
+ return false
|
|
541
|
+ } else {
|
|
542
|
+ return true
|
|
543
|
+ }
|
|
544
|
+ },
|
|
545
|
+ isShow (name) {
|
|
546
|
+ var filedList = this.$store.getters.user.fileds
|
548
|
547
|
|
549
|
548
|
for (let i = 0; i < filedList.length; i++) {
|
550
|
549
|
if (filedList[i].module == 1 && filedList[i].filed_name_cn == name && filedList[i].is_show == 1) {
|
|
@@ -740,13 +739,12 @@ import MsgTip from './subMenu/MsgTip'
|
740
|
739
|
this.isShowDialog = true
|
741
|
740
|
|
742
|
741
|
},
|
743
|
|
- menuMsgTip: function () {
|
744
|
|
- this.msgtip_visibility = false
|
745
|
|
- this.isShowDialog = true
|
746
|
|
- },
|
747
|
|
-
|
748
|
|
- menuComfirmThree: function (targetAdvices) {
|
|
742
|
+ menuMsgTip: function () {
|
|
743
|
+ this.msgtip_visibility = false
|
|
744
|
+ this.isShowDialog = true
|
|
745
|
+ },
|
749
|
746
|
|
|
747
|
+ menuComfirmThree: function (targetAdvices) {
|
750
|
748
|
|
751
|
749
|
if (targetAdvices.length > 0) {
|
752
|
750
|
if (this.is_pre == 1) {
|
|
@@ -759,29 +757,37 @@ import MsgTip from './subMenu/MsgTip'
|
759
|
757
|
Toast.fail(response.data.msg)
|
760
|
758
|
return false
|
761
|
759
|
} else {
|
|
760
|
+
|
|
761
|
+ var d = new Date();
|
|
762
|
+ var year = d.getFullYear();
|
|
763
|
+ var month=d.getMonth()+1;
|
|
764
|
+ var day=d.getDate();
|
|
765
|
+ var hour=d.getHours();
|
|
766
|
+ var minute=d.getMinutes();
|
|
767
|
+ var time = year+'-'+month+'-'+day+' '+hour+':'+minute
|
|
768
|
+
|
|
769
|
+ Toast.success('提交成功')
|
762
|
770
|
let params = {
|
763
|
771
|
advices: targetAdvices,
|
764
|
772
|
advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
765
|
773
|
advice_doctor: targetAdvices[0].advice_doctor,
|
766
|
774
|
advice_type: targetAdvices[0].advice_type,
|
767
|
|
- parent_id: this.patient_id,
|
768
|
|
- start_time: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
|
775
|
+ parent_id: this.$route.query.patient_id,
|
|
776
|
+ start_time: time,
|
769
|
777
|
remark: '',
|
770
|
778
|
}
|
|
779
|
+
|
771
|
780
|
CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
|
772
|
781
|
var resp = rs.data
|
773
|
782
|
if (resp.state == 1) {
|
774
|
|
- this.doctorAdvices = resp.data.advices
|
775
|
|
- Toast.success('提交成功')
|
776
|
|
-
|
777
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
778
|
|
- this.finish()
|
|
783
|
+ this.$emit('prescription', response.data.data.prescription,resp.data.advices)
|
779
|
784
|
|
780
|
785
|
} else {
|
781
|
786
|
|
782
|
787
|
}
|
783
|
788
|
})
|
784
|
789
|
|
|
790
|
+ this.finish()
|
785
|
791
|
}
|
786
|
792
|
})
|
787
|
793
|
|
|
@@ -796,16 +802,36 @@ import MsgTip from './subMenu/MsgTip'
|
796
|
802
|
return false
|
797
|
803
|
} else {
|
798
|
804
|
Toast.success('提交成功')
|
|
805
|
+ var d=new Date();
|
|
806
|
+ var year=d.getFullYear();
|
|
807
|
+ var month=change(d.getMonth()+1);
|
|
808
|
+ var day=change(d.getDate());
|
|
809
|
+ var hour=change(d.getHours());
|
|
810
|
+ var minute=change(d.getMinutes());
|
|
811
|
+ var time=year+'-'+month+'-'+day+' '+hour+':'+minute
|
|
812
|
+ let params = {
|
|
813
|
+ advices: targetAdvices,
|
|
814
|
+ advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
|
815
|
+ advice_doctor: targetAdvices[0].advice_doctor,
|
|
816
|
+ advice_type: targetAdvices[0].advice_type,
|
|
817
|
+ parent_id: this.$route.query.patient_id,
|
|
818
|
+ start_time: time,
|
|
819
|
+ remark: '',
|
|
820
|
+ }
|
|
821
|
+ CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
|
|
822
|
+ var resp = rs.data
|
|
823
|
+ if (resp.state == 1) {
|
|
824
|
+ this.$emit('prescription', response.data.data.prescription,resp.data.advices)
|
|
825
|
+ this.$emit('longSolution', response.data.data.solution,resp.data.advices)
|
|
826
|
+ } else {
|
799
|
827
|
|
800
|
|
- this.$emit('advice')
|
801
|
|
- this.$emit('longSolution', response.data.data.solution,this.doctorAdvices)
|
802
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
|
828
|
+ }
|
|
829
|
+ })
|
803
|
830
|
this.finish()
|
804
|
831
|
}
|
805
|
832
|
})
|
806
|
833
|
}
|
807
|
|
- }else{
|
808
|
|
-
|
|
834
|
+ } else {
|
809
|
835
|
if (this.is_pre == 1) {
|
810
|
836
|
Toast.loading({forbidClick: true, duration: 0})
|
811
|
837
|
let ParamsQuery = this.dialysisPrescription
|
|
@@ -818,7 +844,7 @@ import MsgTip from './subMenu/MsgTip'
|
818
|
844
|
} else {
|
819
|
845
|
Toast.success('提交成功')
|
820
|
846
|
|
821
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
|
847
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
822
|
848
|
this.finish()
|
823
|
849
|
}
|
824
|
850
|
})
|
|
@@ -835,9 +861,8 @@ import MsgTip from './subMenu/MsgTip'
|
835
|
861
|
} else {
|
836
|
862
|
Toast.success('提交成功')
|
837
|
863
|
|
838
|
|
- this.$emit('advice')
|
839
|
|
- this.$emit('longSolution', response.data.data.solution,this.doctorAdvices)
|
840
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
|
864
|
+ this.$emit('longSolution', response.data.data.solution, this.doctorAdvices)
|
|
865
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
841
|
866
|
this.finish()
|
842
|
867
|
}
|
843
|
868
|
})
|
|
@@ -903,21 +928,21 @@ import MsgTip from './subMenu/MsgTip'
|
903
|
928
|
treatment_mode_name = treatment_mode[keys].name
|
904
|
929
|
}
|
905
|
930
|
}
|
906
|
|
- for (let keys in treatment_mode) {
|
907
|
|
- if (treatment_mode[keys].id == val) {
|
908
|
|
- treatment_mode_name = treatment_mode[keys].name
|
909
|
|
- console.log('这是什么', treatment_mode[keys].name)
|
910
|
|
- if (treatment_mode_name == 'HD') {
|
911
|
|
- this.zhiShow = false
|
912
|
|
- this.totalShow = false
|
913
|
|
- this.huShow = false
|
914
|
|
- } else {
|
915
|
|
- this.zhiShow = true
|
916
|
|
- this.totalShow = true
|
917
|
|
- this.huShow = true
|
|
931
|
+ for (let keys in treatment_mode) {
|
|
932
|
+ if (treatment_mode[keys].id == val) {
|
|
933
|
+ treatment_mode_name = treatment_mode[keys].name
|
|
934
|
+ console.log('这是什么', treatment_mode[keys].name)
|
|
935
|
+ if (treatment_mode_name == 'HD') {
|
|
936
|
+ this.zhiShow = false
|
|
937
|
+ this.totalShow = false
|
|
938
|
+ this.huShow = false
|
|
939
|
+ } else {
|
|
940
|
+ this.zhiShow = true
|
|
941
|
+ this.totalShow = true
|
|
942
|
+ this.huShow = true
|
|
943
|
+ }
|
918
|
944
|
}
|
919
|
945
|
}
|
920
|
|
- }
|
921
|
946
|
|
922
|
947
|
return treatment_mode_name
|
923
|
948
|
},
|
|
@@ -978,8 +1003,8 @@ import MsgTip from './subMenu/MsgTip'
|
978
|
1003
|
},
|
979
|
1004
|
commitInfo: function () {
|
980
|
1005
|
this.is_pre = 1
|
981
|
|
-
|
982
|
1006
|
if (this.prescription_prop.id == '') {
|
|
1007
|
+
|
983
|
1008
|
if (this.is_open == 0) {
|
984
|
1009
|
Toast.loading({forbidClick: true, duration: 0})
|
985
|
1010
|
let ParamsQuery = this.dialysisPrescription
|
|
@@ -992,7 +1017,7 @@ import MsgTip from './subMenu/MsgTip'
|
992
|
1017
|
} else {
|
993
|
1018
|
Toast.success('提交成功')
|
994
|
1019
|
|
995
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
|
1020
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
996
|
1021
|
this.finish()
|
997
|
1022
|
}
|
998
|
1023
|
})
|
|
@@ -1021,16 +1046,14 @@ import MsgTip from './subMenu/MsgTip'
|
1021
|
1046
|
} else {
|
1022
|
1047
|
Toast.success('提交成功')
|
1023
|
1048
|
|
1024
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
|
1049
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
1025
|
1050
|
this.finish()
|
1026
|
1051
|
}
|
1027
|
1052
|
})
|
1028
|
1053
|
}
|
1029
|
1054
|
|
1030
|
|
-
|
1031
|
1055
|
} else if (this.is_open == 2) {
|
1032
|
1056
|
if (this.waitUploadAdvices.length > 0) {
|
1033
|
|
-
|
1034
|
1057
|
Toast.loading({forbidClick: true, duration: 0})
|
1035
|
1058
|
let ParamsQuery = this.dialysisPrescription
|
1036
|
1059
|
ParamsQuery['patient'] = this.$route.query.patient_id
|
|
@@ -1042,43 +1065,50 @@ import MsgTip from './subMenu/MsgTip'
|
1042
|
1065
|
} else {
|
1043
|
1066
|
Toast.success('提交成功')
|
1044
|
1067
|
|
1045
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
1046
|
|
- this.finish()
|
1047
|
|
- }
|
1048
|
|
- })
|
1049
|
|
- } else {
|
1050
|
|
- Toast.loading({forbidClick: true, duration: 0})
|
1051
|
|
- let ParamsQuery = this.dialysisPrescription
|
1052
|
|
- ParamsQuery['patient'] = this.$route.query.patient_id
|
1053
|
|
- ParamsQuery['record_date'] = this.record_date
|
1054
|
|
- commitDialysisPrescription(ParamsQuery).then(response => {
|
1055
|
|
- if (response.data.state == 0) {
|
1056
|
|
- Toast.fail(response.data.msg)
|
1057
|
|
- return false
|
1058
|
|
- } else {
|
1059
|
|
- this.advice_visibility = false
|
|
1068
|
+ var d=new Date();
|
|
1069
|
+ var year=d.getFullYear();
|
|
1070
|
+ var month=change(d.getMonth()+1);
|
|
1071
|
+ var day=change(d.getDate());
|
|
1072
|
+ var hour=change(d.getHours());
|
|
1073
|
+ var minute=change(d.getMinutes());
|
|
1074
|
+ var time=year+'-'+month+'-'+day+' '+hour+':'+minute
|
|
1075
|
+
|
1060
|
1076
|
let params = {
|
1061
|
1077
|
advices: this.waitUploadAdvices,
|
1062
|
1078
|
advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
1063
|
1079
|
advice_doctor: this.waitUploadAdvices[0].advice_doctor,
|
1064
|
1080
|
advice_type: this.waitUploadAdvices[0].advice_type,
|
1065
|
|
- parent_id: this.patient_id,
|
1066
|
|
- start_time: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
|
1081
|
+ parent_id: this.$route.query.patient_id,
|
|
1082
|
+ start_time: time,
|
1067
|
1083
|
remark: '',
|
1068
|
1084
|
}
|
1069
|
1085
|
CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
|
1070
|
1086
|
var resp = rs.data
|
1071
|
1087
|
if (resp.state == 1) {
|
1072
|
|
- this.doctorAdvices = resp.data.advices
|
1073
|
|
- Toast.success('提交成功')
|
1074
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
1075
|
|
- this.finish()
|
|
1088
|
+ this.$emit('prescription', response.data.data.prescription, resp.data.advices)
|
1076
|
1089
|
} else {
|
1077
|
1090
|
|
1078
|
1091
|
}
|
1079
|
1092
|
})
|
1080
|
1093
|
|
|
1094
|
+ this.finish()
|
|
1095
|
+ }
|
|
1096
|
+ })
|
|
1097
|
+ } else {
|
|
1098
|
+ Toast.loading({forbidClick: true, duration: 0})
|
|
1099
|
+ let ParamsQuery = this.dialysisPrescription
|
|
1100
|
+ ParamsQuery['patient'] = this.$route.query.patient_id
|
|
1101
|
+ ParamsQuery['record_date'] = this.record_date
|
|
1102
|
+ commitDialysisPrescription(ParamsQuery).then(response => {
|
|
1103
|
+ if (response.data.state == 0) {
|
|
1104
|
+ Toast.fail(response.data.msg)
|
|
1105
|
+ return false
|
|
1106
|
+ } else {
|
|
1107
|
+ this.advice_visibility = false
|
1081
|
1108
|
|
|
1109
|
+ Toast.success('提交成功')
|
|
1110
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
|
1111
|
+ this.finish()
|
1082
|
1112
|
}
|
1083
|
1113
|
})
|
1084
|
1114
|
}
|
|
@@ -1100,7 +1130,7 @@ import MsgTip from './subMenu/MsgTip'
|
1100
|
1130
|
} else {
|
1101
|
1131
|
Toast.success('提交成功')
|
1102
|
1132
|
|
1103
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
|
1133
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
1104
|
1134
|
this.finish()
|
1105
|
1135
|
|
1106
|
1136
|
}
|
|
@@ -1132,7 +1162,7 @@ import MsgTip from './subMenu/MsgTip'
|
1132
|
1162
|
} else {
|
1133
|
1163
|
Toast.success('提交成功')
|
1134
|
1164
|
|
1135
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
|
1165
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
1136
|
1166
|
this.finish()
|
1137
|
1167
|
|
1138
|
1168
|
}
|
|
@@ -1143,7 +1173,6 @@ import MsgTip from './subMenu/MsgTip'
|
1143
|
1173
|
} else if (this.is_open == 2) {
|
1144
|
1174
|
if (this.waitUploadAdvices.length > 0) {
|
1145
|
1175
|
|
1146
|
|
-
|
1147
|
1176
|
Toast.loading({forbidClick: true, duration: 0})
|
1148
|
1177
|
let ParamsQuery = this.dialysisPrescription
|
1149
|
1178
|
ParamsQuery['patient'] = this.$route.query.patient_id
|
|
@@ -1153,52 +1182,64 @@ import MsgTip from './subMenu/MsgTip'
|
1153
|
1182
|
Toast.fail(response.data.msg)
|
1154
|
1183
|
return false
|
1155
|
1184
|
} else {
|
1156
|
|
- Toast.success('提交成功')
|
1157
|
|
- this.$emit('prescription', response.data.data.prescription)
|
1158
|
|
- this.finish()
|
1159
|
1185
|
|
1160
|
|
- }
|
1161
|
|
- })
|
1162
|
|
- }
|
1163
|
|
- else {
|
1164
|
|
- Toast.loading({forbidClick: true, duration: 0})
|
1165
|
|
- let ParamsQuery = this.dialysisPrescription
|
1166
|
|
- ParamsQuery['patient'] = this.$route.query.patient_id
|
1167
|
|
- ParamsQuery['record_date'] = this.record_date
|
1168
|
|
- commitDialysisPrescription(ParamsQuery).then(response => {
|
1169
|
|
- if (response.data.state == 0) {
|
1170
|
|
- Toast.fail(response.data.msg)
|
1171
|
|
- return false
|
1172
|
|
- } else {
|
1173
|
|
- this.advice_visibility = false
|
|
1186
|
+
|
|
1187
|
+ var d=new Date();
|
|
1188
|
+ var year=d.getFullYear();
|
|
1189
|
+ var month=change(d.getMonth()+1);
|
|
1190
|
+ var day=change(d.getDate());
|
|
1191
|
+ var hour=change(d.getHours());
|
|
1192
|
+ var minute=change(d.getMinutes());
|
|
1193
|
+ var time=year+'-'+month+'-'+day+' '+hour+':'+minute
|
|
1194
|
+
|
|
1195
|
+
|
1174
|
1196
|
let params = {
|
1175
|
1197
|
advices: this.waitUploadAdvices,
|
1176
|
1198
|
advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
1177
|
1199
|
advice_doctor: this.waitUploadAdvices[0].advice_doctor,
|
1178
|
1200
|
advice_type: this.waitUploadAdvices[0].advice_type,
|
1179
|
|
- parent_id: this.patient_id,
|
1180
|
|
- start_time: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
|
1201
|
+ parent_id: this.$route.query.patient_id,
|
|
1202
|
+ start_time: time,
|
1181
|
1203
|
remark: '',
|
1182
|
1204
|
}
|
|
1205
|
+
|
1183
|
1206
|
CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
|
1184
|
1207
|
var resp = rs.data
|
1185
|
1208
|
if (resp.state == 1) {
|
1186
|
1209
|
this.doctorAdvices = resp.data.advices
|
1187
|
|
- Toast.success('提交成功')
|
1188
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
1189
|
|
- this.finish()
|
|
1210
|
+ this.$emit('prescription', response.data.data.prescription, resp.data.advices)
|
1190
|
1211
|
|
1191
|
1212
|
} else {
|
1192
|
1213
|
|
1193
|
1214
|
}
|
1194
|
1215
|
})
|
1195
|
1216
|
|
|
1217
|
+ Toast.success('提交成功')
|
|
1218
|
+ this.finish()
|
|
1219
|
+
|
|
1220
|
+ }
|
|
1221
|
+ })
|
|
1222
|
+ } else {
|
|
1223
|
+ Toast.loading({forbidClick: true, duration: 0})
|
|
1224
|
+ let ParamsQuery = this.dialysisPrescription
|
|
1225
|
+ ParamsQuery['patient'] = this.$route.query.patient_id
|
|
1226
|
+ ParamsQuery['record_date'] = this.record_date
|
|
1227
|
+ commitDialysisPrescription(ParamsQuery).then(response => {
|
|
1228
|
+ if (response.data.state == 0) {
|
|
1229
|
+ Toast.fail(response.data.msg)
|
|
1230
|
+ return false
|
|
1231
|
+ } else {
|
|
1232
|
+
|
|
1233
|
+ Toast.success('提交成功')
|
|
1234
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
|
1235
|
+ this.finish()
|
|
1236
|
+
|
1196
|
1237
|
}
|
1197
|
1238
|
})
|
1198
|
1239
|
|
1199
|
1240
|
}
|
1200
|
1241
|
}
|
1201
|
|
- }else{
|
|
1242
|
+ } else {
|
1202
|
1243
|
|
1203
|
1244
|
Toast.loading({forbidClick: true, duration: 0})
|
1204
|
1245
|
let ParamsQuery = this.dialysisPrescription
|
|
@@ -1210,7 +1251,7 @@ import MsgTip from './subMenu/MsgTip'
|
1210
|
1251
|
return false
|
1211
|
1252
|
} else {
|
1212
|
1253
|
Toast.success('提交成功')
|
1213
|
|
- this.$emit('prescription', response.data.data.prescription,this.doctorAdvices)
|
|
1254
|
+ this.$emit('prescription', response.data.data.prescription, this.doctorAdvices)
|
1214
|
1255
|
this.finish()
|
1215
|
1256
|
|
1216
|
1257
|
}
|
|
@@ -1218,7 +1259,6 @@ import MsgTip from './subMenu/MsgTip'
|
1218
|
1259
|
|
1219
|
1260
|
}
|
1220
|
1261
|
|
1221
|
|
-
|
1222
|
1262
|
}
|
1223
|
1263
|
}, commitSolutionInfo: function () {
|
1224
|
1264
|
this.is_pre = 2
|
|
@@ -1294,46 +1334,53 @@ import MsgTip from './subMenu/MsgTip'
|
1294
|
1334
|
} else {
|
1295
|
1335
|
Toast.success('提交成功')
|
1296
|
1336
|
|
1297
|
|
- this.$emit('advice')
|
1298
|
|
- this.$emit('longSolution', response.data.data.solution)
|
1299
|
|
- this.$emit('prescription', response.data.data.prescription)
|
1300
|
|
- this.finish()
|
|
1337
|
+ var d=new Date();
|
|
1338
|
+ var year=d.getFullYear();
|
|
1339
|
+ var month=change(d.getMonth()+1);
|
|
1340
|
+ var day=change(d.getDate());
|
|
1341
|
+ var hour=change(d.getHours());
|
|
1342
|
+ var minute=change(d.getMinutes());
|
|
1343
|
+ var time=year+'-'+month+'-'+day+' '+hour+':'+minute
|
|
1344
|
+
|
1301
|
1345
|
|
1302
|
|
- }
|
1303
|
|
- })
|
1304
|
|
- } else {
|
1305
|
|
- Toast.loading({forbidClick: true, duration: 0})
|
1306
|
|
- let ParamsQuery = this.dialysisPrescription
|
1307
|
|
- ParamsQuery['patient'] = this.$route.query.patient_id
|
1308
|
|
- ParamsQuery['record_date'] = this.record_date
|
1309
|
|
- postSolution(ParamsQuery).then(response => {
|
1310
|
|
- if (response.data.state == 0) {
|
1311
|
|
- Toast.fail(response.data.msg)
|
1312
|
|
- return false
|
1313
|
|
- } else {
|
1314
|
|
- this.advice_visibility = false
|
1315
|
1346
|
let params = {
|
1316
|
1347
|
advices: this.waitUploadAdvices,
|
1317
|
1348
|
advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
1318
|
1349
|
advice_doctor: this.waitUploadAdvices[0].advice_doctor,
|
1319
|
1350
|
advice_type: this.waitUploadAdvices[0].advice_type,
|
1320
|
|
- parent_id: this.patient_id,
|
1321
|
|
- start_time: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
|
1351
|
+ parent_id: this.$route.query.patient_id,
|
|
1352
|
+ start_time: time,
|
1322
|
1353
|
remark: '',
|
1323
|
1354
|
}
|
1324
|
1355
|
CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
|
1325
|
1356
|
var resp = rs.data
|
1326
|
1357
|
if (resp.state == 1) {
|
1327
|
1358
|
this.doctorAdvices = resp.data.advices
|
1328
|
|
-
|
|
1359
|
+ this.$emit('longSolution', response.data.data.solution, resp.data.advices)
|
|
1360
|
+ this.$emit('prescription', response.data.data.prescription, resp.data.advices)
|
1329
|
1361
|
|
1330
|
1362
|
} else {
|
1331
|
1363
|
|
1332
|
1364
|
}
|
1333
|
1365
|
})
|
|
1366
|
+
|
|
1367
|
+ this.finish()
|
|
1368
|
+
|
|
1369
|
+ }
|
|
1370
|
+ })
|
|
1371
|
+ } else {
|
|
1372
|
+ Toast.loading({forbidClick: true, duration: 0})
|
|
1373
|
+ let ParamsQuery = this.dialysisPrescription
|
|
1374
|
+ ParamsQuery['patient'] = this.$route.query.patient_id
|
|
1375
|
+ ParamsQuery['record_date'] = this.record_date
|
|
1376
|
+ postSolution(ParamsQuery).then(response => {
|
|
1377
|
+ if (response.data.state == 0) {
|
|
1378
|
+ Toast.fail(response.data.msg)
|
|
1379
|
+ return false
|
|
1380
|
+ } else {
|
|
1381
|
+
|
1334
|
1382
|
Toast.success('提交成功')
|
1335
|
1383
|
|
1336
|
|
- this.$emit('advice')
|
1337
|
1384
|
this.$emit('longSolution', response.data.data.solution)
|
1338
|
1385
|
this.$emit('prescription', response.data.data.prescription)
|
1339
|
1386
|
this.finish()
|
|
@@ -1358,7 +1405,6 @@ import MsgTip from './subMenu/MsgTip'
|
1358
|
1405
|
} else {
|
1359
|
1406
|
Toast.success('提交成功')
|
1360
|
1407
|
|
1361
|
|
- this.$emit('advice')
|
1362
|
1408
|
this.$emit('longSolution', response.data.data.solution)
|
1363
|
1409
|
this.$emit('prescription', response.data.data.prescription)
|
1364
|
1410
|
this.finish()
|
|
@@ -1393,7 +1439,6 @@ import MsgTip from './subMenu/MsgTip'
|
1393
|
1439
|
} else {
|
1394
|
1440
|
Toast.success('提交成功')
|
1395
|
1441
|
|
1396
|
|
- this.$emit('advice')
|
1397
|
1442
|
this.$emit('longSolution', response.data.data.solution)
|
1398
|
1443
|
this.$emit('prescription', response.data.data.prescription)
|
1399
|
1444
|
this.finish()
|
|
@@ -1416,29 +1461,38 @@ import MsgTip from './subMenu/MsgTip'
|
1416
|
1461
|
return false
|
1417
|
1462
|
} else {
|
1418
|
1463
|
this.advice_visibility = false
|
|
1464
|
+
|
|
1465
|
+
|
|
1466
|
+ var d=new Date();
|
|
1467
|
+ var year=d.getFullYear();
|
|
1468
|
+ var month=change(d.getMonth()+1);
|
|
1469
|
+ var day=change(d.getDate());
|
|
1470
|
+ var hour=change(d.getHours());
|
|
1471
|
+ var minute=change(d.getMinutes());
|
|
1472
|
+ var time = year+'-'+month+'-'+day+' '+hour+':'+minute
|
|
1473
|
+
|
|
1474
|
+
|
1419
|
1475
|
let params = {
|
1420
|
1476
|
advices: this.waitUploadAdvices,
|
1421
|
1477
|
advice_date: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
1422
|
1478
|
advice_doctor: this.waitUploadAdvices[0].advice_doctor,
|
1423
|
1479
|
advice_type: this.waitUploadAdvices[0].advice_type,
|
1424
|
|
- parent_id: this.patient_id,
|
1425
|
|
- start_time: parseTime(this.$route.query.date, '{y}-{m}-{d}'),
|
|
1480
|
+ parent_id: this.$route.query.patient_id,
|
|
1481
|
+ start_time: time,
|
1426
|
1482
|
remark: '',
|
1427
|
1483
|
}
|
1428
|
1484
|
CreateGroupAdvice(this.$route.query.patient_id, 0, params).then(rs => {
|
1429
|
1485
|
var resp = rs.data
|
1430
|
1486
|
if (resp.state == 1) {
|
1431
|
1487
|
this.doctorAdvices = resp.data.advices
|
1432
|
|
- Toast.success('提交成功')
|
1433
|
|
- this.$emit('advice')
|
1434
|
|
- this.$emit('longSolution', response.data.data.solution)
|
1435
|
|
- this.$emit('prescription', response.data.data.prescription)
|
1436
|
|
- this.finish()
|
|
1488
|
+ this.$emit('longSolution', response.data.data.solution,resp.data.advices)
|
|
1489
|
+ this.$emit('prescription', response.data.data.prescription,resp.data.advices)
|
1437
|
1490
|
} else {
|
1438
|
1491
|
|
1439
|
1492
|
}
|
1440
|
1493
|
})
|
1441
|
|
-
|
|
1494
|
+ Toast.success('提交成功')
|
|
1495
|
+ this.finish()
|
1442
|
1496
|
|
1443
|
1497
|
}
|
1444
|
1498
|
})
|
|
@@ -1461,7 +1515,7 @@ import MsgTip from './subMenu/MsgTip'
|
1461
|
1515
|
})
|
1462
|
1516
|
}
|
1463
|
1517
|
}
|
1464
|
|
- }else{
|
|
1518
|
+ } else {
|
1465
|
1519
|
|
1466
|
1520
|
Toast.loading({forbidClick: true, duration: 0})
|
1467
|
1521
|
let ParamsQuery = this.dialysisPrescription
|