This commit is contained in:
@@ -157,6 +157,7 @@ export default {
|
|||||||
"Open",
|
"Open",
|
||||||
"Print",
|
"Print",
|
||||||
"Report",
|
"Report",
|
||||||
|
"Refresh",
|
||||||
"WikiPage",
|
"WikiPage",
|
||||||
"Duplicate",
|
"Duplicate",
|
||||||
"RecordHistory",
|
"RecordHistory",
|
||||||
|
|||||||
@@ -188,6 +188,14 @@ export default {
|
|||||||
valid: true,
|
valid: true,
|
||||||
loading: false
|
loading: false
|
||||||
});
|
});
|
||||||
|
|
||||||
|
//Check the new count and update accordingly
|
||||||
|
//this is to ensure that when a user is viewing the latest notifications they don't see the NEW count still in the bell icon in menu since they are viewing them live
|
||||||
|
let status = await window.$gz.api.get("notify/new-count");
|
||||||
|
if (status.error) {
|
||||||
|
throw status.error;
|
||||||
|
}
|
||||||
|
window.$gz.store.commit("setNewNotificationCount", status.data);
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
window.$gz.errorHandler.handleFormError(error, vm);
|
window.$gz.errorHandler.handleFormError(error, vm);
|
||||||
@@ -211,12 +219,9 @@ async function clickHandler(menuItem) {
|
|||||||
let m = window.$gz.menu.parseMenuItem(menuItem);
|
let m = window.$gz.menu.parseMenuItem(menuItem);
|
||||||
if (m.owner == FORM_KEY && !m.disabled) {
|
if (m.owner == FORM_KEY && !m.disabled) {
|
||||||
switch (m.key) {
|
switch (m.key) {
|
||||||
// case "new":
|
case "refresh":
|
||||||
// m.vm.$router.push({
|
await m.vm.getDataFromApi();
|
||||||
// name: "home-notify-subscription",
|
break;
|
||||||
// params: { recordid: 0 }
|
|
||||||
// });
|
|
||||||
// break;
|
|
||||||
// case "extensions":
|
// case "extensions":
|
||||||
// let res = await m.vm.$refs.extensions.open();
|
// let res = await m.vm.$refs.extensions.open();
|
||||||
// break;
|
// break;
|
||||||
@@ -242,15 +247,13 @@ function generateMenu(vm) {
|
|||||||
menuItems: []
|
menuItems: []
|
||||||
};
|
};
|
||||||
|
|
||||||
// if (vm.rights.change) {
|
menuOptions.menuItems.push({
|
||||||
// menuOptions.menuItems.push({
|
title: "Refresh",
|
||||||
// title: "New",
|
icon: "fa-sync",
|
||||||
// icon: "fa-plus",
|
surface: true,
|
||||||
// surface: true,
|
key: FORM_KEY + ":refresh",
|
||||||
// key: FORM_KEY + ":new",
|
vm: vm
|
||||||
// vm: vm
|
});
|
||||||
// });
|
|
||||||
// }
|
|
||||||
|
|
||||||
// //STUB REPORTS
|
// //STUB REPORTS
|
||||||
// //Report not Print, print is a further option
|
// //Report not Print, print is a further option
|
||||||
|
|||||||
Reference in New Issue
Block a user