From f18d34b02db7bba8eaab7a5c72b04cf07933ab81 Mon Sep 17 00:00:00 2001 From: puriphatt Date: Mon, 10 Feb 2025 09:43:46 +0700 Subject: [PATCH 01/40] fix: add validation rules for group selection in FormBasicInfoAgencies component --- src/components/07_agencies-management/FormBasicInfoAgencies.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/src/components/07_agencies-management/FormBasicInfoAgencies.vue b/src/components/07_agencies-management/FormBasicInfoAgencies.vue index 40b0ceb8..dbf9d568 100644 --- a/src/components/07_agencies-management/FormBasicInfoAgencies.vue +++ b/src/components/07_agencies-management/FormBasicInfoAgencies.vue @@ -46,6 +46,7 @@ type Options = { label: string; value: string }; (lhs: Options, rhs: Options) => lhs.value.localeCompare(rhs.value), ) " + :rules="[(val: string) => !!val || $t('form.error.required')]" v-model="group" > + +
@@ -606,7 +669,6 @@ watch( " /> @@ -649,6 +712,18 @@ watch(
+ + {{ @@ -677,7 +752,6 @@ watch( " /> @@ -814,6 +889,7 @@ watch( if (v) await submit({ selectedImage: v }); } " + @change-status="triggerChangeStatus" :readonly="!pageState.isDrawerEdit" :isEdit="pageState.isDrawerEdit" v-model="pageState.addModal" diff --git a/src/stores/institution/index.ts b/src/stores/institution/index.ts index 930ebda2..c639f708 100644 --- a/src/stores/institution/index.ts +++ b/src/stores/institution/index.ts @@ -40,7 +40,7 @@ export const useInstitution = defineStore('institution-store', () => { params, }, ) - : await api.get>(`/institution`, { + : await api.get>('/institution', { params, }); @@ -80,6 +80,7 @@ export const useInstitution = defineStore('institution-store', () => { const res = await api.put(`/institution/${data.id}`, { ...data, id: undefined, + group: undefined, }); if (res.status < 400) { return res.data; From 51313cc4f88f353b9dcd6388eeee33f65a3c3fc5 Mon Sep 17 00:00:00 2001 From: puriphatt Date: Mon, 10 Feb 2025 13:05:15 +0700 Subject: [PATCH 03/40] feat: add status filtering to agencies management page --- src/pages/07_agencies-management/MainPage.vue | 32 ++++++++++++++++--- src/stores/institution/index.ts | 2 ++ 2 files changed, 30 insertions(+), 4 deletions(-) diff --git a/src/pages/07_agencies-management/MainPage.vue b/src/pages/07_agencies-management/MainPage.vue index 1a4feaac..04decf0b 100644 --- a/src/pages/07_agencies-management/MainPage.vue +++ b/src/pages/07_agencies-management/MainPage.vue @@ -1,5 +1,5 @@ diff --git a/src/components/dialog/DialogProperties.vue b/src/components/dialog/DialogProperties.vue index 231937d0..d8b3b65e 100644 --- a/src/components/dialog/DialogProperties.vue +++ b/src/components/dialog/DialogProperties.vue @@ -365,6 +365,8 @@ watch( {{ $t('flow.stepNo', { msg: (props.stepIndex || stepIndex) + 1 }) }} : {{ step.name }} pageState.inputSearch, workflowPageSize], () => { pageState.inputSearch, workflowPageSize], () => { " /> -->