Actually call API

This commit is contained in:
2022-02-04 21:43:51 +00:00
parent 3d1d1308ac
commit 2204188600
2 changed files with 21 additions and 7 deletions

View File

@ -1,7 +1,7 @@
<script lang="ts">
import { defineComponent, PropType } from "vue"
interface Suggestion {
export interface Suggestion {
ID : string
Name : string
}
@ -34,7 +34,7 @@ export default defineComponent({
e.preventDefault();
},
load(text : String) {
this.$emit('update:modelValue', {ID: "", Name: text});
this.$emit('update:modelValue', {ID: null, Name: text});
if (text == ""){
this.$data.Suggestions = [];
return;
@ -64,7 +64,7 @@ export default defineComponent({
},
clear() {
this.$data.Selected = undefined;
this.$emit('update:modelValue', {ID: "", Name: this.$data.SearchQuery});
this.$emit('update:modelValue', {ID: null, Name: this.$data.SearchQuery});
}
}
})