diff --git a/frappe/desk/doctype/dashboard_chart/dashboard_chart.json b/frappe/desk/doctype/dashboard_chart/dashboard_chart.json index a5aa6cc20a4e..d50f58c9aff8 100644 --- a/frappe/desk/doctype/dashboard_chart/dashboard_chart.json +++ b/frappe/desk/doctype/dashboard_chart/dashboard_chart.json @@ -287,7 +287,7 @@ } ], "links": [], - "modified": "2022-07-27 11:09:09.203236", + "modified": "2023-08-14 16:33:30.172798", "modified_by": "Administrator", "module": "Desk", "name": "Dashboard Chart", @@ -319,7 +319,6 @@ "write": 1 }, { - "create": 1, "email": 1, "export": 1, "print": 1, diff --git a/frappe/public/js/frappe/views/reports/query_report.js b/frappe/public/js/frappe/views/reports/query_report.js index e695bc5c183f..81a4c0207c53 100644 --- a/frappe/public/js/frappe/views/reports/query_report.js +++ b/frappe/public/js/frappe/views/reports/query_report.js @@ -175,12 +175,14 @@ frappe.views.QueryReport = class QueryReport extends frappe.views.BaseList { } add_card_button_to_toolbar() { + if (!frappe.model.can_create("Number Card")) return; this.page.add_inner_button(__("Create Card"), () => { this.add_card_to_dashboard(); }); } add_chart_buttons_to_toolbar(show) { + if (!frappe.model.can_create("Dashboard Chart")) return; if (show) { this.create_chart_button && this.create_chart_button.remove(); this.create_chart_button = this.page.add_button(__("Set Chart"), () => {