51 lines
930 B
TypeScript
51 lines
930 B
TypeScript
import { i18n } from 'src/boot/lang';
|
|
import { ref } from 'vue';
|
|
|
|
export interface Permission {
|
|
name: string;
|
|
label: string;
|
|
permission: number;
|
|
}
|
|
|
|
export type Permissions = Permission[];
|
|
|
|
export const defaultPermissions = [
|
|
{
|
|
name: 'settings',
|
|
label: i18n.global.t('settings'),
|
|
permission: 0,
|
|
},
|
|
{
|
|
name: 'userSettings',
|
|
label: i18n.global.t('userSettings'),
|
|
permission: 0,
|
|
},
|
|
{
|
|
name: 'members',
|
|
label: i18n.global.t('members'),
|
|
permission: 0,
|
|
},
|
|
{
|
|
name: 'events',
|
|
label: i18n.global.t('events'),
|
|
permission: 0,
|
|
},
|
|
{
|
|
name: 'responsible',
|
|
label: i18n.global.t('responsible'),
|
|
permission: 0,
|
|
},
|
|
{
|
|
name: 'group',
|
|
label: i18n.global.t('group'),
|
|
permission: 0,
|
|
},
|
|
{
|
|
name: 'excursionTable',
|
|
label: i18n.global.t('excursionTable'),
|
|
permission: 0,
|
|
},
|
|
];
|
|
|
|
export const permissions = ref<Permissions>(defaultPermissions);
|