Fix: debug Uplaod Doc List table

This commit is contained in:
hasyim_kai
2025-11-21 10:20:23 +07:00
parent 2e48f11f9c
commit c4eaa72aec
@@ -20,8 +20,8 @@ const roleAccess: PagePermission = PAGE_PERMISSIONS['/rehab/encounter']
const { getPagePermissions } = useRBAC()
const pagePermission = getPagePermissions(roleAccess)
const {user,userRole} = useUserStore()
const {getUserPermissions} = useRBAC()
// const {user,userRole} = useUserStore()
// const {getUserPermissions} = useRBAC()
// #endregion
// #region State
@@ -121,6 +121,7 @@ watch([recId, recAction, timestamp], () => {
case ActionEvents.showDetail:
isDocPreviewDialogOpen.value = true
break
case ActionEvents.showEdit:
if(pagePermission.canUpdate){
navigateTo({
@@ -131,22 +132,13 @@ watch([recId, recAction, timestamp], () => {
unauthorizedToast()
}
break
case ActionEvents.showConfirmDelete:
if(pagePermission.canDelete){
isRecordConfirmationOpen.value = true
} else {
unauthorizedToast()
}
navigateTo(recItem.value.filePath, { external: true, open: { target: '_blank' } })
break
case ActionEvents.showEdit:
navigateTo({
name: 'rehab-encounter-id-document-upload-document_id-edit',
params: { id: encounterId, "document_id": recId.value },
})
break
case ActionEvents.showConfirmDelete:
isRecordConfirmationOpen.value = true
break
}
})