From 90cc20554b6464ca7be5ae29be90440973e6bc72 Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Thu, 13 Mar 2025 15:37:56 +0700 Subject: [PATCH 01/10] edit title --- README.md | 2 +- index.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 579ee97..bf53288 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# BMA ระบบลงเวลาเข้า-ออกงาน +# HRMS ระบบลงเวลาเข้า-ออกงาน ## Project setup diff --git a/index.html b/index.html index 52d9075..3d71b38 100644 --- a/index.html +++ b/index.html @@ -4,7 +4,7 @@ - BMA ระบบลงเวลาเข้า-ออกงาน + HRMS ระบบลงเวลาเข้า-ออกงาน diff --git a/src/router/index.ts b/src/router/index.ts index de8d3f1..23e3edb 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -13,7 +13,7 @@ const router = createRouter({ routes: [ { path: '/', - name: 'home', + name: 'main', component: MainView, children: [ { diff --git a/src/views/HomeView.vue b/src/views/HomeView.vue index f098690..7ab94df 100644 --- a/src/views/HomeView.vue +++ b/src/views/HomeView.vue @@ -50,6 +50,8 @@ const Thai = ref(dateNow.value) const formattedS = ref() const formattedM = ref() const formattedH = ref() +const formattedHH = ref() +const formattedA = ref() /** function อัพเดทเวลา*/ function updateClock() { @@ -57,9 +59,14 @@ function updateClock() { const hh = moment(date).format('HH') const mm = moment(date).format('mm') const ss = moment(date).format('ss') + const HH = moment(date).format('hh'); + const A = moment(date).format('a'); + formattedS.value = ss formattedM.value = mm formattedH.value = hh + formattedHH.value = HH + formattedA.value = A } setInterval(updateClock, 1000) @@ -254,11 +261,17 @@ function updateWorkplace() { */ const getClass = (val: boolean) => { return { - 'bg-primary text-white col-12 row items-center q-px-md q-py-sm': val, - 'bg-red-9 text-white col-12 row items-center q-px-md q-py-sm': !val, + 'bg-primary text-white col-12 row items-center q-px-md q-py-sm ': val, + 'bg-red-9 text-white col-12 row items-center q-px-md q-py-sm ': !val, } } +const getClassXS = (val: boolean) => { + return { + 'bg-topIn text-white q-pa-lg col-12 row': val, + 'bg-topOut text-white q-pa-lg col-12 row': !val, + } +} const inQueue = ref(false) async function fetchCheckStatus() { @@ -312,252 +325,423 @@ onMounted(async () => { diff --git a/src/views/MainView.vue b/src/views/MainView.vue index 6cf7bd4..8b215c7 100644 --- a/src/views/MainView.vue +++ b/src/views/MainView.vue @@ -517,7 +517,7 @@ onMounted(async () => { :style=" $q.screen.gt.xs ? 'padding: 1.8% 2%; margin-top: -200px;' - : 'padding: 5% 4%; margin-top: -200px;' + : 'padding: 0% 0%; margin-top: -200px;' " > From b3aeda65bd93fecea59198460bd0a90e6218cdbb Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Fri, 14 Mar 2025 18:13:33 +0700 Subject: [PATCH 03/10] move map last page --- src/views/HomeView.vue | 788 +++++++++++++++++++++-------------------- 1 file changed, 407 insertions(+), 381 deletions(-) diff --git a/src/views/HomeView.vue b/src/views/HomeView.vue index 7ab94df..935dd5b 100644 --- a/src/views/HomeView.vue +++ b/src/views/HomeView.vue @@ -59,8 +59,8 @@ function updateClock() { const hh = moment(date).format('HH') const mm = moment(date).format('mm') const ss = moment(date).format('ss') - const HH = moment(date).format('hh'); - const A = moment(date).format('a'); + const HH = moment(date).format('hh') + const A = moment(date).format('a') formattedS.value = ss formattedM.value = mm @@ -325,134 +325,142 @@ onMounted(async () => { From c4fcfbef768b935b465932f4f0ef3eddfcd3b45d Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Mon, 17 Mar 2025 09:24:14 +0700 Subject: [PATCH 04/10] fix test --- index.html | 4 ++-- src/views/MainView.vue | 7 ++++++- src/views/login.vue | 4 ++++ 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/index.html b/index.html index 3d71b38..4828cc4 100644 --- a/index.html +++ b/index.html @@ -20,10 +20,10 @@
- - + --> diff --git a/src/views/MainView.vue b/src/views/MainView.vue index 8b215c7..9f5f853 100644 --- a/src/views/MainView.vue +++ b/src/views/MainView.vue @@ -160,7 +160,7 @@ function onLoad(index: number, done: Function) { } // landing page redirect -const landingPageUrl = ref(configParam.landingPageUrl) +// const landingPageUrl = ref(configParam.landingPageUrl) /** ฟังก์ชันเรียกข้อมูลผู้ใช่งาน*/ async function fetchKeycloakPosition() { @@ -291,6 +291,11 @@ onMounted(async () => { if (checkTokenParsed != null) { fullName.value = checkTokenParsed.name } + console.log('configParam.landingPageUrl', configParam.landingPageUrl) + console.log( + 'import.meta.env.VITE_URL_LANDING', + import.meta.env.VITE_URL_LANDING + ) }) diff --git a/src/views/login.vue b/src/views/login.vue index df02614..5600401 100644 --- a/src/views/login.vue +++ b/src/views/login.vue @@ -54,6 +54,10 @@ onMounted(async () => { if (checkAuthen) { router.push('/') } + console.log( + 'import.meta.env.VITE_URL_LANDING', + import.meta.env.VITE_URL_LANDING + ) }) From 8302f3c94d8b08d87b758da11cbca6416450886c Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Mon, 17 Mar 2025 09:34:04 +0700 Subject: [PATCH 05/10] fix --- src/views/MainView.vue | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/views/MainView.vue b/src/views/MainView.vue index 9f5f853..14df40d 100644 --- a/src/views/MainView.vue +++ b/src/views/MainView.vue @@ -27,9 +27,9 @@ const router = useRouter() const $q = useQuasar() // landing page config url -const configParam = { - landingPageUrl: import.meta.env.VITE_URL_LANDING, -} +// const configParam = { +// landingPageUrl: import.meta.env.VITE_URL_LANDING, +// } const modalReset = ref(false) //ตัวแปร popup reset password const fullName = ref('') //ชื่อผู้ใช้งาน @@ -291,11 +291,6 @@ onMounted(async () => { if (checkTokenParsed != null) { fullName.value = checkTokenParsed.name } - console.log('configParam.landingPageUrl', configParam.landingPageUrl) - console.log( - 'import.meta.env.VITE_URL_LANDING', - import.meta.env.VITE_URL_LANDING - ) }) From bb12748e042d8971f17c6ee09a7993893aadd24a Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Mon, 17 Mar 2025 09:36:21 +0700 Subject: [PATCH 06/10] fix --- src/views/login.vue | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/views/login.vue b/src/views/login.vue index 5600401..df02614 100644 --- a/src/views/login.vue +++ b/src/views/login.vue @@ -54,10 +54,6 @@ onMounted(async () => { if (checkAuthen) { router.push('/') } - console.log( - 'import.meta.env.VITE_URL_LANDING', - import.meta.env.VITE_URL_LANDING - ) }) From 8ec0e2207ca7a3d5e82e43602d423130991a1dd8 Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Mon, 17 Mar 2025 17:10:24 +0700 Subject: [PATCH 07/10] fix MAP --- src/components/AscGISMap.vue | 49 ++++++++++++++++++++++-------------- src/views/HomeView.vue | 6 +++-- 2 files changed, 34 insertions(+), 21 deletions(-) diff --git a/src/components/AscGISMap.vue b/src/components/AscGISMap.vue index 728ded1..693f7d7 100644 --- a/src/components/AscGISMap.vue +++ b/src/components/AscGISMap.vue @@ -198,13 +198,24 @@ onMounted(async () => { -
+
- - diff --git a/src/views/HomeView.vue b/src/views/HomeView.vue index 935dd5b..38a3f4a 100644 --- a/src/views/HomeView.vue +++ b/src/views/HomeView.vue @@ -387,9 +387,11 @@ onMounted(async () => { >
- +
-
Date: Tue, 18 Mar 2025 09:30:59 +0700 Subject: [PATCH 08/10] updated --- src/views/HomeView.vue | 1 - 1 file changed, 1 deletion(-) diff --git a/src/views/HomeView.vue b/src/views/HomeView.vue index 38a3f4a..52f79e1 100644 --- a/src/views/HomeView.vue +++ b/src/views/HomeView.vue @@ -493,7 +493,6 @@ onMounted(async () => { Date: Tue, 18 Mar 2025 22:39:49 +0700 Subject: [PATCH 09/10] fixing env --- .env.production | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.env.production b/.env.production index dce5f3a..065bcc6 100644 --- a/.env.production +++ b/.env.production @@ -1,2 +1,3 @@ -VITE_API_URI_CONFIG: "https://bma-ehr.frappet.synology.me/api/v1" -VITE_URL_SSO: "https://bma-sso.frappet.synology.me" \ No newline at end of file +VITE_API_URI_CONFIG=VITE_API_URI_CONFIG +VITE_URL_SSO=VITE_URL_SSO +VITE_URL_LANDING=VITE_URL_LANDING \ No newline at end of file From 238e853860a7a6c347c9ea7ca99390960d251e48 Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Tue, 18 Mar 2025 23:18:31 +0700 Subject: [PATCH 10/10] fixing display --- src/views/HomeView.vue | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/views/HomeView.vue b/src/views/HomeView.vue index 52f79e1..da900af 100644 --- a/src/views/HomeView.vue +++ b/src/views/HomeView.vue @@ -719,16 +719,16 @@ onMounted(async () => {
- {{ formattedHH }}: + {{ formattedH }}:
- {{ formattedM }} + {{ formattedM }}:
-
{{ formattedA }}
+
{{ formattedS }}
@@ -736,13 +736,9 @@ onMounted(async () => { - + -
+

+
+ +
*{{ msgCheckTime }}
+