2
0
mirror of https://github.com/frappe/books.git synced 2024-11-08 23:00:56 +00:00

chore: update toast calls, remove window.showToast

This commit is contained in:
18alantom 2022-01-19 15:51:51 +05:30 committed by Alan
parent 2508993d47
commit 039e371f6b
2 changed files with 3 additions and 2 deletions

View File

@ -114,8 +114,9 @@ export default {
methods: {
showReloadToast() {
showToast({
message: _('Changes will be visible on reload'),
message: _('Changes require reload'),
actionText: frappe._('Reload'),
type: 'info',
action: async () => {
frappe.events.trigger('reload-main-window');
},

View File

@ -181,6 +181,7 @@ export function showExportInFolder(message, filePath) {
showToast({
message,
actionText: frappe._('Open Folder'),
type: 'success',
action: async () => {
await showItemInFolder(filePath);
},
@ -342,7 +343,6 @@ export function showToast(props) {
},
});
}
window.showToast = showToast;
export function titleCase(phrase) {
return phrase