# vNext SC Models ## Vendor ```ts type Vendor = 'ARAMARK' | 'LEGENDS' | 'LEVY' | 'TEST' ``` ## Feature Flag ```ts type FeatureFlag = 'ENABLE_CASHIER_ASSIGNMENT' | 'SHOW_UNIFORM_COUNTS' ``` ## Venue ```ts interface Venue { // address?: Address // contacts?: Contact[] compliances: VenueCompliance[] defaultEventSettings: EventSettings // featureFlags: Record<FeatureFlag, boolean> name: string settings: VenueSetting // subscription: Subscription timeZone: string workerRoles: WorkerRole[] vendor: Vendor } ``` ## Venue Setting ```ts interface VenueSetting { complianceExpirationNotificationLeadTimeInDays: number eventStartTimeGranularityInMinutes: number } ``` ## Event Setting ```ts interface EventSettings { checkInWindowBufferInMinutes: { before: number after: number } gateTimeBeforeInMinutes: number } ``` ## Subscription ```ts interface Subscription { dateStart: Date dateEnd: Date contacts: Contact[] isActive: boolean } ``` ## Contact ```ts interface Contact { address?: Address givenName: string familyName: string email: string isActive: boolean phoneNumber: string salutation: string title: string tags: string[] // E.g. billing, hr } ``` ## Venue Compliance ```ts interface VenueCompliance { isRequiredToServeAlcohol: boolean isRequiredToServeFood: boolean isRequiredToWork: boolean key: ComplianceKey type: 'date' | 'string' | 'boolean' defaultValue?: ComplianceValue } ``` ## Address ```ts interface Address { line1: string line2?: string city: string state: string postalCode: string country: string latitude?: number longitude?: number } ``` ## Compliance Key ```ts type ComplianceKey = 'CRIMINAL_HISTORY_EXPIRATION_DATE' | 'HAS_SUBMITTED_VOLUNTEER_FORM' // etc ``` ## Worker Role ```ts interface WorkerRole { name: string requiredCompliances: ComplianceKey[] } ``` ### Location ```ts interface Location { name: string key: string capabilities: Record<'servesAlcohol' | 'isPortable', boolean> locations?: Location[] roleCapacities: RoleCapacity[] tags: string[] // zone, east, alcohol... anything to make filtering/grouping easier } ``` ## Role Capacity ```ts interface RoleCapacity { role: WorkerRole maxCapacity: number } ``` ## Event ```ts interface Event { name: string type: EventType settings: EventSettings startDate: Date endDate: Date checkInStartDate: Date checkInEndDate: Date gateDate: Date } ``` ## Organization ```ts interface Organization { name: string type: OrganizationType key: string isActive: boolean administrators: Worker[] workers: Worker[] complianceGrade: number contacts: Contact[] tags?: string[] } ``` ## Worker ```ts interface Worker { givenName: string familyName: string email?: string isActive: boolean isLocationLeader: boolean defaultRole?: WorkerRole uniformSize?: string compliances: Compliance[] tags?: string[] } ``` ## Compliance Value ```ts type ComplianceValue = string | boolean | Date ``` ## Compliance ```ts interface Compliance { key: ComplianceKey value: ComplianceValue } ``` ## Account ```ts interface Account { username: string roles: Role[] // super admin, venue admin, venue user, organization admin, worker worker: Worker } ``` ## Placement ```ts interface Placement { event: Event location: Location checkInDate?: Date role: WorkerRole roleAssignment?: number worker: Worker } ```
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up