fix: set company while creating encounter, fields rearranged
This commit is contained in:
parent
82aeff0a32
commit
9c7d45deae
@ -193,7 +193,6 @@ let check_and_set_availability = function(frm) {
|
|||||||
d.hide();
|
d.hide();
|
||||||
frm.enable_save();
|
frm.enable_save();
|
||||||
frm.save();
|
frm.save();
|
||||||
frm.enable_save();
|
|
||||||
d.get_primary_btn().attr('disabled', true);
|
d.get_primary_btn().attr('disabled', true);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -400,6 +399,7 @@ let create_vital_signs = function(frm) {
|
|||||||
frappe.route_options = {
|
frappe.route_options = {
|
||||||
'patient': frm.doc.patient,
|
'patient': frm.doc.patient,
|
||||||
'appointment': frm.doc.name,
|
'appointment': frm.doc.name,
|
||||||
|
'company': frm.doc.company
|
||||||
};
|
};
|
||||||
frappe.new_doc('Vital Signs');
|
frappe.new_doc('Vital Signs');
|
||||||
};
|
};
|
||||||
@ -432,6 +432,7 @@ frappe.ui.form.on('Patient Appointment', 'practitioner', function(frm) {
|
|||||||
callback: function (data) {
|
callback: function (data) {
|
||||||
frappe.model.set_value(frm.doctype, frm.docname, 'department', data.message.department);
|
frappe.model.set_value(frm.doctype, frm.docname, 'department', data.message.department);
|
||||||
frappe.model.set_value(frm.doctype, frm.docname, 'paid_amount', data.message.op_consulting_charge);
|
frappe.model.set_value(frm.doctype, frm.docname, 'paid_amount', data.message.op_consulting_charge);
|
||||||
|
frappe.model.set_value(frm.doctype, frm.docname, 'billing_item', data.message.op_consulting_charge_item);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -14,13 +14,16 @@
|
|||||||
"patient_name",
|
"patient_name",
|
||||||
"patient_sex",
|
"patient_sex",
|
||||||
"patient_age",
|
"patient_age",
|
||||||
"inpatient_record",
|
|
||||||
"column_break_1",
|
"column_break_1",
|
||||||
"status",
|
"inpatient_record",
|
||||||
"procedure_template",
|
"company",
|
||||||
"get_procedure_from_encounter",
|
|
||||||
"procedure_prescription",
|
|
||||||
"service_unit",
|
"service_unit",
|
||||||
|
"status",
|
||||||
|
"section_break_11",
|
||||||
|
"get_procedure_from_encounter",
|
||||||
|
"column_break_13",
|
||||||
|
"procedure_template",
|
||||||
|
"procedure_prescription",
|
||||||
"section_break_12",
|
"section_break_12",
|
||||||
"practitioner",
|
"practitioner",
|
||||||
"department",
|
"department",
|
||||||
@ -32,9 +35,9 @@
|
|||||||
"duration",
|
"duration",
|
||||||
"section_break_16",
|
"section_break_16",
|
||||||
"mode_of_payment",
|
"mode_of_payment",
|
||||||
"paid_amount",
|
"billing_item",
|
||||||
"company",
|
|
||||||
"column_break_2",
|
"column_break_2",
|
||||||
|
"paid_amount",
|
||||||
"invoiced",
|
"invoiced",
|
||||||
"ref_sales_invoice",
|
"ref_sales_invoice",
|
||||||
"section_break_3",
|
"section_break_3",
|
||||||
@ -114,7 +117,8 @@
|
|||||||
"label": "Procedure Prescription",
|
"label": "Procedure Prescription",
|
||||||
"no_copy": 1,
|
"no_copy": 1,
|
||||||
"options": "Procedure Prescription",
|
"options": "Procedure Prescription",
|
||||||
"print_hide": 1
|
"print_hide": 1,
|
||||||
|
"read_only": 1
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"fieldname": "service_unit",
|
"fieldname": "service_unit",
|
||||||
@ -140,6 +144,7 @@
|
|||||||
"set_only_once": 1
|
"set_only_once": 1
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
"fetch_from": "practitioner.department",
|
||||||
"fieldname": "department",
|
"fieldname": "department",
|
||||||
"fieldtype": "Link",
|
"fieldtype": "Link",
|
||||||
"ignore_user_permissions": 1,
|
"ignore_user_permissions": 1,
|
||||||
@ -234,12 +239,9 @@
|
|||||||
{
|
{
|
||||||
"fieldname": "company",
|
"fieldname": "company",
|
||||||
"fieldtype": "Link",
|
"fieldtype": "Link",
|
||||||
"hidden": 1,
|
|
||||||
"label": "Company",
|
"label": "Company",
|
||||||
"no_copy": 1,
|
"no_copy": 1,
|
||||||
"options": "Company",
|
"options": "Company"
|
||||||
"print_hide": 1,
|
|
||||||
"report_hide": 1
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"collapsible": 1,
|
"collapsible": 1,
|
||||||
@ -282,10 +284,25 @@
|
|||||||
"label": "Series",
|
"label": "Series",
|
||||||
"options": "HLC-APP-.YYYY.-",
|
"options": "HLC-APP-.YYYY.-",
|
||||||
"set_only_once": 1
|
"set_only_once": 1
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "section_break_11",
|
||||||
|
"fieldtype": "Section Break"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "column_break_13",
|
||||||
|
"fieldtype": "Column Break"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "billing_item",
|
||||||
|
"fieldtype": "Link",
|
||||||
|
"label": "Billing Item",
|
||||||
|
"options": "Item",
|
||||||
|
"read_only": 1
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"links": [],
|
"links": [],
|
||||||
"modified": "2020-03-27 11:27:33.773195",
|
"modified": "2020-04-07 11:16:34.981240",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "Healthcare",
|
"module": "Healthcare",
|
||||||
"name": "Patient Appointment",
|
"name": "Patient Appointment",
|
||||||
|
@ -340,7 +340,8 @@ def make_encounter(source_name, target_doc=None):
|
|||||||
['medical_department', 'department'],
|
['medical_department', 'department'],
|
||||||
['patient_sex', 'patient_sex'],
|
['patient_sex', 'patient_sex'],
|
||||||
['encounter_date', 'appointment_date'],
|
['encounter_date', 'appointment_date'],
|
||||||
['invoiced', 'invoiced']
|
['invoiced', 'invoiced'],
|
||||||
|
['company', 'company']
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}, target_doc)
|
}, target_doc)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user