From 17f20d5d2ed2e1568a2a74f03b14966e28b7fa03 Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Sat, 14 Nov 2020 00:58:43 +0000 Subject: [PATCH] --- ayanova/devdocs/todo.txt | 8 +++ ayanova/src/api/gzform.js | 4 +- ayanova/src/components/pick-list.vue | 8 +-- ayanova/src/views/cust-customer.vue | 62 ++++++++++++++++++++++++ ayanova/src/views/home-user-settings.vue | 3 +- 5 files changed, 78 insertions(+), 7 deletions(-) diff --git a/ayanova/devdocs/todo.txt b/ayanova/devdocs/todo.txt index e420741f..a69e99ff 100644 --- a/ayanova/devdocs/todo.txt +++ b/ayanova/devdocs/todo.txt @@ -5,6 +5,14 @@ todo: SEEDER Seed sample customers from v7 specifically in addition to random ones? +todo: picklist empty null vs zero + test with customer and headofficeid + should have the empty selection pre-selected or maybe I need to do away with that since the clear button does the same thing? + + +todo: picklist clear doesn't trigger dirty change + maybe doesn't emit? + todo: Uifielddatatype Phone and TimeSpan support at client, translation keys etc ay-customize.vue gz-data-table.vue diff --git a/ayanova/src/api/gzform.js b/ayanova/src/api/gzform.js index dd780ea8..fbd76751 100644 --- a/ayanova/src/api/gzform.js +++ b/ayanova/src/api/gzform.js @@ -979,11 +979,11 @@ export default { // Used by forms that need the option of an unselected // item in a pick list // - addNoSelectionItem(listArray) { + addNoSelectionItem(listArray, nullNotZero) { if (listArray == undefined || listArray == null) { listArray = []; } - listArray.unshift({ name: "-", id: 0 }); + listArray.unshift({ name: "-", id: nullNotZero ? null : 0 }); }, //////////////////////////////////// // Get validity of referenced control diff --git a/ayanova/src/components/pick-list.vue b/ayanova/src/components/pick-list.vue index ba313198..d442013f 100644 --- a/ayanova/src/components/pick-list.vue +++ b/ayanova/src/components/pick-list.vue @@ -143,7 +143,7 @@ export default { if (!this.showEditIcon) { return null; } - if (this.value != 0) { + if (this.value != null) { return "$ayiEdit"; } return "$ayiPlus"; @@ -185,8 +185,8 @@ export default { } } //is it the no selection item? - if (val == 0) { - window.$gz.form.addNoSelectionItem(vm.searchResults); + if (val == null) { + window.$gz.form.addNoSelectionItem(vm.searchResults, true); } else { //Not here, better get it let urlParams = "?ayaType=" + vm.ayaType + "&preId=" + vm.value; @@ -274,7 +274,7 @@ export default { throw new Error(res); } vm.searchResults = res.data; - window.$gz.form.addNoSelectionItem(vm.searchResults); + window.$gz.form.addNoSelectionItem(vm.searchResults, true); vm.replaceLastSelection(); } catch (err) { window.$gz.errorHandler.handleFormError(err); diff --git a/ayanova/src/views/cust-customer.vue b/ayanova/src/views/cust-customer.vue index 58e9d34b..fd29c013 100644 --- a/ayanova/src/views/cust-customer.vue +++ b/ayanova/src/views/cust-customer.vue @@ -415,6 +415,68 @@ > + + + + + + + + + + + + + http://maps.apple.com/?ll={aylatitude},{aylongitude}" + value: + "http://maps.apple.com/?q={ayaddress}<|>http://maps.apple.com/?ll={aylatitude},{aylongitude}" }, { name: "Bing",