diff --git a/src/modules/02_organization/components/StructureMain.vue b/src/modules/02_organization/components/StructureMain.vue index d221ef2d5..375cc20ac 100644 --- a/src/modules/02_organization/components/StructureMain.vue +++ b/src/modules/02_organization/components/StructureMain.vue @@ -46,8 +46,6 @@ async function fetchStructChart( type: string, status: boolean = false ) { - console.log(status); - showLoader(); await http .get(config.API.orgStructChart(id, type)) @@ -70,58 +68,11 @@ async function fetchStructChart( }); } -/** - * อ่าน Root ของข้อมูลทั้งหมดจาก ​​API ต้องทำเป็นอันดับแรก เพื่อจะได้รู้รากของข้อมูล - */ -// const fetchTreeRoot = async () => { -// showLoader(); -// let urlRequest = config.API.chartGetTreeRoot; -// await http -// .get(urlRequest) -// .then((response) => { -// if (response.data.result.length > 0) { -// rootOrgID.value = response.data.result[0].organizationId; -// } -// }) -// .catch((e) => { -// messageError($q, e); -// }) -// .finally(() => { -// hideLoader(); -// }); -// }; - -/** - * อ่านข้อมูล organization id ปัจจุบันจาก API ข้อมูลที่ได้เอามาสร้าง Structure Chart - */ -// const fetchStructChart = async () => { -// showLoader(); -// let urlRequest = config.API.chartGetStructure(rootOrgID.value); -// await http -// .get(urlRequest) -// .then((response) => { -// if (response.data.result.length > 0) { -// dataSource.value = response.data.result[0]; -// if (dataSourceLock.value === undefined) -// dataSourceLock.value = dataSource.value; -// breadcrumbsGen(); -// } -// }) -// .catch((e) => { -// messageError($q, e); -// }) -// .finally(() => { -// hideLoader(); -// }); -// }; - /** * เมื่อมีการคลิกที่ Chart ให้อ่าน ID ของหน่วยงานที่ถูกคลิก แล้วดึงข้อมูล Chart ของหน่วยงานนั้น ๆ จาก API * @param data */ const refreshChart = async (data: any, type: number) => { - console.log(data, type); - if (data.value === undefined) { fetchStructChart(data, type.toString()); rootOrgID.value = data; diff --git a/src/modules/02_organization/components/StructureOrgMain.vue b/src/modules/02_organization/components/StructureOrgMain.vue new file mode 100644 index 000000000..9b6a7245f --- /dev/null +++ b/src/modules/02_organization/components/StructureOrgMain.vue @@ -0,0 +1,148 @@ + + + + + diff --git a/src/modules/02_organization/views/main.vue b/src/modules/02_organization/views/main.vue index 1824a137d..40056bae8 100644 --- a/src/modules/02_organization/views/main.vue +++ b/src/modules/02_organization/views/main.vue @@ -16,6 +16,7 @@ import type { OrgRevision } from "@/modules/02_organization/interface/response/o */ import TreeView from "@/modules/02_organization/components/TreeView.vue"; import StructureView from "@/modules/02_organization/components/StructureMain.vue"; +import StructureOrgMain from "@/modules/02_organization/components/StructureOrgMain.vue"; import DialogFormNewStructure from "@/modules/02_organization/components/DialogNewStructure.vue"; import DialogDateTime from "@/modules/02_organization/components/DialogFormDateTime.vue"; @@ -323,6 +324,14 @@ onMounted(async () => { :color="store.statusView === 'tree' ? 'grey-7' : 'grey-4'" @click="store.statusView = 'tree'" /> + + @@ -339,6 +348,10 @@ onMounted(async () => { + + + + diff --git a/src/modules/04_registryPerson/components/detail/Achievement/01_ProfessionalLicense.vue b/src/modules/04_registryPerson/components/detail/Achievement/01_ProfessionalLicense.vue index 2415d54ec..de3d93189 100644 --- a/src/modules/04_registryPerson/components/detail/Achievement/01_ProfessionalLicense.vue +++ b/src/modules/04_registryPerson/components/detail/Achievement/01_ProfessionalLicense.vue @@ -1,5 +1,5 @@