diff --git a/src/interface/request/main/main.ts b/src/interface/request/main/main.ts index 8b9fda266..1dc23be57 100644 --- a/src/interface/request/main/main.ts +++ b/src/interface/request/main/main.ts @@ -111,6 +111,22 @@ const menuList = readonly([ path: "registry", role: "registry", }, + { + key: 10, + icon: "o_contact_page", + activeIcon: "registry_employee_page", + label: "ทะเบียนประวัติลูกจ้าง", + path: "registry-employee", + role: "registryEmployee", + }, + { + key: 10, + icon: "o_list", + activeIcon: "order", + label: "ออกคำสั่ง", + path: "order", + role: "placement", + }, { key: 5, icon: "o_search", @@ -192,12 +208,12 @@ const menuList = readonly([ path: "placement", role: "placement", }, - { - key: 6.2, - label: "ออกคำสั่ง" /* ออกคำสั่งบรรจุ */, - path: "Orderplacement", - role: "placement", - }, + // { + // key: 6.2, + // label: "ออกคำสั่ง" /* ออกคำสั่งบรรจุ */, + // path: "Orderplacement", + // role: "placement", + // }, { key: 6.3, label: "การทดลองงาน" /* การทดลองงาน */, @@ -206,7 +222,7 @@ const menuList = readonly([ }, { key: 6.4, - label: "รายการคำขอโอน" /* */, + label: "รายการขอโอน" /* */, path: "transfer", role: "placement", }, @@ -218,13 +234,43 @@ const menuList = readonly([ }, { key: 6.6, - label: "คำสั่งช่วยราชการ/ส่งตัวกลับ" /* */, + label: "รายการช่วยราชการ" /* */, + // path: "help-government", path: "repatriation-order", role: "placement", }, + { + key: 6.7, + label: "รายการส่งตัวกลับ" /* */, + path: "repatriate", + role: "placement", + }, + { + key: 6.8, + label: "รายการแต่งตั้ง" /* */, + // path: "repatriate", + role: "placement", + }, + { + key: 6.9, + label: "รายการเลื่อน" /* */, + path: "postpone", + role: "placement", + }, + { + key: 6.1, + label: "รายการย้าย" /* */, + path: "move-order", + role: "placement", + }, + { + key: 6.1, + label: "รายการอื่นๆ" /* */, + path: "other-order", + role: "placement", + }, ], }, - { key: 7, icon: "mdi-account-cancel-outline", @@ -241,31 +287,43 @@ const menuList = readonly([ }, { key: 7.2, - label: "ลาออก", + label: "รายการลาออก", path: "resign", role: "retirement", }, + // { + // key: 7.3, + // label: "คำสั่งลาออก", + // path: "resign-order", + // role: "retirement", + // }, { key: 7.3, - label: "คำสั่งลาออก", - path: "resign-order", - role: "retirement", - }, - { - key: 7.4, label: "Exit interview", // path: "", role: "retirement", }, { - key: 7.5, - label: "ถึงแก่กรรม", + key: 7.4, + label: "รายการบันทึกการถึงแก่กรรม", path: "deceased", role: "retirement", }, + { + key: 7.5, + label: "รายการให้ออก", + path: "dismiss-order", + role: "retirement", + }, { key: 7.6, - label: "คำสั่งให้ออก ปลดออก ไล่ออก", + label: "รายการปลดออก", + path: "dismiss-order", + role: "retirement", + }, + { + key: 7.7, + label: "รายการไล่ออก", path: "dismiss-order", role: "retirement", }, @@ -363,14 +421,6 @@ const menuList = readonly([ }, ], }, - { - key: 10, - icon: "o_contact_page", - activeIcon: "contact_page", - label: "ทะเบียนประวัติลูกจ้าง", - path: "registryEmployee", - role: "registryEmployee", - }, ]); const tabList = readonly([ diff --git a/src/modules/04_registry/components/Profile.vue b/src/modules/04_registry/components/Profile.vue index db03c712a..ee54e19eb 100644 --- a/src/modules/04_registry/components/Profile.vue +++ b/src/modules/04_registry/components/Profile.vue @@ -154,33 +154,69 @@ - + + + + + ช่วยราชการ + + + + + + ส่งตัวกลับ + + + + + + แต่งตั้ง + + + + + + เลื่อน + + + + + + ย้าย + + ถึงแก่กรรม - + ให้ออกจากราชการ - + ปลดออกจากราชการ - + ไล่ออกจากราชการ + + + + อื่นๆ + + @@ -986,8 +1022,8 @@ const closeKp7Short = () => { dialogShort.value = false; }; -const clickaddOrder = () => { - router.push("/dismiss-order/add"); +const postAdd = () => { + // router.push("/dismiss-order/add"); }; const downloadKP7 = () => {}; diff --git a/src/modules/05_placement/components/PersonalList/Table.vue b/src/modules/05_placement/components/PersonalList/Table.vue index bb19d36fa..40c9ee9ec 100644 --- a/src/modules/05_placement/components/PersonalList/Table.vue +++ b/src/modules/05_placement/components/PersonalList/Table.vue @@ -1140,7 +1140,7 @@ const paginationLabel = (start: number, end: number, total: number) => { { { import("@/modules/05_placement/components/PersonalList/Detail.vue"); const PlacementPersonalDetail = () => import("@/modules/05_placement/components/PersonalDetail/Detail.vue"); -const addOrderPlacement = () => - import( - "@/modules/05_placement/components/OrderPlacement/addOrderPlacement.vue" - ); -const MainOrderPlacement = () => - import( - "@/modules/05_placement/components/OrderPlacement/MainOrderPlacement.vue" - ); -const detailOrderReplace = () => - import( - "@/modules/05_placement/components/OrderPlacement/detailOrderPlacement.vue" - ); // ระบบทดลองงาน const mainProbation = () => @@ -86,46 +74,6 @@ export default [ Role: "placement", }, }, - { - path: "/placement/order", - name: "Orderplacement", - component: MainOrderPlacement, - meta: { - Auth: true, - Key: [6.2], - Role: "placement", - }, - }, - { - path: "/placement/order/add", - name: "Orderplacementadd", - component: detailOrderReplace, - meta: { - Auth: true, - Key: [6.9], - Role: "placement", - }, - }, - { - path: "/placement/order/detail/:orderid", - name: "OrderplacementDetail", - component: detailOrderReplace, - meta: { - Auth: true, - Key: [6.2], - Role: "placement", - }, - }, - { - path: "/placement/addOrderPlacement", - name: "addOrderPlacement", - component: addOrderPlacement, - meta: { - Auth: true, - Key: [6.2], - Role: "placement", - }, - }, { path: "/probation", name: "probation", diff --git a/src/modules/08_registryEmployee/router.ts b/src/modules/08_registryEmployee/router.ts index 130b90438..49f48ff78 100644 --- a/src/modules/08_registryEmployee/router.ts +++ b/src/modules/08_registryEmployee/router.ts @@ -17,8 +17,8 @@ const EditDetail = defineAsyncComponent( export default [ { - path: "/registryEmployee", - name: "registryEmployee", + path: "/registry-employee", + name: "registry-employee", component: Main, meta: { Auth: true, @@ -37,7 +37,7 @@ export default [ // }, // }, { - path: "/registryEmployee/add", + path: "/registry-employee/add", name: "registryEmployeeAdd", component: Detail, meta: { @@ -47,7 +47,7 @@ export default [ }, }, { - path: "/registryEmployee/edit/:id", + path: "/registry-employee/edit/:id", name: "registryEmployeeEdit", component: EditDetail, meta: { diff --git a/src/modules/08_registryEmployee/views/Main.vue b/src/modules/08_registryEmployee/views/Main.vue index 36e9e8553..5e84ae330 100644 --- a/src/modules/08_registryEmployee/views/Main.vue +++ b/src/modules/08_registryEmployee/views/Main.vue @@ -1343,7 +1343,7 @@ const modalOpenClose = () => { }; const next = (id: string) => { - router.push(`/registryEmployee/${id}`); + router.push(`/registry-employee/${id}`); }; const resetFilter = () => { @@ -1381,13 +1381,13 @@ const clickClose = async () => { const clickAdd = () => { // modal.value = true; - router.push(`/registryEmployee/add`); + router.push(`/registry-employee/add`); // router.push(`/placement/detail`); }; // ดูรายการแก้ไขรายชื่อ const redirectToPage = (id?: string) => { - router.push(`/registryEmployee/edit/${id}`); + router.push(`/registry-employee/edit/${id}`); }; const editDetail = async (row: any) => { await getPosition(row.id); diff --git a/src/modules/08_registryEmployee/views/information.vue b/src/modules/08_registryEmployee/views/information.vue index 8a030d692..f27c210a9 100644 --- a/src/modules/08_registryEmployee/views/information.vue +++ b/src/modules/08_registryEmployee/views/information.vue @@ -1112,7 +1112,7 @@ const saveData = async () => { }; const clickBack = () => { - router.push({ name: "registryEmployee" }); + router.push("/registry-employee"); }; const getClass = (val: boolean) => { diff --git a/src/modules/05_placement/components/OrderPlacement/addOrderPlacement.vue b/src/modules/10_order/components/Add.vue similarity index 100% rename from src/modules/05_placement/components/OrderPlacement/addOrderPlacement.vue rename to src/modules/10_order/components/Add.vue diff --git a/src/modules/05_placement/components/OrderPlacement/detailOrderPlacement.vue b/src/modules/10_order/components/Detail.vue similarity index 88% rename from src/modules/05_placement/components/OrderPlacement/detailOrderPlacement.vue rename to src/modules/10_order/components/Detail.vue index 35f34e817..8a5c8b4db 100644 --- a/src/modules/05_placement/components/OrderPlacement/detailOrderPlacement.vue +++ b/src/modules/10_order/components/Detail.vue @@ -24,7 +24,6 @@ import { useRouter } from "vue-router"; import { ref, defineAsyncComponent, onMounted, onUnmounted } from "vue"; import type { QStepper } from "quasar"; -import { useProbationDataStore } from "@/modules/05_placement/store"; import { useRoute } from "vue-router"; import http from "@/plugins/http"; import config from "@/app.config"; @@ -32,24 +31,22 @@ const route = useRoute(); const orderId_params = route.params.orderid; -const probationData = useProbationDataStore(); -const { stepOrder, setStepOrder } = probationData; const step01 = defineAsyncComponent( () => - import("@/modules/05_placement/components/OrderPlacement/step/step01.vue") + import("@/modules/10_order/components/step/step01.vue") ); const step02 = defineAsyncComponent( () => - import("@/modules/05_placement/components/OrderPlacement/step/step02.vue") + import("@/modules/10_order/components/step/step02.vue") ); const step03 = defineAsyncComponent( () => - import("@/modules/05_placement/components/OrderPlacement/step/step03.vue") + import("@/modules/10_order/components/step/step03.vue") ); const step04 = defineAsyncComponent( () => - import("@/modules/05_placement/components/OrderPlacement/step/step04.vue") + import("@/modules/10_order/components/step/step04.vue") ); const router = useRouter(); diff --git a/src/modules/05_placement/components/OrderPlacement/MainOrderPlacement.vue b/src/modules/10_order/components/Main.vue similarity index 76% rename from src/modules/05_placement/components/OrderPlacement/MainOrderPlacement.vue rename to src/modules/10_order/components/Main.vue index ea400107e..f5ed2ae12 100644 --- a/src/modules/05_placement/components/OrderPlacement/MainOrderPlacement.vue +++ b/src/modules/10_order/components/Main.vue @@ -4,33 +4,12 @@
- +
- + เพิ่มข้อมูล + + + + + +
+
+ + + + +
+ +
+ + + + + +
+ + + + + + + + +
+
+
+
+ +
+ +
+ + +
+ +
+ + +
+
+
+
+
+ + + + + +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/modules/05_placement/components/OrderPlacement/step/step03.vue b/src/modules/10_order/components/step/step03.vue similarity index 100% rename from src/modules/05_placement/components/OrderPlacement/step/step03.vue rename to src/modules/10_order/components/step/step03.vue diff --git a/src/modules/05_placement/components/OrderPlacement/step/step04.vue b/src/modules/10_order/components/step/step04.vue similarity index 100% rename from src/modules/05_placement/components/OrderPlacement/step/step04.vue rename to src/modules/10_order/components/step/step04.vue diff --git a/src/modules/10_order/interface/index/Main.ts b/src/modules/10_order/interface/index/Main.ts new file mode 100644 index 000000000..45d341f54 --- /dev/null +++ b/src/modules/10_order/interface/index/Main.ts @@ -0,0 +1,218 @@ +interface DataOption { + id: number | null; + name: string; + disable?: boolean; +} +interface DataOption1 { + id: string | null; + name: string | null; + disable?: boolean; +} +interface DataOptionInsignia { + id: string; + name: string; + typeName: string; +} + +interface optionData { + id: string; + name: string; +} + +interface EduOps { + levelOptions: optionData[]; + positionPathOptions: optionData[]; +} + +interface InformationOps { + prefixOps: optionData[]; + genderOps: optionData[]; + bloodOps: optionData[]; + statusOps: optionData[]; + religionOps: optionData[]; + employeeClassOps: optionData[]; + employeeTypeOps: optionData[]; +} + +interface InsigniaOps { + insigniaOptions: DataOptionInsignia[]; +} + +interface Pagination { + rowsPerPage: number; +} + +interface treeTab { + id: string; + label: string; + children: treeTab[]; +} + +interface CheckboxItem { + id: number; + label: string; +} + +interface Property { + name: string; + value: boolean; +} + +interface PointExam { + pointA: number; + pointB: number; + pointC: number; + pointTotalA: number; + pointTotalB: number; + pointTotalC: number; + point: number; + pointTotal: number; + examNumber: number; + examRound: number; + pass: string | null; +} + +interface Education { + id: string; + educationLevel: string; + educationLevelId: string; + institute: string; + degree: string; + field: string; + gpa: string; + country: string; + duration: string; + other: string; + fundName: string; + durationYear: number; + finishDate: Date; + isDate: string; + startDate: Date; + endDate: Date; + positionPath: string; + isEducation: boolean; +} + +interface Family { + couple: string; + marryPrefix: string; + marryPrefixId: string; + marryFirstName: string; + marryLastName: string; + marryOccupation: string; + fatherPrefix: string; + fatherPrefixId: string; + fatherFirstName: string; + fatherLastName: string; + fatherOccupation: string; + motherPrefix: string; + motherPrefixId: string; + motherFirstName: string; + motherLastName: string; + motherOccupation: string; +} + +interface Address { + registAddress: string; + registSubDistrict: string; + registSubDistrictId: string; + registZipCode: string; + registDistrict: string; + registDistrictId: string; + registProvince: string; + registProvinceId: string; + currentAddress: string; + currentSubDistrict: string; + currentSubDistrictId: string; + currentZipCode: string; + currentDistrict: string; + currentDistrictId: string; + currentProvince: string; + currentProvinceId: string; + registSame: string; +} + +interface Certificate { + id: string; + certificateNo: string; + issuer: string; + issueDate: Date; + expireDate: Date; + certificateType: string; +} + +const AddressDataDefualt: Address = { + registAddress: "", + currentAddress: "", + registSubDistrict: "", + registSubDistrictId: "", + registZipCode: "", + registDistrict: "", + registDistrictId: "", + registProvince: "", + registProvinceId: "", + currentSubDistrict: "", + currentSubDistrictId: "", + currentZipCode: "", + currentDistrict: "", + currentDistrictId: "", + currentProvince: "", + currentProvinceId: "", + registSame: "0", +}; + +const FamilyDataDefualt: Family = { + couple: "0", + marryPrefix: "", + marryPrefixId: "", + marryFirstName: "", + marryLastName: "", + marryOccupation: "", + fatherPrefix: "", + fatherPrefixId: "", + fatherFirstName: "", + fatherLastName: "", + fatherOccupation: "", + motherPrefix: "", + motherPrefixId: "", + motherFirstName: "", + motherLastName: "", + motherOccupation: "", +}; +interface Assign { + id: number; + personal_id: string; + knowlage_skill_map_no: number; + round_no: number; + date_start: Date; + date_finish: Date; + behavior_desc: string; + other_desc: string; + other4_desc: string; + othor5_no1_desc: string; + othor5_no2_desc: string; + experimenter_dated: Date; + createdAt: Date; + updatedAt: Date; +} +export type { + DataOption, + DataOptionInsignia, + treeTab, + InformationOps, + Pagination, + EduOps, + DataOption1, + InsigniaOps, + CheckboxItem, + Property, + PointExam, + Education, + Family, + Address, + optionData, + Certificate, + Assign, +}; + +export { AddressDataDefualt, FamilyDataDefualt }; diff --git a/src/modules/10_order/interface/request/Main.ts b/src/modules/10_order/interface/request/Main.ts new file mode 100644 index 000000000..1cbcc63ba --- /dev/null +++ b/src/modules/10_order/interface/request/Main.ts @@ -0,0 +1,12 @@ +interface FormOrderPlacementMainData { + Order: string; + OrderNum: string; + fiscalYear: number; + OrderDate: string; + OrderBy: string; + Signer: string; + OrderStatus: string; + OrderType: string; +} + +export type { FormOrderPlacementMainData }; \ No newline at end of file diff --git a/src/modules/10_order/interface/request/Order.ts b/src/modules/10_order/interface/request/Order.ts new file mode 100644 index 000000000..d7e306c25 --- /dev/null +++ b/src/modules/10_order/interface/request/Order.ts @@ -0,0 +1,7 @@ +interface RequestCopyOrder { + personalId: string; + emailChannel: boolean; + inboxChannel: boolean; +} + +export type { RequestCopyOrder }; diff --git a/src/modules/10_order/interface/response/Main.ts b/src/modules/10_order/interface/response/Main.ts new file mode 100644 index 000000000..e4ea7770c --- /dev/null +++ b/src/modules/10_order/interface/response/Main.ts @@ -0,0 +1 @@ +export type {}; diff --git a/src/modules/10_order/interface/response/Order.ts b/src/modules/10_order/interface/response/Order.ts new file mode 100644 index 000000000..375361a97 --- /dev/null +++ b/src/modules/10_order/interface/response/Order.ts @@ -0,0 +1,44 @@ +interface ResponseData { + education: string; + idCard: string; + name: string; + personalId: string; + selectStatus: boolean; + sequence: number; + refRecordId: string +} + +interface ResponseOrganiz { + firstName: string; + idCard: string; + lastName: string; + name: string; + position: string; + prefixId: string; + profileId: string; + unit: string; +} + +interface ResponseCopyOrder { + emailChannel: boolean; + idCard: string; + inboxChannel: boolean; + name: string; + personalId: string; + position: string; + selectStatus: boolean; + sequence: number; + unit: string; +} + +interface DataCopyOrder { + personalId: string; + name: string; + idCard: string; + position: string; + unit: string; + send: string; + mutiselect: number[]; +} + +export type { ResponseData, ResponseOrganiz, ResponseCopyOrder, DataCopyOrder }; diff --git a/src/modules/10_order/router.ts b/src/modules/10_order/router.ts new file mode 100644 index 000000000..a059df203 --- /dev/null +++ b/src/modules/10_order/router.ts @@ -0,0 +1,40 @@ +/** + * Router บรรจุ แต่งตั้ง ย้าย โอน (Placement) + */ + +const AddPage = () => + import("@/modules/10_order/components/Add.vue"); +const MainOrder = () => import("@/modules/10_order/components/Main.vue"); +const DetailPage = () => + import("@/modules/10_order/components/Detail.vue"); + +export default [ + { + path: "/order", + name: "order", + component: MainOrder, + meta: { + Auth: true, + Key: [10], + Role: "placement", + }, + }, + { + path: "/order/add", + name: "OrderAdd", + component: AddPage, + meta: { + Auth: true, + Role: "placement", + }, + }, + { + path: "/order/detail/:orderid", + name: "OrderDetail", + component: DetailPage, + meta: { + Auth: true, + Role: "placement", + }, + }, +]; diff --git a/src/modules/10_order/store.ts b/src/modules/10_order/store.ts new file mode 100644 index 000000000..dff32467e --- /dev/null +++ b/src/modules/10_order/store.ts @@ -0,0 +1,100 @@ +import { defineStore } from "pinia"; +import { ref } from "vue"; +import type { FormOrderPlacementMainData } from "@/modules/10_order/interface/request/Main"; + +export const useOrderPlacementDataStore = defineStore("placementOrder", () => { + interface placementOrder { + mappingPosition: { columns: String[] }; + } + const placementOrderData = ref({ + mappingPosition: { columns: [] }, + }); + const changePlacementColumns = (system: String, val: String[]) => { + if (system == "mappingPosition") + placementOrderData.value.mappingPosition.columns = val; + localStorage.setItem( + "placementOrder", + JSON.stringify(placementOrderData.value) + ); + }; + + if (localStorage.getItem("placementOrder") !== null) { + placementOrderData.value = JSON.parse( + localStorage.getItem("placementOrder") || "{}" + ); + } + + const DataMainYearOrder = ref([]); // ข้อมูลจำนวนปี + const DataMainOrigOrder = ref([]); // ข้อมูลหลักดั้งเดิม + const DataMainUpdateOrder = ref([]); // ข้อมูลเปลี่ยนแปลง + const DataMainYearSetOrder = (val: FormOrderPlacementMainData[]) => + (DataMainYearOrder.value = val); + + const DataMainOrder = (val: FormOrderPlacementMainData[]) => + (DataMainOrigOrder.value = val); + + const DataUpdateOrder = ( + filter_1: string, + filter_2: string, + filterYear: number | null + ) => { + DataMainUpdateOrder.value = []; + + if (filter_1 === "" && filter_2 === "" && filterYear === 0) { + DataMainUpdateOrder.value = DataMainOrigOrder.value; + } else if (filter_1 !== "" && filter_2 === "" && filterYear === 0) { + DataMainUpdateOrder.value = DataMainOrigOrder.value.filter( + (item) => item.OrderType === filter_1 + ); + } else if (filter_1 !== "" && filter_2 !== "" && filterYear === null) { + DataMainUpdateOrder.value = DataMainOrigOrder.value.filter( + (item) => item.OrderType === filter_1 && item.OrderStatus === filter_2 + ); + } else if (filter_1 !== "" && filter_2 === "" && filterYear !== 0) { + DataMainUpdateOrder.value = DataMainOrigOrder.value.filter( + (item) => item.OrderType === filter_1 && item.fiscalYear === filterYear + ); + } else if (filter_1 === "" && filter_2 !== "" && filterYear === 0) { + DataMainUpdateOrder.value = DataMainOrigOrder.value.filter( + (item) => item.OrderStatus === filter_2 + ); + } else if (filter_1 === "" && filter_2 === "" && filterYear !== 0) { + DataMainUpdateOrder.value = DataMainOrigOrder.value.filter( + (item) => item.fiscalYear === filterYear + ); + } else if (filter_1 === "" && filter_2 !== "" && filterYear !== null) { + DataMainUpdateOrder.value = DataMainOrigOrder.value.filter( + (item) => + item.OrderStatus === filter_2 && item.fiscalYear === filterYear + ); + } else if (filter_1 !== "" && filter_2 !== "" && filterYear === 0) { + DataMainUpdateOrder.value = DataMainOrigOrder.value.filter( + (item) => item.OrderStatus === filter_2 && item.OrderType === filter_1 + ); + } else if (filter_1 !== "" && filter_2 !== "" && filterYear !== null) { + DataMainUpdateOrder.value = DataMainOrigOrder.value.filter( + (item) => + item.OrderType === filter_1 && + item.OrderStatus === filter_2 && + item.fiscalYear === filterYear + ); + } else if ( + filter_1 == "ทั้งหมด" && + filter_2 == "ทั้งหมด" && + filterYear !== null + ) { + DataMainUpdateOrder.value = DataMainOrigOrder.value; + } + }; + + return { + placementOrderData, + changePlacementColumns, + DataMainYearOrder, + DataMainOrigOrder, + DataMainUpdateOrder, + DataUpdateOrder, + DataMainYearSetOrder, + DataMainOrder, + }; +}); \ No newline at end of file diff --git a/src/modules/10_order/views/Main.vue b/src/modules/10_order/views/Main.vue new file mode 100644 index 000000000..dc47857b9 --- /dev/null +++ b/src/modules/10_order/views/Main.vue @@ -0,0 +1,7 @@ + + \ No newline at end of file diff --git a/src/router/index.ts b/src/router/index.ts index 28211f6e6..ee4354771 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -13,6 +13,7 @@ import ModuleRetirement from "@/modules/06_retirement/router"; import ModuleInsignia from "@/modules/07_insignia/router"; import ModuleRegistryEmployee from "@/modules/08_registryEmployee/router"; import ModuleCoin from "@/modules/09_coin/router"; +import ModuleOrder from "@/modules/10_order/router"; // TODO: ใช้หรือไม่? import keycloak from "@/plugins/keycloak"; @@ -44,6 +45,7 @@ const router = createRouter({ ...ModuleInsignia, ...ModuleRegistryEmployee, ...ModuleCoin, + ...ModuleOrder, ], }, /** diff --git a/src/views/MainLayout.vue b/src/views/MainLayout.vue index 76ee21a07..04eee3f99 100644 --- a/src/views/MainLayout.vue +++ b/src/views/MainLayout.vue @@ -221,9 +221,11 @@ const myEventHandler = (e: any, setSCroll: boolean) => { */ const activeMenu = (path: string) => { if (path == "dashboard" && route.fullPath == "/") return true; - + if (path == "registry" && route.fullPath == "/registry-employee") return false; if (path == "registry" && route.fullPath == "/") return false; - const bool = route.fullPath.includes(path); + // if (path != "registry" && path == "registryEmployee" && route.fullPath == "/registryEmployee") return true; + const bool = route.fullPath.includes(`/${path}`); + return bool; }; /**