This commit is contained in:
2020-03-19 22:58:14 +00:00
parent f858036b00
commit d0b8a1beab

View File

@@ -10,7 +10,7 @@
item-disabled="!active"
:error-messages="errors"
:loading="searchUnderway"
:placeholder="lt('search hint here')"
:placeholder="lt('Search by text, ..tags or both')"
:search-input.sync="searchEntry"
auto-select-first
:multiple="multiple"
@@ -46,6 +46,7 @@ import _ from "../libs/lodash.min.js";
//todo test multiple selection
//todo: search only property that forces user to search vs just drop down and get default 100
//todo: append or use slot to put at end of drop down menu a "type to search for more" when the results are from an empty query only
//todo: translation keys when done
export default {
created() {
@@ -55,13 +56,14 @@ export default {
if (vm.preFill) {
vm.searchUnderway = true;
vm.getList();
} else {
if (vm.noSelectionValid) {
window.$gz.form.addNoSelectionItem(vm.searchResults);
if (vm.value == null) {
vm.value = 0;
}
}
}
// if (vm.noSelectionValid) {
// window.$gz.form.addNoSelectionItem(vm.searchResults);
// if (vm.value == null) {
// vm.value = 0;
// }
// }
},
beforeUpdate() {
//Set the initial list items based on the record items, this only needs to be called once at init