From 5524320b7e432d6a1c2085864191987a04848fca Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Tue, 7 Sep 2021 17:56:12 +0000 Subject: [PATCH] --- ayanova/devdocs/todo.txt | 15 ++------------- ayanova/src/components/data-table.vue | 13 ++++++++----- 2 files changed, 10 insertions(+), 18 deletions(-) diff --git a/ayanova/devdocs/todo.txt b/ayanova/devdocs/todo.txt index 1ced0b0d..aa408c76 100644 --- a/ayanova/devdocs/todo.txt +++ b/ayanova/devdocs/todo.txt @@ -62,18 +62,6 @@ Coded by importance ## CLIENT MISC ITEMS - -todo:1 grid position not preserved when open a record then track back - i.e. go to last record in a multipage list, open something, go back and will see it's back to the start of the list losing the user's scroll position - this is very important that it work correctly - I *did* code this so it should actually be working, not sure why it isn't but the code is probably all there. - -todo: test bulk ops on wo/quote/pm tagging or something, had widget code in it that I just switched to wo/quote/pm - - - - - -2 hyperlinks in memos sb clickable to open in new tab or window or whatever this supports help links in migrate and also user links like "take a look at workorder 55" with a link to it in the UI recognize urls and make them actionable somehow @@ -766,4 +754,5 @@ BUILD 129 CHANGES OF NOTE - Fixed error when erase database then make PO or other default tax object got error due to server in memory global settings cache not clearing as well as db settings - Operations -> Backup form added ability to delete a backup file - Final de-widgetification, removed all remnants of the original widget test code from back and front end -- Fixed bug with bulk operations extension on Workorders / quotes / pm's that was preventing things like mass tagging workorders etc \ No newline at end of file +- Fixed bug with bulk operations extension on Workorders / quotes / pm's that was preventing things like mass tagging workorders etc +- Fixed bug where data table page setting was lost on opening a record then returning to the datatable \ No newline at end of file diff --git a/ayanova/src/components/data-table.vue b/ayanova/src/components/data-table.vue index 0591e755..eb4fe938 100644 --- a/ayanova/src/components/data-table.vue +++ b/ayanova/src/components/data-table.vue @@ -539,7 +539,7 @@ export default { dataTablePagingOptions: {}, lastDataTablePagingOptions: {}, activeFilterId: 0, //<--0 signifies to select default as it's uninitialized - lastFetchFilterId: 0, //used to track change of filter and reset paging in getdata + lastFetchFilterId: -1, //used to track change of filter and reset paging in getdata selectLists: { savedFilters: [] }, @@ -875,10 +875,16 @@ export default { }; //has filter changed? - if (vm.lastFetchFilterId != vm.activeFilterId) { + //-1 is the new form default + if ( + vm.lastFetchFilterId != -1 && + vm.lastFetchFilterId != vm.activeFilterId + ) { //yes, go back to page one vm.dataTablePagingOptions.page = 1; vm.lastFetchFilterId = vm.activeFilterId; + } else { + vm.lastFetchFilterId = vm.activeFilterId; } //calculate paging based on settings @@ -962,8 +968,6 @@ export default { //get pick lists let vm = this; await initForm(vm); - //rehydrate last form settings - //loadFormSettings(vm); vm.loading = false; vm.getDataFromApi(); } @@ -1039,7 +1043,6 @@ async function buildRecords(listData, columndefinitions, ridColumnOpenable) { if (column.rid) { o.id = column.i; } - //console.log("build records column: ", column); let dataType = columndefinitions[iColumn].dt; let display = column.v;