|
@@ -377,7 +377,7 @@
|
377
|
377
|
allow-create
|
378
|
378
|
:disabled="isChild"
|
379
|
379
|
placeholder="请选择(输入可搜索)"
|
380
|
|
- style="width:200px"
|
|
380
|
+ style="width:100%"
|
381
|
381
|
@change="changeDrugName"
|
382
|
382
|
>
|
383
|
383
|
<el-option
|
|
@@ -396,12 +396,12 @@
|
396
|
396
|
|
397
|
397
|
</el-row>
|
398
|
398
|
<el-row>
|
399
|
|
- <el-col :span="13">
|
|
399
|
+ <el-col :span="12">
|
400
|
400
|
<!--<el-form-item label="规格 :" prop="advice_desc">-->
|
401
|
401
|
<!--<el-input v-model="nameForm.advice_desc"></el-input>-->
|
402
|
402
|
<!--</el-form-item>-->
|
403
|
403
|
<el-form-item label="药品规格 :" prop="advice_desc">
|
404
|
|
- <el-col :span="10">
|
|
404
|
+ <el-col :span="8">
|
405
|
405
|
<!-- <el-input v-model="nameForm.advice_desc"></el-input> -->
|
406
|
406
|
<el-select
|
407
|
407
|
v-model="nameForm.advice_desc"
|
|
@@ -410,7 +410,6 @@
|
410
|
410
|
allow-create
|
411
|
411
|
:disabled="isChild"
|
412
|
412
|
placeholder="请选择(输入可搜索)"
|
413
|
|
- style="width:150px"
|
414
|
413
|
@change="changeDrugDesc"
|
415
|
414
|
>
|
416
|
415
|
<el-option
|
|
@@ -423,14 +422,13 @@
|
423
|
422
|
|
424
|
423
|
</el-col>
|
425
|
424
|
<el-col class="line" :span="2"> </el-col>
|
426
|
|
- <el-col :span="10">
|
|
425
|
+ <el-col :span="14">
|
427
|
426
|
<el-select
|
428
|
427
|
v-model="nameForm.drug_spec_unit"
|
429
|
428
|
filterable
|
430
|
429
|
clearable
|
431
|
430
|
allow-create
|
432
|
431
|
placeholder="选择"
|
433
|
|
- style="width:120px"
|
434
|
432
|
>
|
435
|
433
|
<el-option
|
436
|
434
|
v-for="item in unitsOption"
|
|
@@ -442,7 +440,7 @@
|
442
|
440
|
</el-col>
|
443
|
441
|
</el-form-item>
|
444
|
442
|
</el-col>
|
445
|
|
- <el-col :span="9">
|
|
443
|
+ <el-col :span="12">
|
446
|
444
|
<el-form-item label="开药数量 :" prop="prescribing_number">
|
447
|
445
|
<el-col :span="8">
|
448
|
446
|
<el-input v-model="nameForm.prescribing_number"></el-input>
|
|
@@ -647,7 +645,8 @@ export default {
|
647
|
645
|
current_drug_name:"",
|
648
|
646
|
current_drug_spec: "",
|
649
|
647
|
drug_id: 0,
|
650
|
|
- src_type:""
|
|
648
|
+ src_type:"",
|
|
649
|
+ private_drug_config:{},
|
651
|
650
|
};
|
652
|
651
|
},
|
653
|
652
|
props: {
|
|
@@ -699,10 +698,9 @@ export default {
|
699
|
698
|
},
|
700
|
699
|
methods: {
|
701
|
700
|
submitgroupAdvice(formName) {
|
702
|
|
-
|
703
|
701
|
this.$refs[formName].validate(valid => {
|
704
|
702
|
if (valid) {
|
705
|
|
- var submitForm = {
|
|
703
|
+ var submitForm = {
|
706
|
704
|
advice_type: this.groupForm.advice_type,
|
707
|
705
|
advice_date: this.groupForm.advice_date,
|
708
|
706
|
start_time: this.groupForm.start_time,
|
|
@@ -711,8 +709,7 @@ export default {
|
711
|
709
|
remark: this.groupForm.remark,
|
712
|
710
|
parent_id: this.groupForm.parent_id
|
713
|
711
|
};
|
714
|
|
-
|
715
|
|
- console.log("888888",this.groupForm.adviceNames)
|
|
712
|
+
|
716
|
713
|
var adviceNames = [];
|
717
|
714
|
for (const index in this.groupForm.adviceNames) {
|
718
|
715
|
adviceNames.unshift(this.groupForm.adviceNames[index]);
|
|
@@ -720,9 +717,18 @@ export default {
|
720
|
717
|
submitForm.adviceNames = adviceNames;
|
721
|
718
|
let mode = "1";
|
722
|
719
|
|
723
|
|
-
|
724
|
720
|
console.log("88888888",submitForm)
|
725
|
|
-
|
|
721
|
+ console.log("99999",this.medicals)
|
|
722
|
+ if(this.private_drug_config.drug_start == 1){
|
|
723
|
+
|
|
724
|
+ for(let index=0;index<submitForm.adviceNames.length;index++){
|
|
725
|
+ for(let i=0;i<this.medicals.length;i++){
|
|
726
|
+ if(submitForm.adviceNames[index].drug_id == this.medicals[i].drug_name_id){
|
|
727
|
+ submitForm.adviceNames[index].way = 2
|
|
728
|
+ }
|
|
729
|
+ }
|
|
730
|
+ }
|
|
731
|
+ }
|
726
|
732
|
CreateGroupAdvice(this.patientID, 0, submitForm, mode).then(
|
727
|
733
|
response => {
|
728
|
734
|
if (response.data.state == 0) {
|
|
@@ -1134,6 +1140,7 @@ export default {
|
1134
|
1140
|
}
|
1135
|
1141
|
},
|
1136
|
1142
|
templateTableChange(currentRow, oldCurrentRow) {
|
|
1143
|
+ console.log("params -----",currentRow)
|
1137
|
1144
|
this.selectedTemp = { id: 0, name: "", org_id: 0, list: [], rows: [] };
|
1138
|
1145
|
if (currentRow == null) {
|
1139
|
1146
|
return false;
|
|
@@ -1148,40 +1155,20 @@ export default {
|
1148
|
1155
|
.DoctorAdviceTemplate) {
|
1149
|
1156
|
thisRowKey++;
|
1150
|
1157
|
var item = {
|
1151
|
|
- advice_name: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[
|
1152
|
|
- index
|
1153
|
|
- ].advice_name,
|
1154
|
|
- advice_desc: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[
|
1155
|
|
- index
|
1156
|
|
- ].advice_desc,
|
1157
|
|
- single_dose:
|
1158
|
|
- "" +
|
1159
|
|
- this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index]
|
1160
|
|
- .single_dose,
|
1161
|
|
- single_dose_unit: this.adviceTemplateMaps[mapid]
|
1162
|
|
- .DoctorAdviceTemplate[index].single_dose_unit,
|
1163
|
|
- drug_spec:
|
1164
|
|
- "" +
|
1165
|
|
- this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].drug_spec,
|
|
1158
|
+ advice_name: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].advice_name,
|
|
1159
|
+ advice_desc: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].advice_desc,
|
|
1160
|
+ single_dose:"" +this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].single_dose,
|
|
1161
|
+ single_dose_unit: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].single_dose_unit,
|
|
1162
|
+ drug_spec:"" +this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].drug_spec,
|
1166
|
1163
|
drug_spec_unit: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].drug_spec_unit,
|
1167
|
|
- prescribing_number:
|
1168
|
|
- "" +
|
1169
|
|
- this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index]
|
1170
|
|
- .prescribing_number,
|
1171
|
|
- prescribing_number_unit: this.adviceTemplateMaps[mapid]
|
1172
|
|
- .DoctorAdviceTemplate[index].prescribing_number_unit,
|
1173
|
|
- delivery_way: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[
|
1174
|
|
- index
|
1175
|
|
- ].delivery_way,
|
1176
|
|
- execution_frequency: this.adviceTemplateMaps[mapid]
|
1177
|
|
- .DoctorAdviceTemplate[index].execution_frequency,
|
1178
|
|
- selection: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[
|
1179
|
|
- index
|
1180
|
|
- ].selection,
|
1181
|
|
- advice_id: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[
|
1182
|
|
- index
|
1183
|
|
- ].id,
|
1184
|
|
-
|
|
1164
|
+ prescribing_number:"" +this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].prescribing_number,
|
|
1165
|
+ prescribing_number_unit: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].prescribing_number_unit,
|
|
1166
|
+ delivery_way: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].delivery_way,
|
|
1167
|
+ execution_frequency: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].execution_frequency,
|
|
1168
|
+ selection: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].selection,
|
|
1169
|
+ advice_id: this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].id,
|
|
1170
|
+ drug_id:this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].drug_id,
|
|
1171
|
+ way:this.adviceTemplateMaps[mapid].DoctorAdviceTemplate[index].way,
|
1185
|
1172
|
isEdit: 0,
|
1186
|
1173
|
id: 0,
|
1187
|
1174
|
children: [],
|
|
@@ -1212,11 +1199,14 @@ export default {
|
1212
|
1199
|
prescribing_number_unit: children[key].prescribing_number_unit,
|
1213
|
1200
|
delivery_way: children[key].delivery_way,
|
1214
|
1201
|
execution_frequency: children[key].execution_frequency,
|
|
1202
|
+ drug_id:children[key].drug_id,
|
|
1203
|
+ way:children[key].way,
|
1215
|
1204
|
isEdit: 0,
|
1216
|
1205
|
id: 0,
|
1217
|
1206
|
children: [],
|
1218
|
1207
|
parent_row: parentRow,
|
1219
|
|
- row_key: thisRowKey
|
|
1208
|
+ row_key: thisRowKey,
|
|
1209
|
+
|
1220
|
1210
|
};
|
1221
|
1211
|
item.children.push(child);
|
1222
|
1212
|
}
|
|
@@ -1236,36 +1226,27 @@ export default {
|
1236
|
1226
|
if (adviceTemplate.DoctorAdviceTemplate[index].selection) {
|
1237
|
1227
|
thisRowKey++;
|
1238
|
1228
|
var item = {
|
1239
|
|
- advice_name:
|
1240
|
|
- adviceTemplate.DoctorAdviceTemplate[index].advice_name,
|
1241
|
|
- advice_desc:
|
1242
|
|
- adviceTemplate.DoctorAdviceTemplate[index].advice_desc,
|
1243
|
|
- single_dose:
|
1244
|
|
- "" + adviceTemplate.DoctorAdviceTemplate[index].single_dose,
|
1245
|
|
- single_dose_unit:
|
1246
|
|
- adviceTemplate.DoctorAdviceTemplate[index].single_dose_unit,
|
1247
|
|
- drug_spec:
|
1248
|
|
- "" + adviceTemplate.DoctorAdviceTemplate[index].drug_spec,
|
1249
|
|
- drug_spec_unit:
|
1250
|
|
- adviceTemplate.DoctorAdviceTemplate[index].drug_spec_unit,
|
1251
|
|
- prescribing_number:
|
1252
|
|
- "" +
|
1253
|
|
- adviceTemplate.DoctorAdviceTemplate[index].prescribing_number,
|
1254
|
|
- prescribing_number_unit:
|
1255
|
|
- adviceTemplate.DoctorAdviceTemplate[index]
|
1256
|
|
- .prescribing_number_unit,
|
1257
|
|
- delivery_way:
|
1258
|
|
- adviceTemplate.DoctorAdviceTemplate[index].delivery_way,
|
1259
|
|
- execution_frequency:
|
1260
|
|
- adviceTemplate.DoctorAdviceTemplate[index].execution_frequency,
|
|
1229
|
+ advice_name:adviceTemplate.DoctorAdviceTemplate[index].advice_name,
|
|
1230
|
+ advice_desc:adviceTemplate.DoctorAdviceTemplate[index].advice_desc,
|
|
1231
|
+ single_dose:"" + adviceTemplate.DoctorAdviceTemplate[index].single_dose,
|
|
1232
|
+ single_dose_unit:adviceTemplate.DoctorAdviceTemplate[index].single_dose_unit,
|
|
1233
|
+ drug_spec:"" + adviceTemplate.DoctorAdviceTemplate[index].drug_spec,
|
|
1234
|
+ drug_spec_unit:adviceTemplate.DoctorAdviceTemplate[index].drug_spec_unit,
|
|
1235
|
+ prescribing_number:"" +adviceTemplate.DoctorAdviceTemplate[index].prescribing_number,
|
|
1236
|
+ prescribing_number_unit:adviceTemplate.DoctorAdviceTemplate[index].prescribing_number_unit,
|
|
1237
|
+ delivery_way:adviceTemplate.DoctorAdviceTemplate[index].delivery_way,
|
|
1238
|
+ execution_frequency:adviceTemplate.DoctorAdviceTemplate[index].execution_frequency,
|
1261
|
1239
|
advice_id: adviceTemplate.DoctorAdviceTemplate[index].id,
|
1262
|
1240
|
selection: adviceTemplate.DoctorAdviceTemplate[index].selection,
|
|
1241
|
+ drug_id: adviceTemplate.DoctorAdviceTemplate[index].drug_id,
|
|
1242
|
+ way:adviceTemplate.DoctorAdviceTemplate[index].way,
|
1263
|
1243
|
isEdit: 0,
|
1264
|
1244
|
id: 0,
|
1265
|
1245
|
children: [],
|
1266
|
1246
|
parent_row: 0,
|
1267
|
1247
|
row_key: thisRowKey
|
1268
|
1248
|
};
|
|
1249
|
+ console.log("items========",item)
|
1269
|
1250
|
if (
|
1270
|
1251
|
"children" in adviceTemplate.DoctorAdviceTemplate[index] &&
|
1271
|
1252
|
adviceTemplate.DoctorAdviceTemplate[index].children.length > 0
|
|
@@ -1284,16 +1265,18 @@ export default {
|
1284
|
1265
|
drug_spec: "" + children[key].drug_spec,
|
1285
|
1266
|
drug_spec_unit: children[key].drug_spec_unit,
|
1286
|
1267
|
prescribing_number: "" + children[key].prescribing_number,
|
1287
|
|
- prescribing_number_unit:
|
1288
|
|
- children[key].prescribing_number_unit,
|
|
1268
|
+ prescribing_number_unit:children[key].prescribing_number_unit,
|
1289
|
1269
|
delivery_way: children[key].delivery_way,
|
1290
|
1270
|
execution_frequency: children[key].execution_frequency,
|
|
1271
|
+ drug_id:children[key].drug_id,
|
|
1272
|
+ way:children[key].way,
|
1291
|
1273
|
isEdit: 0,
|
1292
|
1274
|
id: 0,
|
1293
|
1275
|
children: [],
|
1294
|
1276
|
parent_row: parentRow,
|
1295
|
1277
|
row_key: thisRowKey
|
1296
|
1278
|
};
|
|
1279
|
+ conosle.log("item======",child)
|
1297
|
1280
|
item.children.push(child);
|
1298
|
1281
|
this.allSelectedTemplate.unshift(child);
|
1299
|
1282
|
}
|
|
@@ -1329,13 +1312,12 @@ export default {
|
1329
|
1312
|
single_dose_unit: this.allSelectedTemplate[index].single_dose_unit,
|
1330
|
1313
|
drug_spec: "" + this.allSelectedTemplate[index].drug_spec,
|
1331
|
1314
|
drug_spec_unit: this.allSelectedTemplate[index].drug_spec_unit,
|
1332
|
|
- prescribing_number:
|
1333
|
|
- "" + this.allSelectedTemplate[index].prescribing_number,
|
1334
|
|
- prescribing_number_unit: this.allSelectedTemplate[index]
|
1335
|
|
- .prescribing_number_unit,
|
|
1315
|
+ prescribing_number:"" + this.allSelectedTemplate[index].prescribing_number,
|
|
1316
|
+ prescribing_number_unit: this.allSelectedTemplate[index].prescribing_number_unit,
|
1336
|
1317
|
delivery_way: this.allSelectedTemplate[index].delivery_way,
|
1337
|
|
- execution_frequency: this.allSelectedTemplate[index]
|
1338
|
|
- .execution_frequency,
|
|
1318
|
+ execution_frequency: this.allSelectedTemplate[index].execution_frequency,
|
|
1319
|
+ drug_id:this.allSelectedTemplate[index].drug_id,
|
|
1320
|
+ way:this.allSelectedTemplate[index].way,
|
1339
|
1321
|
isEdit: 0,
|
1340
|
1322
|
id: 0,
|
1341
|
1323
|
children: [],
|
|
@@ -1360,6 +1342,8 @@ export default {
|
1360
|
1342
|
prescribing_number_unit: children[key].prescribing_number_unit,
|
1361
|
1343
|
delivery_way: children[key].delivery_way,
|
1362
|
1344
|
execution_frequency: children[key].execution_frequency,
|
|
1345
|
+ drug_id:children[key].drug_id,
|
|
1346
|
+ way:children[key].way,
|
1363
|
1347
|
isEdit: 0,
|
1364
|
1348
|
id: 0,
|
1365
|
1349
|
children: [],
|
|
@@ -1524,8 +1508,8 @@ export default {
|
1524
|
1508
|
var base_drug_list = response.data.data.base_drug_list
|
1525
|
1509
|
var base_drug_cofig = response.data.data.base_drug_config
|
1526
|
1510
|
var private_drug_cofig = response.data.data.private_drug_config
|
1527
|
|
-
|
1528
|
|
-
|
|
1511
|
+
|
|
1512
|
+
|
1529
|
1513
|
if(private_drug_cofig != null&&private_drug_cofig.drug_start == 1) {
|
1530
|
1514
|
|
1531
|
1515
|
for (let i = 0; i < medicalList.length; i++) {
|
|
@@ -1596,6 +1580,8 @@ export default {
|
1596
|
1580
|
obj.drug_specs = base_drug_list[i].drug_specs
|
1597
|
1581
|
this.all_drug.push(obj)
|
1598
|
1582
|
}
|
|
1583
|
+ this.private_drug_config = response.data.data.private_drug_config
|
|
1584
|
+ this.medicals = medicalList
|
1599
|
1585
|
}
|
1600
|
1586
|
})
|
1601
|
1587
|
|