Add /staff/:id/roles

This commit is contained in:
Zoe Roux
2025-03-09 21:17:38 +01:00
parent 7e6592fa2e
commit cba47ca346
2 changed files with 144 additions and 2 deletions
+17
View File
@@ -1,4 +1,5 @@
import { t } from "elysia";
import { Show } from "./show";
import { DbMetadata, ExternalId, Image, Resource } from "./utils";
export const Character = t.Object({
@@ -32,3 +33,19 @@ export const Staff = t.Intersect([
DbMetadata,
]);
export type Staff = typeof Staff.static;
export const RoleWShow = t.Intersect([
Role,
t.Object({
show: Show,
}),
]);
export type RoleWShow = typeof RoleWShow.static;
export const RoleWStaff = t.Intersect([
Role,
t.Object({
staff: Staff
}),
]);
export type RoleWStaff = typeof RoleWStaff.static;