fix(03): br id select
This commit is contained in:
parent
c6f2dc216d
commit
75a8e43a22
2 changed files with 21 additions and 13 deletions
|
|
@ -1,8 +1,9 @@
|
|||
<script setup lang="ts">
|
||||
import { QSelect } from 'quasar';
|
||||
import { getRole } from 'src/services/keycloak';
|
||||
import { CustomerBranch } from 'src/stores/customer/types';
|
||||
import { selectFilterOptionRefMod } from 'src/stores/utils';
|
||||
import { ref } from 'vue';
|
||||
import { onMounted, ref, watch } from 'vue';
|
||||
|
||||
const personName = defineModel<string>('personName');
|
||||
const customerName = defineModel<string>('customerName');
|
||||
|
|
@ -16,6 +17,7 @@ const taxNo = defineModel<string | null | undefined>('taxNo');
|
|||
|
||||
const employerID = defineModel<string>('employerID');
|
||||
const slash = ref<string>('-');
|
||||
|
||||
// employee
|
||||
const customerBranch = defineModel<{
|
||||
id: string;
|
||||
|
|
@ -44,12 +46,22 @@ defineEmits<{
|
|||
(e: 'filterOwnerBranch', val: string, update: void): void;
|
||||
}>();
|
||||
|
||||
const branchOptions = ref<Record<string, unknown>[]>([]);
|
||||
const branchFilter = selectFilterOptionRefMod(
|
||||
optionsBranch,
|
||||
branchOptions,
|
||||
'name',
|
||||
watch(
|
||||
() => optionsBranch.value,
|
||||
() => {
|
||||
branchFilter = selectFilterOptionRefMod(
|
||||
optionsBranch,
|
||||
branchOptions,
|
||||
'name',
|
||||
);
|
||||
},
|
||||
);
|
||||
|
||||
const branchOptions = ref<Record<string, unknown>[]>([]);
|
||||
let branchFilter: (
|
||||
value: string,
|
||||
update: (callbackFn: () => void, afterFn?: (ref: QSelect) => void) => void,
|
||||
) => void;
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue