refactor(role): rename PagePermission to RoleAccesses and fix base model id

Update type name from PagePermission to RoleAccesses across multiple files for consistency
Change mock id value from -1 to 0 in base model to match backend constraints
Enable RBAC middleware and fix patient edit page permissions
This commit is contained in:
Khafid Prayoga
2025-12-08 18:57:35 +07:00
parent 1083bb5384
commit e967ee1cf0
7 changed files with 26 additions and 29 deletions
+1 -3
View File
@@ -19,9 +19,7 @@ export interface TreeItem {
export function genBase(): Base {
return {
// -1 buat mock data
// backend harusnya non-negative/ > 0 (untuk auto increment constraint) jadi harusnya aman ya
id: -1,
id: 0,
createdAt: '',
updatedAt: '',
}
+3 -3
View File
@@ -43,9 +43,9 @@ export interface Person extends Base {
export function genPerson(): Person {
return {
...genBase(),
frontTitle: '[MOCK] dr. ',
name: 'Agus Iwan Setiawan',
endTitle: 'Sp.Bo',
frontTitle: '',
name: '',
endTitle: '',
}
}