Skip to content

Commit

Permalink
feat: disable change log
Browse files Browse the repository at this point in the history
(cherry picked from commit 63e2e32)
  • Loading branch information
hrwX authored and mergify[bot] committed May 10, 2022
1 parent 27a9d2d commit 1897af2
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
11 changes: 9 additions & 2 deletions frappe/core/doctype/system_settings/system_settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@
"column_break_64",
"max_auto_email_report_per_user",
"system_updates_section",
"disable_system_update_notification"
"disable_system_update_notification",
"disable_change_log_notification"
],
"fields": [
{
Expand Down Expand Up @@ -489,12 +490,18 @@
"fieldname": "max_auto_email_report_per_user",
"fieldtype": "Int",
"label": "Max auto email report per user"
},
{
"default": "0",
"fieldname": "disable_change_log_notification",
"fieldtype": "Check",
"label": "Disable Change Log Notification"
}
],
"icon": "fa fa-cog",
"issingle": 1,
"links": [],
"modified": "2022-04-21 09:11:35.218721",
"modified": "2022-04-28 14:31:50.330954",
"modified_by": "Administrator",
"module": "Core",
"name": "System Settings",
Expand Down
3 changes: 2 additions & 1 deletion frappe/public/js/frappe/desk.js
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,8 @@ frappe.Application = Class.extend({
// "version": "12.2.0"
// }];

if (!Array.isArray(change_log) || !change_log.length || window.Cypress) {
if (!Array.isArray(change_log) || !change_log.length ||
window.Cypress || cint(frappe.boot.sysdefaults.disable_change_log_notification)) {
return;
}

Expand Down

0 comments on commit 1897af2

Please sign in to comment.