diff --git a/src/modules/02_organizationalNew/components/listView.vue b/src/modules/02_organizationalNew/components/listView.vue index be42f4ada..0b6cedcde 100644 --- a/src/modules/02_organizationalNew/components/listView.vue +++ b/src/modules/02_organizationalNew/components/listView.vue @@ -120,6 +120,12 @@ async function fetchDataTable(id: string, level: number, action: boolean) { }); } +async function filterKeyword() { + reqMaster.page = 1; + action1.value === false && + fetchDataTable(reqMaster.id, reqMaster.type, false); +} + /**lifecycle Hook*/ onMounted(async () => { const id = @@ -197,6 +203,7 @@ watch( v-model:reqMaster="reqMaster" v-model:totalPage="totalPage" v-model:posMaster="posMaster" + :filterKeyword="filterKeyword" /> diff --git a/src/modules/02_organizationalNew/components/tableTree.vue b/src/modules/02_organizationalNew/components/tableTree.vue index cbc6151e1..640a68b49 100644 --- a/src/modules/02_organizationalNew/components/tableTree.vue +++ b/src/modules/02_organizationalNew/components/tableTree.vue @@ -17,6 +17,10 @@ import DialogSort from "@/modules/02_organizationalNew/components/DialogSortPosi /** importStore*/ import { useOrganizational } from "@/modules/02_organizationalNew/store/organizational"; +const props = defineProps({ + filterKeyword: { type: Function, require: true, default: () => {} }, +}); + const dataSort = ref>([]); const modalSort = ref(false); const showAllData = ref(false); @@ -188,22 +192,6 @@ const columnsExpand = ref([ style: "font-size: 14px", }, ]); -const rows = ref([ - { - noPosition: "สกง.1", - namePosition: "นักทรัพยากรบุคคล", - typePosition: "ทั่วไป", - levelPositoion: "ชำนาญการ / ?", - isStatus: "ไม่มี", - }, - { - noPosition: "สกง.2", - namePosition: "นักทรัพยากรบุคคล", - typePosition: "ทั่วไป", - levelPositoion: "ชำนาญการ / ?", - isStatus: "ไม่มี", - }, -]); const dialogPosition = ref(false); function onClickPosition(type: string) { @@ -281,7 +269,15 @@ function updatePagination(newPagination: NewPagination) { > -
+
+ +
@@ -298,7 +294,6 @@ function updatePagination(newPagination: NewPagination) { :paging="true" dense :rows-per-page-options="[10, 25, 50, 100]" - :filter="filter" @update:pagination="updatePagination" >