fix: Dimension filters in accounting reports
This commit is contained in:
parent
12b45b3f2a
commit
7b2d518059
@ -194,7 +194,11 @@ $.extend(erpnext.utils, {
|
|||||||
add_dimensions: function(report_name, index) {
|
add_dimensions: function(report_name, index) {
|
||||||
let filters = frappe.query_reports[report_name].filters;
|
let filters = frappe.query_reports[report_name].filters;
|
||||||
|
|
||||||
erpnext.dimension_filters.forEach((dimension) => {
|
frappe.call({
|
||||||
|
method: "erpnext.accounts.doctype.accounting_dimension.accounting_dimension.get_dimensions",
|
||||||
|
callback: function(r) {
|
||||||
|
let accounting_dimensions = r.message[0];
|
||||||
|
accounting_dimensions.forEach((dimension) => {
|
||||||
let found = filters.some(el => el.fieldname === dimension['fieldname']);
|
let found = filters.some(el => el.fieldname === dimension['fieldname']);
|
||||||
|
|
||||||
if (!found) {
|
if (!found) {
|
||||||
@ -206,6 +210,8 @@ $.extend(erpnext.utils, {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
make_subscription: function(doctype, docname) {
|
make_subscription: function(doctype, docname) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user