import type { Permission } from "~/models/role";

// Should we define the keys first?
// export type Keys = 'key1' | 'key2' | 'key3' | etc

export const permissions: Record<string, Record<string, Permission[]>> = {
  '/emergency/triage': {
    'emp|doc': ['C', 'R', 'U', 'D'],
    'emp|nur': ['C', 'R', 'U', 'D'],
  },
  '/emergency/triage/add': {
    'emp|doc': ['C', 'R', 'U', 'D'],
    'emp|nur': ['C', 'R', 'U', 'D'],
  },
  '/emergency/triage/[id]': {
    'emp|doc': ['C', 'R', 'U', 'D'],
    'emp|nur': ['C', 'R', 'U', 'D'],
  },
  '/emergency/triage/[id]/edit': {
    'emp|doc': ['C', 'R', 'U', 'D'],
    'emp|nur': ['C', 'R', 'U', 'D'],
  },
  '/emergency/encounter': {
    'emp|reg': ['C', 'R', 'U', 'D'],
    'emp|doc': ['R'],
    'emp|nur': ['R'],
    'emp|thr': ['R'],
    'emp|miw': ['R'],
    'emp|nut': ['R'],
    'emp|pha': ['R'],
    'emp|lab': ['R'],
    'emp|rad': ['R'],
  },
  '/emergency/encounter/add': {
    'emp|reg': ['C', 'R', 'U', 'D'],
  },
  '/emergency/encounter/[id]': {
    'emp|reg': ['C', 'R', 'U', 'D'],
    'emp|doc': ['R'],
    'emp|nur': ['R'],
    'emp|thr': ['R'],
    'emp|miw': ['R'],
    'emp|nut': ['R'],
    'emp|pha': ['R'],
    'emp|lab': ['R'],
    'emp|rad': ['R'],
  },
  '/emergency/encounter/[id]/edit': {
    'emp|reg': ['C', 'R', 'U', 'D'],
  },
  '/emergency/encounter/[id]/process': {
    'emp|doc': ['R', 'U'],
    'emp|nur': ['R', 'U'],
    'emp|thr': ['R', 'U'],
    'emp|miw': ['R', 'U'],
    'emp|nut': ['R', 'U'],
    'emp|pha': ['R', 'U'],
    'emp|lab': ['R', 'U'],
    'emp|rad': ['R', 'U'],
  },
  '/emergency/consulation': {
    'emp|doc': ['R'],
  },
  '/emergency/consulation/[id]/process': {
    'emp|doc': ['R', 'U'],
  },
}
