fix(ux): add confirm before logout
This commit is contained in:
parent
407c1a9b2b
commit
b8549a53e5
2 changed files with 6 additions and 2 deletions
|
|
@ -486,7 +486,9 @@ class DesktopPage {
|
|||
icon: "log-out",
|
||||
label: "Logout",
|
||||
onClick: function () {
|
||||
frappe.app.logout();
|
||||
frappe.confirm(__("Are you sure you want to logout?"), () => {
|
||||
return frappe.app.logout();
|
||||
});
|
||||
},
|
||||
},
|
||||
];
|
||||
|
|
|
|||
|
|
@ -82,7 +82,9 @@ frappe.ui.SidebarHeader = class SidebarHeader {
|
|||
label: "Logout",
|
||||
icon: "logout",
|
||||
onClick: function () {
|
||||
return frappe.app.logout();
|
||||
frappe.confirm(__("Are you sure you want to logout?"), () => {
|
||||
return frappe.app.logout();
|
||||
});
|
||||
},
|
||||
}
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue