Something went wrong. Try again.
A functional toolkit for authoring resource-leveling algorithms — compose constraint and scoring blocks, enumerate feasible schedules
Something went wrong. Try again.
1234567891011121314151617181920import { z } from "zod";
import { NullableDurationSchema } from "./duration.ts";import { ResourceTypeSchema } from "./types.ts";
export const ResourceSchema = z.object({ id: z.nullable(z.number()), uniqueId: z.nullable(z.number()), name: z.nullable(z.string()), type: ResourceTypeSchema, email: z.nullable(z.string()), group: z.nullable(z.string()), maxUnits: z.nullable(z.number()), cost: z.nullable(z.number()), work: NullableDurationSchema, resourcePool: z.nullable(z.string()),});
export type Resource = z.infer<typeof ResourceSchema>;