|
@@ -911,17 +911,21 @@ export default {
|
911
|
911
|
var today = new Date()
|
912
|
912
|
this.form.inspect_date = uParseTime(today, '{y}-{m}-{d} {h}:{i}')
|
913
|
913
|
this.form.formItem = []
|
|
914
|
+
|
|
915
|
+ console.log("hhhhhhhhhhhhhhhhhhhhhhhhhhhh",this.project.inspection_reference)
|
914
|
916
|
for (var index in this.project.inspection_reference) {
|
915
|
|
- // var formItem = this.project.inspection_reference[index];
|
916
|
|
- // formItem["value"] = '';
|
917
|
|
- // if (formItem.range_type==2) {
|
918
|
|
- // formItem["select_options"] = formItem.range_options.split(",");
|
919
|
|
- // }
|
|
917
|
+ var item_id =0
|
|
918
|
+ if(this.project.inspection_reference[index].item_id == 0){
|
|
919
|
+ item_id = parseInt(this.project.inspection_reference[index].id)
|
|
920
|
+ }
|
|
921
|
+ if(this.project.inspection_reference[index].item_id > 0){
|
|
922
|
+ item_id = parseInt(this.project.inspection_reference[index].item_id)
|
|
923
|
+ }
|
920
|
924
|
this.form.formItem.push({
|
921
|
925
|
id: 0,
|
922
|
926
|
project_id: this.project.inspection_reference[index].project_id,
|
923
|
927
|
project_name: this.project.inspection_reference[index].project_name,
|
924
|
|
- item_id: this.project.inspection_reference[index].id,
|
|
928
|
+ item_id:item_id,
|
925
|
929
|
item: this.project.inspection_reference[index].item,
|
926
|
930
|
item_name: this.project.inspection_reference[index].item_name,
|
927
|
931
|
range_type: this.project.inspection_reference[index].range_type,
|
|
@@ -1023,10 +1027,11 @@ export default {
|
1023
|
1027
|
this.$message.error('未填写项目')
|
1024
|
1028
|
return false
|
1025
|
1029
|
}
|
1026
|
|
- for (var index in this.form.formItem) {
|
1027
|
|
- this.form.formItem[index].value =
|
1028
|
|
- '' + this.form.formItem[index].value
|
1029
|
|
- }
|
|
1030
|
+ for (var index in this.form.formItem) {this.form.formItem[index].value ='' + this.form.formItem[index].value}
|
|
1031
|
+
|
|
1032
|
+ console.log("this.form",this.form)
|
|
1033
|
+
|
|
1034
|
+
|
1030
|
1035
|
CreatePatientInspection(
|
1031
|
1036
|
this.patientID,
|
1032
|
1037
|
this.form,
|
|
@@ -1352,7 +1357,7 @@ export default {
|
1352
|
1357
|
console.log('执行0',inspectionsMap[items[index].id]);
|
1353
|
1358
|
|
1354
|
1359
|
if (typeof(inspectionsMap[parseInt(items[index].item_id)]) == "undefined") {
|
1355
|
|
- if(this.org_id == 10121 || this.org_id ==10138 || this.org_id ==10278 ){
|
|
1360
|
+ if(this.org_id == 10121 || this.org_id ==10138 || this.org_id ==10278){
|
1356
|
1361
|
item.value = inspectionsMap[items[index].id].inspect_value
|
1357
|
1362
|
item.item_name = inspectionsMap[items[index].id].item_name
|
1358
|
1363
|
}else{
|