Added missing view on map menu item

This commit is contained in:
2022-01-18 22:50:31 +00:00
parent 55c90efe60
commit c8cd316068
4 changed files with 55 additions and 1 deletions

View File

@@ -1350,4 +1350,7 @@ BUILD 8.0.0-beta.0.12 CHANGES OF NOTE
- Changes to authorization roles for Sales, Tech, Tech - restricted, Subcontractor and Subcontractor restricted decreasing in all cases how much they have access to in AyaNova
- Reordered the login form sample users list to be in alphabetical order to match full name changes to roles from earlier
- renamed "select lists" to "autocomplete lists" in docs and in UI (english), select lists now refer to selects that are not searchable, autocomplete is every searchable list for selectingan ayanova object
- Added missing "View on map" menu option to work orders, pm and quote
- TODO: 1 before this release handlebars utilities add to report edit functions https://handlebarsjs.com/api-reference/utilities.html

View File

@@ -1721,7 +1721,17 @@ async function clickHandler(menuItem) {
name: "svc-task-groups"
});
break;
case "geoview":
window.$gz.util.viewGeoLocation({
latitude: m.vm.obj.latitude,
longitude: m.vm.obj.longitude,
address: m.vm.obj.address || m.vm.obj.postAddress,
city: m.vm.obj.city || m.vm.obj.postCity,
region: m.vm.obj.region || m.vm.obj.postRegion,
country: m.vm.obj.country || m.vm.obj.postCountry,
postCode: m.vm.obj.postCode
});
break;
default:
window.$gz.eventBus.$emit(
"notify-warning",
@@ -1865,6 +1875,12 @@ function generateMenu(vm) {
vm: vm
});
}
menuOptions.menuItems.push({
title: "GeoView",
icon: "$ayiMapMarked",
key: FORM_KEY + ":geoview",
vm: vm
});
menuOptions.menuItems.push({ divider: true, inset: false });
window.$gz.eventBus.$emit("menu-change", menuOptions);

View File

@@ -1792,6 +1792,17 @@ async function clickHandler(menuItem) {
id: m.vm.obj.fromCSRId
});
break;
case "geoview":
window.$gz.util.viewGeoLocation({
latitude: m.vm.obj.latitude,
longitude: m.vm.obj.longitude,
address: m.vm.obj.address || m.vm.obj.postAddress,
city: m.vm.obj.city || m.vm.obj.postCity,
region: m.vm.obj.region || m.vm.obj.postRegion,
country: m.vm.obj.country || m.vm.obj.postCountry,
postCode: m.vm.obj.postCode
});
break;
default:
window.$gz.eventBus.$emit(
"notify-warning",
@@ -1939,6 +1950,12 @@ function generateMenu(vm) {
vm: vm
});
}
menuOptions.menuItems.push({
title: "GeoView",
icon: "$ayiMapMarked",
key: FORM_KEY + ":geoview",
vm: vm
});
menuOptions.menuItems.push({ divider: true, inset: false });
window.$gz.eventBus.$emit("menu-change", menuOptions);

View File

@@ -1955,6 +1955,17 @@ async function clickHandler(menuItem) {
id: m.vm.obj.fromPMId
});
break;
case "geoview":
window.$gz.util.viewGeoLocation({
latitude: m.vm.obj.latitude,
longitude: m.vm.obj.longitude,
address: m.vm.obj.address || m.vm.obj.postAddress,
city: m.vm.obj.city || m.vm.obj.postCity,
region: m.vm.obj.region || m.vm.obj.postRegion,
country: m.vm.obj.country || m.vm.obj.postCountry,
postCode: m.vm.obj.postCode
});
break;
default:
window.$gz.eventBus.$emit(
"notify-warning",
@@ -2105,6 +2116,13 @@ function generateMenu(vm) {
vm: vm
});
}
menuOptions.menuItems.push({
title: "GeoView",
icon: "$ayiMapMarked",
key: FORM_KEY + ":geoview",
vm: vm
});
menuOptions.menuItems.push({ divider: true, inset: false });
let hasFromInsertDivider = false;