Merge pull request #7617 from deepeshgarg007/report-print-fix
fix: Query report print fix
This commit is contained in:
commit
2f43a76a0a
1 changed files with 6 additions and 0 deletions
|
|
@ -347,6 +347,7 @@ frappe.views.QueryReport = class QueryReport extends frappe.views.BaseList {
|
|||
|
||||
this.render_datatable();
|
||||
} else {
|
||||
this.data = [];
|
||||
this.toggle_nothing_to_show(true);
|
||||
}
|
||||
|
||||
|
|
@ -925,6 +926,11 @@ frappe.views.QueryReport = class QueryReport extends frappe.views.BaseList {
|
|||
}
|
||||
|
||||
get_data_for_print() {
|
||||
|
||||
if (!this.data.length) {
|
||||
return [];
|
||||
}
|
||||
|
||||
const rows = this.datatable.datamanager.rowViewOrder.map(index => {
|
||||
if (this.datatable.bodyRenderer.visibleRowIndices.includes(index)) {
|
||||
return this.data[index];
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue