|
@@ -42,8 +42,10 @@
|
42
|
42
|
<el-radio-button label="病历"></el-radio-button>
|
43
|
43
|
</el-radio-group>
|
44
|
44
|
</div>
|
45
|
|
- <desk-prescription :prescriptions="prescriptions" :patientInfo="patientInfo" :hisPatientInfo="hisPatientInfo" v-if="titleType == '处方'" style="flex:1;"></desk-prescription>
|
46
|
|
- <desk-record :record_date="record_date" :case_history="case_history" :patientInfo="patientInfo" :hisPatientInfo="hisPatientInfo" v-if="titleType == '病历'"></desk-record>
|
|
45
|
+ <desk-prescription ref="prescriptions" :prescriptions="prescriptions" :patientInfo="patientInfo" :hisPatientInfo="hisPatientInfo"
|
|
46
|
+ v-if="titleType == '处方'" style="flex:1;"></desk-prescription>
|
|
47
|
+ <desk-record :record_date="record_date" :case_history="case_history" :patientInfo="patientInfo"
|
|
48
|
+ :hisPatientInfo="hisPatientInfo" v-if="titleType == '病历'"></desk-record>
|
47
|
49
|
</div>
|
48
|
50
|
|
49
|
51
|
</div>
|
|
@@ -56,9 +58,8 @@
|
56
|
58
|
import deskRecord from './components/deskRecord'
|
57
|
59
|
import { getPatientInfo, getSchedulePatientList } from '@/api/his/his'
|
58
|
60
|
|
59
|
|
- import {
|
60
|
|
- uParseTime
|
61
|
|
- } from "@/utils/tools";
|
|
61
|
+ import { uParseTime } from '@/utils/tools'
|
|
62
|
+
|
62
|
63
|
export default {
|
63
|
64
|
components: {
|
64
|
65
|
BreadCrumb,
|
|
@@ -67,11 +68,11 @@
|
67
|
68
|
},
|
68
|
69
|
data() {
|
69
|
70
|
return {
|
70
|
|
- prescriptions:[
|
|
71
|
+ prescriptions: [
|
71
|
72
|
{
|
72
|
|
- name:"处方1",
|
73
|
|
- advice:[],
|
74
|
|
- project:[],
|
|
73
|
+ name: '处方1',
|
|
74
|
+ advice: [],
|
|
75
|
+ project: []
|
75
|
76
|
}
|
76
|
77
|
],
|
77
|
78
|
search_input: '',
|
|
@@ -87,13 +88,11 @@
|
87
|
88
|
patientTableData: [{}],
|
88
|
89
|
patientInfo: {},
|
89
|
90
|
hisPatientInfo: {},
|
90
|
|
- case_history:{},
|
|
91
|
+ case_history: {}
|
91
|
92
|
}
|
92
|
93
|
},
|
93
|
94
|
methods: {
|
94
|
|
- changeTab(val){
|
95
|
|
-
|
96
|
|
-
|
|
95
|
+ changeTab(val) {
|
97
|
96
|
|
98
|
97
|
},
|
99
|
98
|
searchAction() {
|
|
@@ -144,40 +143,59 @@
|
144
|
143
|
this.patientInfo = response.data.data.xt_info
|
145
|
144
|
this.hisPatientInfo = response.data.data.his_info
|
146
|
145
|
this.case_history = response.data.data.case_history
|
147
|
|
- this.patientInfo.birth = uParseTime(this.patientInfo.birthday, "{y}-{m}-{d}");
|
148
|
|
- if(this.case_history.temperature <= 0){
|
149
|
|
- this.case_history.temperature = ""
|
|
146
|
+ this.patientInfo.birth = uParseTime(this.patientInfo.birthday, '{y}-{m}-{d}')
|
|
147
|
+ if (this.case_history.temperature <= 0) {
|
|
148
|
+ this.case_history.temperature = ''
|
150
|
149
|
}
|
151
|
|
- if(this.case_history.blood_sugar <= 0){
|
152
|
|
- this.case_history.blood_sugar = ""
|
|
150
|
+ if (this.case_history.blood_sugar <= 0) {
|
|
151
|
+ this.case_history.blood_sugar = ''
|
153
|
152
|
}
|
154
|
|
- if(this.case_history.pulse <= 0){
|
155
|
|
- this.case_history.pulse = ""
|
|
153
|
+ if (this.case_history.pulse <= 0) {
|
|
154
|
+ this.case_history.pulse = ''
|
156
|
155
|
}
|
157
|
|
- if(this.case_history.sbp <= 0){
|
158
|
|
- this.case_history.sbp = ""
|
|
156
|
+ if (this.case_history.sbp <= 0) {
|
|
157
|
+ this.case_history.sbp = ''
|
159
|
158
|
}
|
160
|
|
- if(this.case_history.dbp <= 0){
|
161
|
|
- this.case_history.dbp = ""
|
|
159
|
+ if (this.case_history.dbp <= 0) {
|
|
160
|
+ this.case_history.dbp = ''
|
162
|
161
|
}
|
163
|
|
- if(this.case_history.height <= 0){
|
164
|
|
- this.case_history.height = ""
|
|
162
|
+ if (this.case_history.height <= 0) {
|
|
163
|
+ this.case_history.height = ''
|
165
|
164
|
}
|
166
|
|
- if(this.case_history.blood_fat <= 0){
|
167
|
|
- this.case_history.blood_fat = ""
|
|
165
|
+ if (this.case_history.blood_fat <= 0) {
|
|
166
|
+ this.case_history.blood_fat = ''
|
168
|
167
|
}
|
169
|
|
- if(this.case_history.sick_type <= 0){
|
170
|
|
- this.case_history.sick_type = ""
|
|
168
|
+ if (this.case_history.sick_type <= 0) {
|
|
169
|
+ this.case_history.sick_type = ''
|
171
|
170
|
}
|
172
|
|
- this.case_history.sick_date = uParseTime(this.case_history.sick_date, "{y}-{m}-{d}");
|
173
|
|
- if(this.case_history.is_infect == 1){
|
|
171
|
+ this.case_history.sick_date = uParseTime(this.case_history.sick_date, '{y}-{m}-{d}')
|
|
172
|
+ if (this.case_history.is_infect == 1) {
|
174
|
173
|
this.case_history.is_infect = true
|
175
|
|
- }else{
|
|
174
|
+ } else {
|
176
|
175
|
this.case_history.is_infect = false
|
177
|
|
-
|
178
|
176
|
}
|
179
|
|
-
|
180
|
|
-
|
|
177
|
+ this.prescriptions = []
|
|
178
|
+ if (response.data.data.prescription.length > 0) {
|
|
179
|
+ for (let i = 0; i < response.data.data.prescription.length; i++) {
|
|
180
|
+ var prescription = response.data.data.prescription[i]
|
|
181
|
+ let index = i + 1
|
|
182
|
+ let obj = {
|
|
183
|
+ name: "处方" + index,
|
|
184
|
+ advices: prescription.advices,
|
|
185
|
+ projects: prescription.project,
|
|
186
|
+ }
|
|
187
|
+ this.prescriptions.push(obj)
|
|
188
|
+ }
|
|
189
|
+ }else{
|
|
190
|
+ let obj = {
|
|
191
|
+ name: "处方" + 1,
|
|
192
|
+ advices: [],
|
|
193
|
+ projects: [],
|
|
194
|
+ }
|
|
195
|
+ this.prescriptions.push(obj)
|
|
196
|
+ }
|
|
197
|
+ console.log()
|
|
198
|
+ this.$refs.prescriptions.setData(this.prescriptions)
|
181
|
199
|
}
|
182
|
200
|
})
|
183
|
201
|
|