From b925badccc4e7386367b9c2e7cf72f0120c412a9 Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Wed, 29 Sep 2021 20:22:50 +0000 Subject: [PATCH] case 3987 --- ayanova/devdocs/todo.txt | 14 +++++++++++++- ayanova/src/App.vue | 18 +++++++++++------- ayanova/src/api/gzmenu.js | 17 +++++++++++------ 3 files changed, 35 insertions(+), 14 deletions(-) diff --git a/ayanova/devdocs/todo.txt b/ayanova/devdocs/todo.txt index c0d60611..20d96ee5 100644 --- a/ayanova/devdocs/todo.txt +++ b/ayanova/devdocs/todo.txt @@ -11,7 +11,14 @@ ## ROUGH SCHEDULE - testing cases?? + testing cases + - After a fix now main grid titles are all showing as ??Parts etc, fuck is up with that?? + the fix for the edit form is fighting with the list form + - grid filter clicking on "delete" for whole filter should just save and close, right now it removes all filters but stays open and can't save so it's fucked + - Edge case but if filter is added while on last page of results and the filter means only one page returns the grid still stays on last page so it appears + as though the filter returned no results when in fact just on a non existant page number beyond the results pages returned. Possible fix is to reset to page zero if + user adds a filter condition or alternatively check if the current page is non zero then check if the current page is beyond the number of pages and if so reset to zero page + # Schedule form @@ -28,6 +35,9 @@ //.......... + cases to do + 3989 + 3991 Customer work order form / view / open??? @@ -788,5 +798,7 @@ MID CENTURY MODERN TUNES - https://www.allmusic.com/album/ultra-lounge-vol-14-bo BUILD 132 CHANGES OF NOTE - major refactor and cleanup of all client end source code +- case 3987 fixed +- case 3988 fixed diff --git a/ayanova/src/App.vue b/ayanova/src/App.vue index 5c05dabe..bb34b6de 100644 --- a/ayanova/src/App.vue +++ b/ayanova/src/App.vue @@ -364,13 +364,17 @@ export default { const t = this.appBar.title.split(":"); return t[1] + " " + this.$ay.t(t[0]); } - if (this.appBar.isMain) { - //if ismain then it's a translation key - return this.$ay.t(this.appBar.title); - } else { - //if not ismain then it's a record name - return this.appBar.title; - } + // if (this.appBar.isMain) { + // //if ismain then it's a translation key + // //return this.$ay.t(this.appBar.title); + // //update, no it's not, gzmenu now translatest it ahead of time so this has changed (build alpha 132) + // return this.appBar.title; + // } else { + // //if not ismain then it's a record name + // return this.appBar.title; + // } + //due to changes at gzmenu in build alpha 132 the remaining possiblities are all to just show the title as is no translation + return this.appBar.title; } }, props: { diff --git a/ayanova/src/api/gzmenu.js b/ayanova/src/api/gzmenu.js index a447504a..723a2768 100644 --- a/ayanova/src/api/gzmenu.js +++ b/ayanova/src/api/gzmenu.js @@ -55,21 +55,26 @@ export default { //ctx.title if set is a Translation key //ctx.formData.recordName is the object name or serial number or whatever identifies it uniquely let recordName = ""; - if (ctx && ctx.formData && ctx.formData.recordName) { + if ( + ctx && + ctx.formData && + ctx.formData.recordName && + ctx.formData.recordName != "null" //some forms (part) present "null" as the record name due to attempts to format a name so if that's the case just turn it into null here to bypass + ) { recordName = ctx.formData.recordName; } - const hasRecordName = recordName != ""; + const hasRecordName = !window.$gz.util.stringIsNullOrEmpty(recordName); if (ctx.title) { //it has a title translation key + const translatedTitle = vm.$ay.t(ctx.title); if (hasRecordName) { //recordname takes all precedence in AppBar in order to conserve space (narrow view etc) //also it just looks cleaner, the icon is already there to indicate where the user is at - //vm.appBar.title = `${ctx.title}:${recordName}`; vm.appBar.title = recordName; - document.title = `${recordName} - ${vm.$ay.t(ctx.title)} AyaNova `; + document.title = `${recordName} - ${translatedTitle} AyaNova `; } else { - vm.appBar.title = ctx.title; - document.title = `${vm.$ay.t(ctx.title)} ${recordName}`; + vm.appBar.title = translatedTitle; + document.title = `${translatedTitle} ${recordName}`; } } else { if (hasRecordName) {