mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-17 17:26:43 +00:00
fix: Usability fixes in accountng dimensions
This commit is contained in:
@@ -41,10 +41,10 @@ frappe.ui.form.on('Accounting Dimension', {
|
||||
|
||||
document_type: function(frm) {
|
||||
frm.set_value('label', frm.doc.document_type);
|
||||
frm.set_value('fieldname', frappe.scrub(frm.doc.document_type));
|
||||
frm.set_value('fieldname', frappe.model.scrub(frm.doc.document_type));
|
||||
|
||||
frappe.db.get_value('Accounting Dimension', {'document_type': frm.doc.document_type}, 'document_type', (r) => {
|
||||
if (r.document_type) {
|
||||
if (r && r.document_type) {
|
||||
frm.set_df_property('document_type', 'description', "Document type is already set as dimension");
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user