From 7343405d19c7394ea6796d14923c06e3125f79a9 Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Mon, 18 Nov 2024 10:22:56 +0700 Subject: [PATCH 01/31] fix env report --- .env.production | 4 +- entrypoint.sh | 2 + src/api/index.ts | 8 ++++ src/api/reports/api.report.ts | 7 ++++ src/app.config.ts | 9 +++- src/modules/10_registry/views/main.vue | 58 ++++++-------------------- src/plugins/genreport.ts | 27 +++++++----- 7 files changed, 56 insertions(+), 59 deletions(-) create mode 100644 src/api/reports/api.report.ts diff --git a/.env.production b/.env.production index 277058b..17b2902 100644 --- a/.env.production +++ b/.env.production @@ -10,4 +10,6 @@ VITE_URL_SSO: VITE_URL_SSO # VITE_CLIENTID_KEYCLOAK: "bma-ehr-exam-vue3" # VITE_URL_KEYCLOAK: "https://id.frappet.synology.me/" # VITE_API_URI_CONFIG: "https://bma-ehr.frappet.synology.me/api/v1" -# VITE_API_PUBLISH_URL: "https://bma-ehr-publish.frappet.synology.me" \ No newline at end of file +# VITE_API_PUBLISH_URL: "https://bma-ehr-publish.frappet.synology.me" +VITE_API_REPORT_URL=VITE_API_REPORT_URL + diff --git a/entrypoint.sh b/entrypoint.sh index d84bb9b..c386c66 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -16,6 +16,8 @@ do sed -i 's|VITE_CLIENTSECRET_KEYCLOAK|'${VITE_CLIENTSECRET_KEYCLOAK}'|g' $file sed -i 's|VITE_MANUAL_URL|'${VITE_MANUAL_URL}'|g' $file sed -i 's|VITE_URL_SSO|'${VITE_URL_SSO}'|g' $file + sed -i 's|VITE_API_REPORT_URL|'${VITE_API_REPORT_URL}'|g' $file + done diff --git a/src/api/index.ts b/src/api/index.ts index b646c57..90fc5db 100644 --- a/src/api/index.ts +++ b/src/api/index.ts @@ -4,6 +4,7 @@ import { ref } from "vue"; const env = ref(process.env.NODE_ENV || "development"); export const apiUrlConfig = import.meta.env.VITE_API_URI_CONFIG; export const apiUrlConfigPublish = import.meta.env.VITE_API_PUBLISH_URL; +export const apiUrlConfigReport = import.meta.env.VITE_API_REPORT_URL; // if (process.env.VUE_APP_TEST) { // env = "test"; @@ -15,6 +16,8 @@ const config = ref({ API_URL_SUPPORT: "https://bma-ehr.frappet.synology.me/api/v1/support", MEET_URI: "meet.frappet.com", LINK_EVALUATE_PUBLISH: "https://bma-ehr-publish.frappet.synology.me", + API_REPORT_TEMPLATE_URI: + "https://report-server.frappet.synology.me/api/v1/report-template", }, test: { API_URI: "http://localhost:5010/api/v1", @@ -27,6 +30,7 @@ const config = ref({ "https://s3cluster.frappet.com/bma-ehr-fpt/organization/strueture/tree_20230707_115124.json", MEET_URI: "meet.frappet.com", LINK_EVALUATE_PUBLISH: apiUrlConfigPublish, + API_REPORT_TEMPLATE_URI: apiUrlConfigReport, }, }); @@ -36,6 +40,9 @@ const MEET_URI = ref(config.value[env.value].MEET_URI); const LINK_EVALUATE_PUBLISH = ref( config.value[env.value].LINK_EVALUATE_PUBLISH ); +const API_REPORT_TEMPLATE_URI = ref( + config.value[env.value].API_REPORT_TEMPLATE_URI +); export default { env: env.value, @@ -44,4 +51,5 @@ export default { API_URL_SUPPORT: API_URL_SUPPORT.value, MEET_URI: MEET_URI.value, LINK_EVALUATE_PUBLISH: LINK_EVALUATE_PUBLISH.value, + API_REPORT_TEMPLATE_URI: API_REPORT_TEMPLATE_URI.value, }; diff --git a/src/api/reports/api.report.ts b/src/api/reports/api.report.ts new file mode 100644 index 0000000..e8c98b4 --- /dev/null +++ b/src/api/reports/api.report.ts @@ -0,0 +1,7 @@ +import env from "../index"; + +const reportTemplate = `${env.API_REPORT_TEMPLATE_URI}`; + +export default { + reportTemplate, +}; diff --git a/src/app.config.ts b/src/app.config.ts index 0b1387d..ecbd141 100644 --- a/src/app.config.ts +++ b/src/app.config.ts @@ -14,6 +14,9 @@ import kpi from "./api/KPI/api.kpis"; import probation from "./api/probation/api.probation"; import development from "./api/api.development"; +/** API reports */ +import reports from "./api/reports/api.report"; + const API = { ...testtest, ...retirementResign, @@ -27,6 +30,8 @@ const API = { ...kpi, ...probation, ...development, + //reports + ...reports, }; const path = @@ -61,7 +66,9 @@ const generatePopupPath = (routeName: any, type: string) => { return `${path}/manual/chapter-6-user-transfer`; } if (routeName.includes("appealComplain")) { - return `${path}/manual/chapter-${type ? "4" : "7"}-user${type}-appeal-complain`; + return `${path}/manual/chapter-${ + type ? "4" : "7" + }-user${type}-appeal-complain`; } if (routeName.includes("KPI-evaluator")) { return `${path}/manual/chapter-9-user-KPI-evaluator`; diff --git a/src/modules/10_registry/views/main.vue b/src/modules/10_registry/views/main.vue index f3e70c5..0fb2ead 100644 --- a/src/modules/10_registry/views/main.vue +++ b/src/modules/10_registry/views/main.vue @@ -1,10 +1,12 @@ @@ -484,6 +500,19 @@ function onInfo() { + + + + + Landing Page + + Date: Mon, 18 Nov 2024 14:11:31 +0700 Subject: [PATCH 04/31] =?UTF-8?q?=E0=B9=80=E0=B8=9E=E0=B8=B4=E0=B9=88?= =?UTF-8?q?=E0=B8=A1=E0=B9=80=E0=B8=A1=E0=B8=99=E0=B8=B9=E0=B9=84=E0=B8=9B?= =?UTF-8?q?=E0=B8=AB=E0=B8=99=E0=B9=89=E0=B8=B2=20Landing=20Page?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/MainLayout.vue | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/src/views/MainLayout.vue b/src/views/MainLayout.vue index 13b24ac..393bda7 100644 --- a/src/views/MainLayout.vue +++ b/src/views/MainLayout.vue @@ -499,7 +499,7 @@ const landingPageUrl = () => { - + { /> - + + + + + + Landing Page + { > - + From b9cf252e368b21e20f04b0ff0b6bfd96fa65c895 Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Mon, 18 Nov 2024 15:31:46 +0700 Subject: [PATCH 05/31] fixing landing page --- src/views/MainLayout.vue | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/views/MainLayout.vue b/src/views/MainLayout.vue index 13b24ac..1cd9061 100644 --- a/src/views/MainLayout.vue +++ b/src/views/MainLayout.vue @@ -234,7 +234,8 @@ function onInfo() { } // landing page redirect -const landingPageUrl = () => { +const landingPageUrl = ref(getLandingUrl()); +function getLandingUrl() { if (window.location.hostname === "bmasso.bma.go.th") { return `${configParam.landingPageUrl}/landing?mode=dev`; } else if (window.location.hostname === "bma-ehr.frappet.com") { @@ -242,7 +243,7 @@ const landingPageUrl = () => { } else { return `${configParam.landingPageUrl}/landing?mode=dev`; } -}; +} From a2198b3302dc7f34ef25e37816de2b997e3024e8 Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Mon, 18 Nov 2024 23:10:43 +0700 Subject: [PATCH 06/31] fixing label --- src/modules/05_leave/components/formDetail/01_SickForm.vue | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/modules/05_leave/components/formDetail/01_SickForm.vue b/src/modules/05_leave/components/formDetail/01_SickForm.vue index cf8a51a..1c9d53d 100644 --- a/src/modules/05_leave/components/formDetail/01_SickForm.vue +++ b/src/modules/05_leave/components/formDetail/01_SickForm.vue @@ -50,9 +50,11 @@ const props = defineProps({
- ลาครั้งสุดท้ายในประเภทนั้น ๆ เมื่อวันที่ + ลาครั้งสุดท้ายเมื่อวันที่ +
+
+ {{ props.data.leaveLastStart ?? "-" }}
-
{{ props.data.leaveLastStart }}
หมายเลขที่ติดต่อขณะลา
From 6fd22e0c32d4268255ffd6705d8c130e20a15901 Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Tue, 19 Nov 2024 11:52:34 +0700 Subject: [PATCH 07/31] =?UTF-8?q?=E0=B9=81=E0=B8=AA=E0=B8=94=E0=B8=87?= =?UTF-8?q?=E0=B8=A3=E0=B8=B9=E0=B8=9B=20Profile?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/MainLayout.vue | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/views/MainLayout.vue b/src/views/MainLayout.vue index 6d0da85..c73f646 100644 --- a/src/views/MainLayout.vue +++ b/src/views/MainLayout.vue @@ -500,7 +500,7 @@ function getLandingUrl() { - + @@ -566,7 +566,6 @@ function getLandingUrl() { text-color="white" icon="home" size="18px" - /> Landing Page From 38bdb23a0dc1474791ec8c6a4cd37d2692dcbd8f Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Wed, 20 Nov 2024 11:00:43 +0700 Subject: [PATCH 08/31] edit api path --- src/api/probation/api.probation.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/probation/api.probation.ts b/src/api/probation/api.probation.ts index 274f2a1..fdd102b 100644 --- a/src/api/probation/api.probation.ts +++ b/src/api/probation/api.probation.ts @@ -6,7 +6,7 @@ const kpiCapacity = `${env.API_URI}/kpi/capacity`; const reportProbation = `${env.API_URI}/report/probation`; export default { probationMain: (id: string) => - `${probation}/assign/probation-assign-list?personal_id=${id}`, + `${probation}/assign/assign-user-list?personal_id=${id}`, orgProfilePlacement: (id: string) => `${org}/profile/placement/${id}`, calculateDate: () => `${probation}/calculate/assign-finish`, From 7cb5f1e2ec71df03bcd0c9ca6ae81d0ee93c8311 Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Wed, 20 Nov 2024 17:40:34 +0700 Subject: [PATCH 09/31] =?UTF-8?q?Workflow=20=E0=B8=A5=E0=B8=B2=E0=B8=A5?= =?UTF-8?q?=E0=B8=B9=E0=B8=81=E0=B8=88=E0=B9=89=E0=B8=B2=E0=B8=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/05_leave/components/DialogDetail.vue | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/modules/05_leave/components/DialogDetail.vue b/src/modules/05_leave/components/DialogDetail.vue index 4a72760..a1ee1de 100644 --- a/src/modules/05_leave/components/DialogDetail.vue +++ b/src/modules/05_leave/components/DialogDetail.vue @@ -499,9 +499,7 @@ watch( Date: Thu, 21 Nov 2024 10:06:59 +0700 Subject: [PATCH 10/31] =?UTF-8?q?=E0=B9=80=E0=B8=9E=E0=B8=B4=E0=B9=88?= =?UTF-8?q?=E0=B8=A1=20verify=20Email?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/router/index.ts | 6 ++++++ src/views/VerifyEmail.vue | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 src/views/VerifyEmail.vue diff --git a/src/router/index.ts b/src/router/index.ts index af9989a..103e994 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -5,6 +5,7 @@ const Dashboard = () => import("@/modules/01_dashboard/views/Dashboard.vue"); const Error404NotFound = () => import("@/views/Error404NotFound.vue"); const loginMain = () => import("@/views/login.vue"); const ErrorPermission = () => import("@/views/ErrorPermission.vue"); +const VerifyEmail = () => import("@/views/VerifyEmail.vue"); import ModuleTransfer from "@/modules/02_transfer/router"; import ModuleRetire from "@/modules/03_retire/router"; @@ -77,6 +78,11 @@ const router = createRouter({ Auth: false, }, }, + { + path: "/verifyemail", + name: "verifyemail", + component: VerifyEmail, + }, { path: "/auth", name: "auth", diff --git a/src/views/VerifyEmail.vue b/src/views/VerifyEmail.vue new file mode 100644 index 0000000..425bc2c --- /dev/null +++ b/src/views/VerifyEmail.vue @@ -0,0 +1,34 @@ + + + + + From 4a8bad800267996e1971fd1fdd032c2b03b3308b Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Thu, 21 Nov 2024 15:11:55 +0700 Subject: [PATCH 11/31] verify-email --- src/router/index.ts | 2 +- src/views/VerifyEmail.vue | 42 ++++++++++++++++++++++++++++++++++++++- 2 files changed, 42 insertions(+), 2 deletions(-) diff --git a/src/router/index.ts b/src/router/index.ts index 103e994..3e6cc89 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -79,7 +79,7 @@ const router = createRouter({ }, }, { - path: "/verifyemail", + path: "/verifyemail/:token", name: "verifyemail", component: VerifyEmail, }, diff --git a/src/views/VerifyEmail.vue b/src/views/VerifyEmail.vue index 425bc2c..d9e2ed6 100644 --- a/src/views/VerifyEmail.vue +++ b/src/views/VerifyEmail.vue @@ -1,4 +1,44 @@ - +