Cleaned up excessive logging at client, paring down to errors mostly and critical info
This commit is contained in:
@@ -11,16 +11,11 @@
|
||||
|
||||
## ROUGH SCHEDULE
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
todo: release then test sched from linux server just to ensure no unexpected issues. Test with ipad and table and phone as well.
|
||||
|
||||
# Schedule form
|
||||
|
||||
|
||||
todo: svc-schedule
|
||||
todo: svc-schedule once had time to test out personal schedule (give it a few days then move on to this)
|
||||
|
||||
CASES
|
||||
3766 - view schedule filtered by customer so can see at a glance all past and future for a single customer (more data table filter similarity)
|
||||
@@ -33,11 +28,11 @@ todo: release then test sched from linux server just to ensure no unexpected iss
|
||||
|
||||
//..........
|
||||
|
||||
workorderitempriority edit form missing NEW option, also probably woitemstatus and maybe wostatus too
|
||||
|
||||
|
||||
|
||||
Dashboard / widgets
|
||||
Just enough an no more, this could be endless, come up with a top 5 or something and limit it to that
|
||||
(this is also a very juicy v.next feature thing too)
|
||||
Installer INNO
|
||||
version with postgres included, version without postgres included
|
||||
quick trialers / beta testers will want a self contained test on windows scenario with built in pg until they get serious
|
||||
@@ -103,6 +98,8 @@ Coded by importance
|
||||
- 1 BUG BUG: attempt to delete a customer with a linked unit (so it can't be deleted) and get error properly but overlay stays on form
|
||||
whatever this is needs to be fixed everywhere
|
||||
|
||||
- 1 workorderitempriority edit form missing NEW option, also probably woitemstatus and maybe wostatus too
|
||||
|
||||
- 1 potential serious bug need to test to confirm it's ok:
|
||||
Test input and display when forced time zone to alternate:
|
||||
Good test time zones:
|
||||
@@ -113,8 +110,6 @@ Coded by importance
|
||||
In particular also, need to confirm DST boundary still works as expected even when in alternate time zone
|
||||
Also confirm when not overriding time zone the DST boundary thing
|
||||
|
||||
- 1 If the client has not overriden their browser time zone then there is really no need to go through the hoops to convert it
|
||||
i.e. it should all just work without any conversion, wouldn't that be faster??
|
||||
|
||||
- 1 Reminder form dates don't have start before end rule applied??
|
||||
- 1 reminder list default template has stop before start left to right backwards
|
||||
|
||||
@@ -285,25 +285,6 @@ export default {
|
||||
});
|
||||
}
|
||||
|
||||
//Removed this when I added the PWA update code because in reality it should not be required for
|
||||
//regular updates as it would be very intrusive, instead, on a new version it should internally fixup the
|
||||
//store if necessary
|
||||
|
||||
// //Detect version change, wipe persisted form settings if has changed.
|
||||
// let currentVersion = window.$gz.clientInfo.version;
|
||||
// if (currentVersion != window.$gz.store.state.lastClientVersion) {
|
||||
// window.$gz.store.commit(
|
||||
// "logItem",
|
||||
// "##### New version detected ##### cleared form settings cache (" +
|
||||
// window.$gz.store.state.lastClientVersion +
|
||||
// " -> " +
|
||||
// currentVersion +
|
||||
// ")"
|
||||
// );
|
||||
// window.$gz.store.commit("setLastClientVersion", currentVersion);
|
||||
// window.$gz.store.commit("clearAllFormSettings");
|
||||
// }
|
||||
|
||||
//////////////////////////////////
|
||||
// WIRE UP
|
||||
// EVENT HANDLERS ON GZEVENTBUS
|
||||
|
||||
@@ -59,11 +59,14 @@ export function processLogin(authResponse, loggedInWithKnownPassword) {
|
||||
tfaEnabled: authResponse.tfa,
|
||||
customerRights: authResponse.customerRights
|
||||
});
|
||||
//log the login
|
||||
window.$gz.store.commit(
|
||||
"logItem",
|
||||
"auth::processLogin -> User " + token.id + " logged in"
|
||||
);
|
||||
|
||||
//decided to remove this as it is not an out of the ordinary scenario to log
|
||||
// however left this block here in case in future becomes necessary for some common issue
|
||||
// //log the login
|
||||
// window.$gz.store.commit(
|
||||
// "logItem",
|
||||
// "auth::processLogin -> User " + token.id + " logged in"
|
||||
// );
|
||||
|
||||
//Get global settings
|
||||
let gsets = await window.$gz.api.get("global-biz-setting/client");
|
||||
@@ -71,10 +74,6 @@ export function processLogin(authResponse, loggedInWithKnownPassword) {
|
||||
//In a form this would trigger a bunch of validation or error display code but for here and now:
|
||||
//convert error to human readable string for display and popup a notification to user
|
||||
let msg = window.$gz.api.apiErrorToHumanString(gsets.error);
|
||||
window.$gz.store.commit(
|
||||
"logItem",
|
||||
"Initialize::() fetch global-biz-setting/client -> error" + msg
|
||||
);
|
||||
window.$gz.eventBus.$emit("notify-error", msg);
|
||||
} else {
|
||||
//Check if overrides and use them here
|
||||
@@ -95,12 +94,6 @@ export function processLogin(authResponse, loggedInWithKnownPassword) {
|
||||
|
||||
export function processLogout() {
|
||||
notifypoll.stopPolling();
|
||||
if (window.$gz.store.state.authenticated) {
|
||||
window.$gz.store.commit(
|
||||
"logItem",
|
||||
"auth::processLogout -> User logged out"
|
||||
);
|
||||
}
|
||||
window.$gz.store.commit("logout");
|
||||
sessionStorage.clear(); //clear all temporary session storage data
|
||||
}
|
||||
|
||||
@@ -32,7 +32,6 @@ function handleError(action, error, route) {
|
||||
//reaction to directly entered or opened link, not application logic driving it, so home is safest choice
|
||||
//
|
||||
if (error.message && error.message.includes("NotAuthorized")) {
|
||||
window.$gz.store.commit("logItem", "Not authorized, redirecting to HOME");
|
||||
window.$gz.eventBus.$emit(
|
||||
"notify-warning",
|
||||
window.$gz.translation.get("ErrorUserNotAuthorized")
|
||||
@@ -44,10 +43,6 @@ function handleError(action, error, route) {
|
||||
|
||||
//Handle 401 not authenticated
|
||||
if (error.message && error.message.includes("NotAuthenticated")) {
|
||||
window.$gz.store.commit(
|
||||
"logItem",
|
||||
"User is not authenticated, redirecting to LOGIN"
|
||||
);
|
||||
window.$gz.eventBus.$emit(
|
||||
"notify-error",
|
||||
window.$gz.translation.get("ErrorUserNotAuthenticated")
|
||||
@@ -66,7 +61,6 @@ function handleError(action, error, route) {
|
||||
error.message.includes("NetworkError") ||
|
||||
error.message.includes("Network request failed")
|
||||
) {
|
||||
window.$gz.store.commit("logItem", "Network error");
|
||||
let msg = "";
|
||||
|
||||
if (window.$gz.store.state.authenticated) {
|
||||
@@ -288,11 +282,6 @@ export default {
|
||||
) {
|
||||
window.$gz.store.commit("setAPIURL", "http://localhost:7575/api/v8.0/");
|
||||
window.$gz.store.commit("setHelpURL", "http://localhost:7575/docs/");
|
||||
window.$gz.store.commit(
|
||||
"logItem",
|
||||
"gzapi::APIUrl -> setting to dev. mode: " +
|
||||
window.$gz.store.state.apiUrl
|
||||
);
|
||||
} else {
|
||||
//production location <protocol>//<hostname>:<port>/
|
||||
window.$gz.store.commit(
|
||||
@@ -303,10 +292,6 @@ export default {
|
||||
"setAPIURL",
|
||||
window.location.protocol + "//" + window.location.host + "/api/v8.0/"
|
||||
);
|
||||
window.$gz.store.commit(
|
||||
"logItem",
|
||||
"gzapi::APIUrl -> setting to: " + window.$gz.store.state.apiUrl
|
||||
);
|
||||
}
|
||||
}
|
||||
return window.$gz.store.state.apiUrl + apiPath;
|
||||
|
||||
@@ -1074,7 +1074,6 @@ export default new Router({
|
||||
let msg = `/viewReport, query ${JSON.stringify(
|
||||
to.query
|
||||
)}, server error: ${JSON.stringify(res.error)}`;
|
||||
// window.$gz.store.commit("logItem", msg);
|
||||
window.$gz.eventBus.$emit("notify-error", msg);
|
||||
next("/applog");
|
||||
}
|
||||
|
||||
@@ -21,29 +21,6 @@ export default {
|
||||
async created() {
|
||||
await window.$gz.translation.cacheTranslations(["NoFeaturesAvailable"]);
|
||||
this.ready = true;
|
||||
// let badPath = this.$router.history.current.path;
|
||||
// //If this happens too early then it might not have all the setup stuff available which would trigger an infinite loop
|
||||
// if (
|
||||
// !window ||
|
||||
// !window.$gz ||
|
||||
// !window.$gz.eventBus ||
|
||||
// !window.$gz.translation ||
|
||||
// !window.$gz.store
|
||||
// ) {
|
||||
// this.msg = '404 - NOT FOUND: "' + badPath + '"';
|
||||
// } else {
|
||||
// let notFoundTranslated = this.$ay.t("ErrorAPI2010");
|
||||
// //format the message
|
||||
// this.msg = "404 - " + notFoundTranslated + ': "' + badPath + '"';
|
||||
// //log it in case we need to see it in tech support
|
||||
// window.$gz.store.commit("logItem", this.msg);
|
||||
// //set the title of the window
|
||||
// window.$gz.eventBus.$emit("menu-change", {
|
||||
// isMain: true,
|
||||
// icon: "$ayiDragon",
|
||||
// title: "404 - " + notFoundTranslated
|
||||
// });
|
||||
// }
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user