114 lines
2.5 KiB
Vue
114 lines
2.5 KiB
Vue
<script setup>
|
|
import NotesPanel from '@/pages/providers/NotesPanel.vue'
|
|
import PrescriptionPanel from '@/pages/providers/PrescriptionPanel.vue'
|
|
import ProviderBioPanel from '@/pages/providers/ProviderBioPanel.vue'
|
|
import ProviderTabOverview from '@/pages/providers/ProviderTabOverview.vue'
|
|
import UserTabNotifications from '@/views/apps/user/view/UserTabNotifications.vue'
|
|
import { useStore } from 'vuex'
|
|
const patientDtail = ref(null);
|
|
|
|
const store = useStore();
|
|
const route = useRoute('apps-user-view-id')
|
|
const userTab = ref(null)
|
|
|
|
const tabs = [
|
|
{
|
|
icon: 'ri-group-line',
|
|
title: 'Overview',
|
|
},
|
|
{
|
|
icon: 'ri-lock-2-line',
|
|
title: 'Notes',
|
|
},
|
|
{
|
|
icon: 'ri-bookmark-line',
|
|
title: 'Prescriptions',
|
|
},
|
|
// {
|
|
// icon: 'ri-notification-4-line',
|
|
// title: 'Notifications',
|
|
// },
|
|
// {
|
|
// icon: 'ri-link-m',
|
|
// title: 'Connections',
|
|
// },
|
|
]
|
|
const getPatientDeatail = async () => {
|
|
store.dispatch('updateIsLoading', true);
|
|
await store.dispatch('providerDetial', { id: route.params.id });
|
|
store.dispatch('updateIsLoading', false);
|
|
|
|
let list = store.getters.getProviderDetail;
|
|
patientDtail.value=list
|
|
console.log(list.patient);
|
|
};
|
|
onMounted(async () => {
|
|
await getPatientDeatail();
|
|
|
|
});
|
|
//const { data: userData } = await useApi(`/apps/users/${ route.params.id }`)
|
|
</script>
|
|
|
|
<template>
|
|
<VRow v-if="patientDtail">
|
|
<VCol
|
|
cols="12"
|
|
md="5"
|
|
lg="4"
|
|
>
|
|
<ProviderBioPanel :user-data="patientDtail" />
|
|
</VCol>
|
|
|
|
<VCol
|
|
cols="12"
|
|
md="7"
|
|
lg="8"
|
|
>
|
|
<VTabs
|
|
v-model="userTab"
|
|
class="v-tabs-pill"
|
|
>
|
|
<VTab
|
|
v-for="tab in tabs"
|
|
:key="tab.icon"
|
|
>
|
|
<VIcon
|
|
start
|
|
:icon="tab.icon"
|
|
/>
|
|
<span>{{ tab.title }}</span>
|
|
</VTab>
|
|
</VTabs>
|
|
|
|
<VWindow
|
|
v-model="userTab"
|
|
class="mt-6 disable-tab-transition"
|
|
:touch="false"
|
|
>
|
|
<VWindowItem>
|
|
<ProviderTabOverview :user-data="patientDtail"/>
|
|
</VWindowItem>
|
|
|
|
<VWindowItem>
|
|
<NotesPanel :notes-data="patientDtail"/>
|
|
</VWindowItem>
|
|
|
|
<VWindowItem>
|
|
<PrescriptionPanel :prescription-data="patientDtail"/>
|
|
</VWindowItem>
|
|
|
|
<VWindowItem>
|
|
<UserTabNotifications />
|
|
</VWindowItem>
|
|
|
|
|
|
</VWindow>
|
|
</VCol>
|
|
</VRow>
|
|
<VCard v-else>
|
|
<VCardTitle class="text-center">
|
|
No User Found
|
|
</VCardTitle>
|
|
</VCard>
|
|
</template>
|