From 9346a786001749a4fb7e2453e755bca600520cff Mon Sep 17 00:00:00 2001 From: Muhammad Shahzad Date: Mon, 10 Jun 2024 22:15:28 +0500 Subject: [PATCH 1/6] fixes --- .../js/plugins/1.router/additional-routes.js | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/resources/js/plugins/1.router/additional-routes.js b/resources/js/plugins/1.router/additional-routes.js index 18c5fa5..98de1a6 100644 --- a/resources/js/plugins/1.router/additional-routes.js +++ b/resources/js/plugins/1.router/additional-routes.js @@ -4,9 +4,24 @@ const emailRouteComponent = () => import('@/pages/apps/email/index.vue') export const redirects = [ // â„šī¸ We are redirecting to different pages based on role. // NOTE: Role is just for UI purposes. ACL is based on abilities. + { + path: '/admin', + // name: 'index', + redirect: to => { + // TODO: Get type from backend + const userData = useCookie('userData') + const userRole = userData.value?.role + if (userRole === 'admin') + return { name: 'admin-dashboard' } + if (userRole === 'client') + return { name: 'access-control' } + + return { name: 'login', query: to.query } + }, + }, { path: '/', - name: 'index', + // name: 'index', redirect: to => { // TODO: Get type from backend const userData = useCookie('userData') From 6629ad584d559c6dbd97a2f918f1e06394c3ca1b Mon Sep 17 00:00:00 2001 From: "nasir@endelospay.com" Date: Mon, 10 Jun 2024 22:32:12 +0500 Subject: [PATCH 2/6] fix --- resources/js/pages/labs/labs-kit.vue | 12 +++--- .../js/pages/patients/PatienTabOverview.vue | 14 +++--- .../js/pages/patients/PatientBioPanel.vue | 43 +++++++------------ .../js/pages/providers/ProviderBioPanel.vue | 30 +++---------- 4 files changed, 33 insertions(+), 66 deletions(-) diff --git a/resources/js/pages/labs/labs-kit.vue b/resources/js/pages/labs/labs-kit.vue index 30a139f..667baaa 100644 --- a/resources/js/pages/labs/labs-kit.vue +++ b/resources/js/pages/labs/labs-kit.vue @@ -64,10 +64,10 @@ const headers = [ }, - { - title: 'ACTIONS', - key: 'actions', - }, + // { + // title: 'ACTIONS', + // key: 'actions', + // }, ] const resolveStatusVariant = status => { @@ -187,8 +187,8 @@ onMounted(() => { - - + + New Lab Kit diff --git a/resources/js/pages/patients/PatienTabOverview.vue b/resources/js/pages/patients/PatienTabOverview.vue index f5cfe89..4ac304b 100644 --- a/resources/js/pages/patients/PatienTabOverview.vue +++ b/resources/js/pages/patients/PatienTabOverview.vue @@ -42,12 +42,12 @@ const refVForm = ref(null); // Headers const headers = [ // { title: 'Appointment Id', key: 'id' }, - { title: 'Patient', key: 'patient_name' }, - // { key: 'appointment_date', sortable: false, title: 'Date' }, - { key: 'start_time', title: 'Start Time' }, - { key: 'end_time', title: 'End Time' }, - { key: 'duration', title: 'Duration' }, - { title: 'ACTIONS', key: 'actions' }, + { title: 'Provider', key: 'provider_name' }, + { key: 'appointment_date', sortable: false, title: 'Date' }, + //{ key: 'start_time', title: 'Start Time' }, + // { key: 'end_time', title: 'End Time' }, + //{ key: 'duration', title: 'Duration' }, + //{ title: 'ACTIONS', key: 'actions' }, ]; @@ -93,7 +93,7 @@ const getPatientMeetingList = async () => { patientMeetingList.value = list.map(history => ({ ...history, - appointment_date: formatDate(history.appointment_date), + appointment_date: formatDate(history.appointment_date+' '+history.appointment_time), start_time: formatDate(history.start_time), end_time: formatDate(history.end_time), duration: totalCallDuration(history.start_time, history.end_time), diff --git a/resources/js/pages/patients/PatientBioPanel.vue b/resources/js/pages/patients/PatientBioPanel.vue index 74141b1..e63d0fc 100644 --- a/resources/js/pages/patients/PatientBioPanel.vue +++ b/resources/js/pages/patients/PatientBioPanel.vue @@ -62,6 +62,11 @@ const resolveUserRoleVariant = role => { icon: 'ri-user-line', } } + const firstThreeLines = computed(() => { + const lines = props.userData.plans.list_two_title.split(',') + return lines.slice(0, 3) + }) +