1
0
Fork 0

chore(db): register migrations and regenerate schema/types

This commit is contained in:
Jason Fraley 2026-09-30 14:50:40 -04:00
parent f8f09057bc
commit 4224096b62
3 changed files with 1129 additions and 132 deletions

View file

@ -90,6 +90,10 @@ import * as migration_20260923_200000_add_missing_role_permission_enum_values fr
import * as migration_20260923_202700_add_form_builder_collections from './20260923_202700_add_form_builder_collections';
import * as migration_20260924_205400_add_story_beat_voiceover from './20260924_205400_add_story_beat_voiceover';
import * as migration_20260924_212353_add_story_voiceover_ai_generated from './20260924_212353_add_story_voiceover_ai_generated';
import * as migration_20260925_235150_add_mission_role_signups from './20260925_235150_add_mission_role_signups';
import * as migration_20260926_030859_add_mission_role_description from './20260926_030859_add_mission_role_description';
import * as migration_20260926_044319_add_mission_role_description_richtext from './20260926_044319_add_mission_role_description_richtext';
import * as migration_20260928_021138_change_ai_model from './20260928_021138_change_ai_model';
export const migrations = [
{
@ -550,6 +554,26 @@ export const migrations = [
{
up: migration_20260924_212353_add_story_voiceover_ai_generated.up,
down: migration_20260924_212353_add_story_voiceover_ai_generated.down,
name: '20260924_212353_add_story_voiceover_ai_generated'
name: '20260924_212353_add_story_voiceover_ai_generated',
},
{
up: migration_20260925_235150_add_mission_role_signups.up,
down: migration_20260925_235150_add_mission_role_signups.down,
name: '20260925_235150_add_mission_role_signups',
},
{
up: migration_20260926_030859_add_mission_role_description.up,
down: migration_20260926_030859_add_mission_role_description.down,
name: '20260926_030859_add_mission_role_description',
},
{
up: migration_20260926_044319_add_mission_role_description_richtext.up,
down: migration_20260926_044319_add_mission_role_description_richtext.down,
name: '20260926_044319_add_mission_role_description_richtext',
},
{
up: migration_20260928_021138_change_ai_model.up,
down: migration_20260928_021138_change_ai_model.down,
name: '20260928_021138_change_ai_model'
},
];

File diff suppressed because it is too large Load diff

View file

@ -91,6 +91,7 @@ export interface Config {
'ribbon-submissions': RibbonSubmission;
missions: Mission;
'mission-attendances': MissionAttendance;
'mission-role-signups': MissionRoleSignup;
campaigns: Campaign;
factions: Faction;
technologies: Technology;
@ -183,6 +184,7 @@ export interface Config {
'ribbon-submissions': RibbonSubmissionsSelect<false> | RibbonSubmissionsSelect<true>;
missions: MissionsSelect<false> | MissionsSelect<true>;
'mission-attendances': MissionAttendancesSelect<false> | MissionAttendancesSelect<true>;
'mission-role-signups': MissionRoleSignupsSelect<false> | MissionRoleSignupsSelect<true>;
campaigns: CampaignsSelect<false> | CampaignsSelect<true>;
factions: FactionsSelect<false> | FactionsSelect<true>;
technologies: TechnologiesSelect<false> | TechnologiesSelect<true>;
@ -461,6 +463,7 @@ export interface User {
| 'poker:everyone-left'
| 'blackjack:force-ended'
| 'blackjack:everyone-left'
| 'mission:role-promoted'
)[]
| null;
};
@ -497,6 +500,7 @@ export interface User {
| 'poker:everyone-left'
| 'blackjack:force-ended'
| 'blackjack:everyone-left'
| 'mission:role-promoted'
)[]
| null;
};
@ -631,6 +635,11 @@ export interface Role {
| 'mission-attendances:update'
| 'mission-attendances:delete'
| 'admin:mission-attendances:manage'
| 'mission-role-signups:create'
| 'mission-role-signups:read'
| 'mission-role-signups:update'
| 'mission-role-signups:delete'
| 'admin:mission-role-signups:manage'
| 'campaigns:create'
| 'campaigns:read'
| 'campaigns:update'
@ -771,12 +780,16 @@ export interface Role {
| 'maps:read'
| 'maps:update'
| 'maps:delete'
| 'maps:place'
| 'admin:maps:manage'
| 'map-roads:read'
| 'map-roads:author'
| 'admin:map-roads:manage'
| 'map-zones:read'
| 'map-zones:author'
| 'admin:map-zones:manage'
| 'resource-nodes:read'
| 'resource-nodes:author'
| 'admin:resource-nodes:manage'
| 'narrative-events:create'
| 'narrative-events:read'
@ -2948,6 +2961,24 @@ export interface Mission {
providedRoles?:
| {
roleName: string;
/**
* Shown to players under the role name: what the role does and what is expected of whoever fills it.
*/
description?: {
root: {
type: string;
children: {
type: any;
version: number;
[k: string]: unknown;
}[];
direction: ('ltr' | 'rtl') | null;
format: 'left' | 'start' | 'center' | 'right' | 'end' | 'justify' | '';
indent: number;
version: number;
};
[k: string]: unknown;
} | null;
/**
* If true, this mission cannot be executed without someone fulfilling this role.
*/
@ -2960,6 +2991,10 @@ export interface Mission {
* This role can only be fulfilled by someone of this rank or higher.
*/
minimumRank?: (number | null) | Rank;
/**
* How many members can hold this role. Extra sign-ups form a first-come, first-served waitlist that auto-promotes when a holder stops attending.
*/
slots?: number | null;
id?: string | null;
}[]
| null;
@ -3208,6 +3243,25 @@ export interface MissionAttendance {
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "mission-role-signups".
*/
export interface MissionRoleSignup {
id: number;
mission: number | Mission;
user: number | User;
/**
* Index into the mission's missionRoles.providedRoles array. A roleName snapshot is kept alongside in case the mission's role list is later edited.
*/
roleIndex: number;
/**
* Copy of the role name at sign-up time, for display if the role list changes.
*/
roleNameSnapshot?: string | null;
updatedAt: string;
createdAt: string;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "shipments".
@ -5146,7 +5200,7 @@ export interface PluginAiInstruction {
*/
'field-type'?: ('text' | 'textarea' | 'upload' | 'richText') | null;
'relation-to'?: string | null;
'model-id'?: 'unsloth-text' | null;
'model-id'?: 'unsloth/gemma-4-26B-A4B-it-qat-GGUF' | null;
/**
* Please reload your collection after applying the changes
*/
@ -5166,7 +5220,7 @@ export interface PluginAiInstruction {
| null;
system?: string | null;
layout?: string | null;
'unsloth-text-settings'?: {
'gemma-4-settings'?: {
model?: string | null;
};
updatedAt: string;
@ -5606,6 +5660,24 @@ export interface PayloadMcpApiKey {
*/
delete?: boolean | null;
};
missionRoleSignups?: {
/**
* Allow clients to find mission-role-signups.
*/
find?: boolean | null;
/**
* Allow clients to create mission-role-signups.
*/
create?: boolean | null;
/**
* Allow clients to update mission-role-signups.
*/
update?: boolean | null;
/**
* Allow clients to delete mission-role-signups.
*/
delete?: boolean | null;
};
campaigns?: {
/**
* Allow clients to find campaigns.
@ -6647,6 +6719,10 @@ export interface PayloadLockedDocument {
relationTo: 'mission-attendances';
value: number | MissionAttendance;
} | null)
| ({
relationTo: 'mission-role-signups';
value: number | MissionRoleSignup;
} | null)
| ({
relationTo: 'campaigns';
value: number | Campaign;
@ -7607,9 +7683,11 @@ export interface MissionsSelect<T extends boolean = true> {
| T
| {
roleName?: T;
description?: T;
missionCritical?: T;
requiredMos?: T;
minimumRank?: T;
slots?: T;
id?: T;
};
notes?: T;
@ -7699,6 +7777,18 @@ export interface MissionAttendancesSelect<T extends boolean = true> {
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "mission-role-signups_select".
*/
export interface MissionRoleSignupsSelect<T extends boolean = true> {
mission?: T;
user?: T;
roleIndex?: T;
roleNameSnapshot?: T;
updatedAt?: T;
createdAt?: T;
}
/**
* This interface was referenced by `Config`'s JSON-Schema
* via the `definition` "campaigns_select".
@ -9191,7 +9281,7 @@ export interface PluginAiInstructionsSelect<T extends boolean = true> {
};
system?: T;
layout?: T;
'unsloth-text-settings'?:
'gemma-4-settings'?:
| T
| {
model?: T;
@ -9391,6 +9481,14 @@ export interface PayloadMcpApiKeysSelect<T extends boolean = true> {
update?: T;
delete?: T;
};
missionRoleSignups?:
| T
| {
find?: T;
create?: T;
update?: T;
delete?: T;
};
campaigns?:
| T
| {