@happyvertical/smrt-events 0.55.6 → 0.55.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { a as formatEventDateRange, c as isEventNow, d as validateEventStatus, f as expandRecurrence, h as toZonedWallTime, i as formatDuration, l as parseRecurrencePattern, m as isValidTimeZone, n as calculateNextOccurrence, o as generateEventSlug, p as fromZonedWallTime, r as checkSchedulingConflict, s as getEventStatusFromDates, t as calculateDuration, u as sortEventsByDate } from "./chunks/utils-DV00CoDY.js";
2
2
  import { EVENTS_MODULE_META, EVENTS_UI_SLOTS } from "./ui.js";
3
- import { ObjectRegistry, SmrtCollection, SmrtHierarchical, SmrtJunction, SmrtObject, crossPackageRef, field, foreignKey, resolveDatabase, smrt } from "@happyvertical/smrt-core";
3
+ import { ObjectRegistry, SmrtCollection, SmrtHierarchical, SmrtJunction, SmrtObject, SmrtRecipe, crossPackageRef, field, foreignKey, resolveDatabase, smrt } from "@happyvertical/smrt-core";
4
4
  import { ICAL, parseICalendar } from "@happyvertical/icalendar";
5
5
  import { createHash } from "node:crypto";
6
6
  import { TenantScoped, getTenantId, queryGlobal, queryWithGlobals, tenantId } from "@happyvertical/smrt-tenancy";
@@ -18,7 +18,7 @@ var __exportAll = (all, no_symbols) => {
18
18
  };
19
19
  //#endregion
20
20
  //#region src/__smrt-register__.ts
21
- ObjectRegistry.registerPackageManifest(JSON.parse(`{"version":"1.0.0","timestamp":0,"packageName":"@happyvertical/smrt-events","packageVersion":"0.55.6","objects":{"@happyvertical/smrt-events:EventAssetCollection":{"name":"eventassetcollection","className":"EventAssetCollection","qualifiedName":"@happyvertical/smrt-events:EventAssetCollection","collection":"eventassets","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventAssetCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"byRight":{"name":"byRight","async":true,"parameters":[{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<TItem[]>","isStatic":false,"isPublic":true},"byLeft":{"name":"byLeft","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<TItem[]>","isStatic":false,"isPublic":true},"attach":{"name":"attach","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionAttachOptions","optional":true}],"returnType":"Promise<TItem>","isStatic":false,"isPublic":true},"detach":{"name":"detach","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"setLinks":{"name":"setLinks","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightIds","type":"string[]","optional":false},{"name":"opts","type":"JunctionAttachOptions","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"getAssets":{"name":"getAssets","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<Asset[]>","isStatic":false,"isPublic":true},"addAsset":{"name":"addAsset","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"asset","type":"Asset","optional":false},{"name":"relationship","type":"any","optional":true,"default":"attachment"},{"name":"sortOrder","type":"any","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"removeAsset":{"name":"removeAsset","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"assetId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true}},"decoratorConfig":{"api":false,"mcp":false,"cli":false,"tableName":"event_assets"},"extends":"SmrtJunction","extendsTypeArg":"EventAsset","exportName":"EventAssetCollection","collectionExportName":"EventAssetCollectionCollection","schema":{"tableName":"event_assets","ddl":"CREATE TABLE IF NOT EXISTS \\"event_assets\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"event_id\\" UUID NOT NULL,\\n \\"asset_id\\" UUID NOT NULL,\\n \\"relationship\\" TEXT NOT NULL,\\n \\"sort_order\\" INTEGER NOT NULL DEFAULT 0\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false,"unique":false},"event_id":{"type":"UUID","referenceKind":"foreignKey","notNull":true,"unique":false,"foreignKey":{"table":"events","column":"id","onDelete":"CASCADE","onUpdate":"CASCADE"}},"asset_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":true,"unique":false},"relationship":{"type":"TEXT","notNull":true,"unique":false},"sort_order":{"type":"INTEGER","notNull":true,"unique":false,"default":0}},"indexes":[{"name":"event_assets_event_id_asset_id_idx","columns":["event_id","asset_id","relationship"],"unique":true},{"name":"event_assets_slug_context_idx","columns":["slug","context"]},{"name":"event_assets_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_assets_asset_id_idx","columns":["asset_id"]}],"version":"aeebedc6"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventCollection":{"name":"eventcollection","className":"EventCollection","qualifiedName":"@happyvertical/smrt-events:EventCollection","collection":"events","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"getBySeriesId":{"name":"getBySeriesId","async":true,"parameters":[{"name":"seriesId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByPlace":{"name":"getByPlace","async":true,"parameters":[{"name":"placeId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByDateRange":{"name":"getByDateRange","async":true,"parameters":[{"name":"startDate","type":"Date","optional":false},{"name":"endDate","type":"Date","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getUpcoming":{"name":"getUpcoming","async":true,"parameters":[{"name":"limit","type":"number","optional":true}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByStatus":{"name":"getByStatus","async":true,"parameters":[{"name":"status","type":"EventStatus","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByType":{"name":"getByType","async":true,"parameters":[{"name":"typeId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getRootEvents":{"name":"getRootEvents","async":true,"parameters":[],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByParent":{"name":"getByParent","async":true,"parameters":[{"name":"parentId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getEventTree":{"name":"getEventTree","async":true,"parameters":[{"name":"eventId","type":"string","optional":false}],"returnType":"Promise<Event | null>","isStatic":false,"isPublic":true},"getAssets":{"name":"getAssets","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<Asset[]>","isStatic":false,"isPublic":true},"addAsset":{"name":"addAsset","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"asset","type":"Asset","optional":false},{"name":"relationship","type":"any","optional":true,"default":"attachment"},{"name":"sortOrder","type":"any","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"removeAsset":{"name":"removeAsset","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"assetId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"search":{"name":"search","async":true,"parameters":[{"name":"query","type":"string","optional":false},{"name":"filters","type":"EventSearchFilters","optional":true}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getInProgress":{"name":"getInProgress","async":true,"parameters":[],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"findByTenant":{"name":"findByTenant","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"findGlobal":{"name":"findGlobal","async":true,"parameters":[],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"findWithGlobals":{"name":"findWithGlobals","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true}},"decoratorConfig":{},"extends":"SmrtCollection","extendsTypeArg":"Event","exportName":"EventCollection","collectionExportName":"EventCollectionCollection","schema":{"tableName":"events","ddl":"CREATE TABLE IF NOT EXISTS \\"events\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"parent_id\\" UUID,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"series_id\\" UUID,\\n \\"type_id\\" UUID,\\n \\"place_id\\" UUID,\\n \\"description\\" TEXT,\\n \\"start_date\\" TIMESTAMP,\\n \\"end_date\\" TIMESTAMP,\\n \\"all_day\\" BOOLEAN DEFAULT FALSE,\\n \\"time_zone\\" TEXT,\\n \\"status\\" TEXT DEFAULT 'scheduled',\\n \\"round\\" INTEGER,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"parent_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"events","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"series_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_series","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"type_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_types","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"place_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false},"description":{"type":"TEXT","notNull":false},"start_date":{"type":"TIMESTAMP","notNull":false},"end_date":{"type":"TIMESTAMP","notNull":false},"all_day":{"type":"BOOLEAN","notNull":false,"default":false},"time_zone":{"type":"TEXT","notNull":false},"status":{"type":"TEXT","notNull":false,"default":"scheduled"},"round":{"type":"INTEGER","notNull":false},"metadata":{"type":"TEXT","notNull":false},"external_id":{"type":"TEXT","notNull":false},"source":{"type":"TEXT","notNull":false}},"indexes":[{"name":"events_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"events_meta_type_idx","columns":["_meta_type"]},{"name":"events_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"events_parent_id_idx","columns":["parent_id"]},{"name":"events_series_id_idx","columns":["series_id"]},{"name":"events_type_id_idx","columns":["type_id"]},{"name":"events_place_id_idx","columns":["place_id"]}],"version":"8e689646"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventParticipantCollection":{"name":"eventparticipantcollection","className":"EventParticipantCollection","qualifiedName":"@happyvertical/smrt-events:EventParticipantCollection","collection":"eventparticipants","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventParticipantCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"byRight":{"name":"byRight","async":true,"parameters":[{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<TItem[]>","isStatic":false,"isPublic":true},"byLeft":{"name":"byLeft","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<TItem[]>","isStatic":false,"isPublic":true},"attach":{"name":"attach","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionAttachOptions","optional":true}],"returnType":"Promise<TItem>","isStatic":false,"isPublic":true},"detach":{"name":"detach","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"setLinks":{"name":"setLinks","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightIds","type":"string[]","optional":false},{"name":"opts","type":"JunctionAttachOptions","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"getByPlacement":{"name":"getByPlacement","async":true,"parameters":[{"name":"eventId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"getByGroup":{"name":"getByGroup","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"groupId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"getHome":{"name":"getHome","async":true,"parameters":[{"name":"eventId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"getAway":{"name":"getAway","async":true,"parameters":[{"name":"eventId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"search":{"name":"search","async":true,"parameters":[{"name":"filters","type":"ParticipantSearchFilters","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"getParticipantStats":{"name":"getParticipantStats","async":true,"parameters":[{"name":"profileId","type":"string","optional":false},{"name":"eventTypeId","type":"string","optional":true}],"returnType":"Promise<object>","isStatic":false,"isPublic":true},"findByTenant":{"name":"findByTenant","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"findGlobal":{"name":"findGlobal","async":true,"parameters":[],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"findWithGlobals":{"name":"findWithGlobals","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true}},"decoratorConfig":{},"extends":"SmrtJunction","extendsTypeArg":"EventParticipant","exportName":"EventParticipantCollection","collectionExportName":"EventParticipantCollectionCollection","schema":{"tableName":"event_participants","ddl":"CREATE TABLE IF NOT EXISTS \\"event_participants\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"event_id\\" UUID,\\n \\"profile_id\\" UUID,\\n \\"role\\" TEXT DEFAULT '',\\n \\"placement\\" INTEGER,\\n \\"group_id\\" TEXT,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false,"unique":false},"event_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"unique":false,"foreignKey":{"table":"events","column":"id","onDelete":"CASCADE","onUpdate":"CASCADE"}},"profile_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false,"unique":false},"role":{"type":"TEXT","notNull":false,"unique":false,"default":""},"placement":{"type":"INTEGER","notNull":false,"unique":false},"group_id":{"type":"TEXT","notNull":false,"unique":false},"metadata":{"type":"TEXT","notNull":false,"unique":false},"external_id":{"type":"TEXT","notNull":false,"unique":false},"source":{"type":"TEXT","notNull":false,"unique":false}},"indexes":[{"name":"event_participants_event_id_profile_id_idx","columns":["event_id","profile_id","role"],"unique":true,"nullsNotDistinct":true},{"name":"event_participants_slug_context_idx","columns":["slug","context"]},{"name":"event_participants_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_participants_profile_id_idx","columns":["profile_id"]}],"version":"c2faac84"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventSeriesCollection":{"name":"eventseriescollection","className":"EventSeriesCollection","qualifiedName":"@happyvertical/smrt-events:EventSeriesCollection","collection":"eventserieses","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventSeriesCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"getByOrganizer":{"name":"getByOrganizer","async":true,"parameters":[{"name":"organizerId","type":"string","optional":false}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"getActive":{"name":"getActive","async":true,"parameters":[],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"getUpcoming":{"name":"getUpcoming","async":true,"parameters":[{"name":"limit","type":"number","optional":true}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"getByType":{"name":"getByType","async":true,"parameters":[{"name":"typeId","type":"string","optional":false}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"search":{"name":"search","async":true,"parameters":[{"name":"query","type":"string","optional":false},{"name":"filters","type":"EventSeriesSearchFilters","optional":true}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"findByTenant":{"name":"findByTenant","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"findGlobal":{"name":"findGlobal","async":true,"parameters":[],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"findWithGlobals":{"name":"findWithGlobals","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true}},"decoratorConfig":{},"extends":"SmrtCollection","extendsTypeArg":"EventSeries","exportName":"EventSeriesCollection","collectionExportName":"EventSeriesCollectionCollection","schema":{"tableName":"event_series","ddl":"CREATE TABLE IF NOT EXISTS \\"event_series\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"type_id\\" UUID,\\n \\"organizer_id\\" UUID,\\n \\"description\\" TEXT,\\n \\"start_date\\" TIMESTAMP,\\n \\"end_date\\" TIMESTAMP,\\n \\"recurrence\\" TEXT,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"type_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_types","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE"}},"organizer_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false},"description":{"type":"TEXT","notNull":false},"start_date":{"type":"TIMESTAMP","notNull":false},"end_date":{"type":"TIMESTAMP","notNull":false},"recurrence":{"type":"TEXT","notNull":false},"metadata":{"type":"TEXT","notNull":false},"external_id":{"type":"TEXT","notNull":false},"source":{"type":"TEXT","notNull":false}},"indexes":[{"name":"event_series_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"event_series_meta_type_idx","columns":["_meta_type"]},{"name":"event_series_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_series_type_id_idx","columns":["type_id"]},{"name":"event_series_organizer_id_idx","columns":["organizer_id"]}],"version":"c79f5863"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventTypeCollection":{"name":"eventtypecollection","className":"EventTypeCollection","qualifiedName":"@happyvertical/smrt-events:EventTypeCollection","collection":"eventtypes","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventTypeCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"getOrCreate":{"name":"getOrCreate","async":true,"parameters":[{"name":"slug","type":"string","optional":false},{"name":"name","type":"string","optional":true}],"returnType":"Promise<EventType>","isStatic":false,"isPublic":true},"getBySlug":{"name":"getBySlug","async":true,"parameters":[{"name":"slug","type":"string","optional":false}],"returnType":"Promise<EventType | null>","isStatic":false,"isPublic":true},"initializeDefaults":{"name":"initializeDefaults","async":true,"parameters":[],"returnType":"Promise<EventType[]>","isStatic":false,"isPublic":true},"findByTenant":{"name":"findByTenant","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventType[]>","isStatic":false,"isPublic":true},"findGlobal":{"name":"findGlobal","async":true,"parameters":[],"returnType":"Promise<EventType[]>","isStatic":false,"isPublic":true},"findWithGlobals":{"name":"findWithGlobals","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventType[]>","isStatic":false,"isPublic":true}},"decoratorConfig":{},"extends":"SmrtCollection","extendsTypeArg":"EventType","exportName":"EventTypeCollection","collectionExportName":"EventTypeCollectionCollection","schema":{"tableName":"event_types","ddl":"CREATE TABLE IF NOT EXISTS \\"event_types\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"description\\" TEXT DEFAULT '',\\n \\"schema\\" TEXT DEFAULT '',\\n \\"participant_schema\\" TEXT DEFAULT ''\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"description":{"type":"TEXT","notNull":false,"default":""},"schema":{"type":"TEXT","notNull":false,"default":""},"participant_schema":{"type":"TEXT","notNull":false,"default":""}},"indexes":[{"name":"event_types_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"event_types_meta_type_idx","columns":["_meta_type"]},{"name":"event_types_tenant_id_created_at_idx","columns":["tenant_id","created_at"]}],"version":"922ae3b0"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:Event":{"name":"event","className":"Event","qualifiedName":"@happyvertical/smrt-events:Event","collection":"events","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/Event.ts","packageName":"@happyvertical/smrt-events","fields":{"created_at":{"type":"datetime","required":false},"updated_at":{"type":"datetime","required":false},"parentId":{"type":"foreignKey","required":false,"related":"Event","_meta":{"nullable":true,"constraint":{"engines":["postgres","sqlite"]}}},"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"name":{"type":"text","required":false,"default":""},"seriesId":{"type":"foreignKey","required":false,"related":"EventSeries","_meta":{"constraint":{"engines":["postgres","sqlite"]}}},"typeId":{"type":"foreignKey","required":false,"related":"EventType","_meta":{"constraint":{"engines":["postgres","sqlite"]}}},"placeId":{"type":"crossPackageRef","required":false,"related":"@happyvertical/smrt-places:Place"},"description":{"type":"text","required":false},"startDate":{"type":"datetime","required":false},"endDate":{"type":"datetime","required":false},"allDay":{"type":"boolean","required":false,"default":false},"timeZone":{"type":"text","required":false},"status":{"type":"text","required":false,"default":"scheduled","enum":["scheduled","in_progress","completed","cancelled","postponed"]},"round":{"type":"integer","required":false},"metadata":{"type":"text","required":false},"externalId":{"type":"text","required":false},"source":{"type":"text","required":false},"createdAt":{"type":"text","required":false},"updatedAt":{"type":"text","required":false}},"methods":{"getParent":{"name":"getParent","async":true,"parameters":[],"returnType":"Promise<this | null>","isStatic":false,"isPublic":true},"getChildren":{"name":"getChildren","async":true,"parameters":[],"returnType":"Promise<this[]>","isStatic":false,"isPublic":true},"getAncestors":{"name":"getAncestors","async":true,"parameters":[],"returnType":"Promise<this[]>","isStatic":false,"isPublic":true},"getDescendants":{"name":"getDescendants","async":true,"parameters":[],"returnType":"Promise<this[]>","isStatic":false,"isPublic":true},"getHierarchy":{"name":"getHierarchy","async":true,"parameters":[],"returnType":"Promise<HierarchyView<this>>","isStatic":false,"isPublic":true},"moveTo":{"name":"moveTo","async":true,"parameters":[{"name":"newParent","type":"this | string | null","optional":false,"unionBranches":[{"type":"this"},{"type":"string"},{"type":"null"}]}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"getMetadata":{"name":"getMetadata","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setMetadata":{"name":"setMetadata","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"updateMetadata":{"name":"updateMetadata","async":false,"parameters":[{"name":"updates","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"updateStatus":{"name":"updateStatus","async":true,"parameters":[{"name":"newStatus","type":"EventStatus","optional":false}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"getSeries":{"name":"getSeries","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getType":{"name":"getType","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getPlace":{"name":"getPlace","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getRootEvent":{"name":"getRootEvent","async":true,"parameters":[],"returnType":"Promise<Event>","isStatic":false,"isPublic":true},"getParticipants":{"name":"getParticipants","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getAssets":{"name":"getAssets","async":true,"parameters":[{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<Asset[]>","isStatic":false,"isPublic":true},"addAsset":{"name":"addAsset","async":true,"parameters":[{"name":"asset","type":"Asset","optional":false},{"name":"relationship","type":"any","optional":true,"default":"attachment"},{"name":"sortOrder","type":"any","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"removeAsset":{"name":"removeAsset","async":true,"parameters":[{"name":"assetId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"isInProgress":{"name":"isInProgress","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true},"isRoot":{"name":"isRoot","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true}},"decoratorConfig":{"tableStrategy":"sti","api":{"include":["list","get","create","update","delete"]},"mcp":{"include":["list","get","create","update"]},"cli":{"skipApiCheck":true},"tenantScoped":{"mode":"optional"},"conflictColumns":["tenant_id","slug","context","_meta_type"]},"extends":"SmrtHierarchical","exportName":"Event","collectionExportName":"EventCollection","displayLabelField":"name","schema":{"tableName":"events","ddl":"CREATE TABLE IF NOT EXISTS \\"events\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"parent_id\\" UUID,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"series_id\\" UUID,\\n \\"type_id\\" UUID,\\n \\"place_id\\" UUID,\\n \\"description\\" TEXT,\\n \\"start_date\\" TIMESTAMP,\\n \\"end_date\\" TIMESTAMP,\\n \\"all_day\\" BOOLEAN DEFAULT FALSE,\\n \\"time_zone\\" TEXT,\\n \\"status\\" TEXT DEFAULT 'scheduled',\\n \\"round\\" INTEGER,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"parent_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"events","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"series_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_series","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"type_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_types","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"place_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false},"description":{"type":"TEXT","notNull":false},"start_date":{"type":"TIMESTAMP","notNull":false},"end_date":{"type":"TIMESTAMP","notNull":false},"all_day":{"type":"BOOLEAN","notNull":false,"default":false},"time_zone":{"type":"TEXT","notNull":false},"status":{"type":"TEXT","notNull":false,"default":"scheduled"},"round":{"type":"INTEGER","notNull":false},"metadata":{"type":"TEXT","notNull":false},"external_id":{"type":"TEXT","notNull":false},"source":{"type":"TEXT","notNull":false}},"indexes":[{"name":"events_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"events_meta_type_idx","columns":["_meta_type"]},{"name":"events_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"events_parent_id_idx","columns":["parent_id"]},{"name":"events_series_id_idx","columns":["series_id"]},{"name":"events_type_id_idx","columns":["type_id"]},{"name":"events_place_id_idx","columns":["place_id"]}],"version":"8e689646"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventAsset":{"name":"eventasset","className":"EventAsset","qualifiedName":"@happyvertical/smrt-events:EventAsset","collection":"eventassets","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/EventAsset.ts","packageName":"@happyvertical/smrt-events","fields":{"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"eventId":{"type":"foreignKey","required":true,"related":"Event","_meta":{"required":true}},"assetId":{"type":"crossPackageRef","required":true,"related":"@happyvertical/smrt-assets:Asset"},"relationship":{"type":"text","required":true,"_meta":{"required":true}},"sortOrder":{"type":"integer","required":true,"default":0}},"methods":{},"decoratorConfig":{"tableName":"event_assets","conflictColumns":["event_id","asset_id","relationship"],"api":false,"mcp":false,"cli":false,"tenantScoped":{"mode":"optional"}},"extends":"SmrtObject","exportName":"EventAsset","collectionExportName":"EventAssetCollection","validationRules":[{"field":"eventId","rule":"required","fieldType":"foreignKey"},{"field":"assetId","rule":"required","fieldType":"crossPackageRef"},{"field":"relationship","rule":"required","fieldType":"text"},{"field":"sortOrder","rule":"required","fieldType":"integer"}],"schema":{"tableName":"event_assets","ddl":"CREATE TABLE IF NOT EXISTS \\"event_assets\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"event_id\\" UUID NOT NULL,\\n \\"asset_id\\" UUID NOT NULL,\\n \\"relationship\\" TEXT NOT NULL,\\n \\"sort_order\\" INTEGER NOT NULL DEFAULT 0\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false,"unique":false},"event_id":{"type":"UUID","referenceKind":"foreignKey","notNull":true,"unique":false,"foreignKey":{"table":"events","column":"id","onDelete":"CASCADE","onUpdate":"CASCADE"}},"asset_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":true,"unique":false},"relationship":{"type":"TEXT","notNull":true,"unique":false},"sort_order":{"type":"INTEGER","notNull":true,"unique":false,"default":0}},"indexes":[{"name":"event_assets_event_id_asset_id_idx","columns":["event_id","asset_id","relationship"],"unique":true},{"name":"event_assets_slug_context_idx","columns":["slug","context"]},{"name":"event_assets_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_assets_asset_id_idx","columns":["asset_id"]}],"version":"aeebedc6"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventParticipant":{"name":"eventparticipant","className":"EventParticipant","qualifiedName":"@happyvertical/smrt-events:EventParticipant","collection":"eventparticipants","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/EventParticipant.ts","packageName":"@happyvertical/smrt-events","fields":{"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"eventId":{"type":"foreignKey","required":false,"related":"Event"},"profileId":{"type":"crossPackageRef","required":false,"related":"@happyvertical/smrt-profiles:Profile"},"role":{"type":"text","required":false,"default":""},"placement":{"type":"integer","required":false},"groupId":{"type":"text","required":false},"metadata":{"type":"text","required":false},"externalId":{"type":"text","required":false},"source":{"type":"text","required":false},"createdAt":{"type":"text","required":false},"updatedAt":{"type":"text","required":false}},"methods":{"getMetadata":{"name":"getMetadata","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setMetadata":{"name":"setMetadata","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"updateMetadata":{"name":"updateMetadata","async":false,"parameters":[{"name":"updates","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getEvent":{"name":"getEvent","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getProfile":{"name":"getProfile","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getGroupParticipants":{"name":"getGroupParticipants","async":true,"parameters":[],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"isHome":{"name":"isHome","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true},"isAway":{"name":"isAway","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true}},"decoratorConfig":{"conflictColumns":["event_id","profile_id","role"],"api":{"include":["list","get","create","update","delete"]},"mcp":{"include":["list","get","create","update"]},"cli":{"skipApiCheck":true},"tenantScoped":{"mode":"optional"}},"extends":"SmrtObject","exportName":"EventParticipant","collectionExportName":"EventParticipantCollection","schema":{"tableName":"event_participants","ddl":"CREATE TABLE IF NOT EXISTS \\"event_participants\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"event_id\\" UUID,\\n \\"profile_id\\" UUID,\\n \\"role\\" TEXT DEFAULT '',\\n \\"placement\\" INTEGER,\\n \\"group_id\\" TEXT,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false,"unique":false},"event_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"unique":false,"foreignKey":{"table":"events","column":"id","onDelete":"CASCADE","onUpdate":"CASCADE"}},"profile_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false,"unique":false},"role":{"type":"TEXT","notNull":false,"unique":false,"default":""},"placement":{"type":"INTEGER","notNull":false,"unique":false},"group_id":{"type":"TEXT","notNull":false,"unique":false},"metadata":{"type":"TEXT","notNull":false,"unique":false},"external_id":{"type":"TEXT","notNull":false,"unique":false},"source":{"type":"TEXT","notNull":false,"unique":false}},"indexes":[{"name":"event_participants_event_id_profile_id_idx","columns":["event_id","profile_id","role"],"unique":true,"nullsNotDistinct":true},{"name":"event_participants_slug_context_idx","columns":["slug","context"]},{"name":"event_participants_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_participants_profile_id_idx","columns":["profile_id"]}],"version":"c2faac84"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventSeries":{"name":"eventseries","className":"EventSeries","qualifiedName":"@happyvertical/smrt-events:EventSeries","collection":"eventserieses","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/EventSeries.ts","packageName":"@happyvertical/smrt-events","fields":{"created_at":{"type":"datetime","required":false},"updated_at":{"type":"datetime","required":false},"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"name":{"type":"text","required":false,"default":""},"typeId":{"type":"foreignKey","required":false,"related":"EventType"},"organizerId":{"type":"crossPackageRef","required":false,"related":"@happyvertical/smrt-profiles:Profile"},"description":{"type":"text","required":false},"startDate":{"type":"datetime","required":false},"endDate":{"type":"datetime","required":false},"recurrence":{"type":"text","required":false},"metadata":{"type":"text","required":false},"externalId":{"type":"text","required":false},"source":{"type":"text","required":false},"createdAt":{"type":"text","required":false},"updatedAt":{"type":"text","required":false}},"methods":{"getRecurrence":{"name":"getRecurrence","async":false,"parameters":[],"returnType":"RecurrencePattern | null","isStatic":false,"isPublic":true},"setRecurrence":{"name":"setRecurrence","async":false,"parameters":[{"name":"pattern","type":"RecurrencePattern","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getOccurrences":{"name":"getOccurrences","async":false,"parameters":[{"name":"rangeStart","type":"Date","optional":false},{"name":"rangeEnd","type":"Date","optional":false},{"name":"options","type":"object","optional":true,"memberTypes":["string","Date","number"]}],"returnType":"Date[]","isStatic":false,"isPublic":true},"getMetadata":{"name":"getMetadata","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setMetadata":{"name":"setMetadata","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"updateMetadata":{"name":"updateMetadata","async":false,"parameters":[{"name":"updates","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getType":{"name":"getType","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getOrganizer":{"name":"getOrganizer","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getEvents":{"name":"getEvents","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"isActive":{"name":"isActive","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true}},"decoratorConfig":{"tableStrategy":"sti","api":{"include":["list","get","create","update","delete"]},"mcp":{"include":["list","get","create","update"]},"cli":{"skipApiCheck":true},"tenantScoped":{"mode":"optional"},"conflictColumns":["tenant_id","slug","context","_meta_type"]},"extends":"SmrtObject","exportName":"EventSeries","collectionExportName":"EventSeriesCollection","displayLabelField":"name","schema":{"tableName":"event_series","ddl":"CREATE TABLE IF NOT EXISTS \\"event_series\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"type_id\\" UUID,\\n \\"organizer_id\\" UUID,\\n \\"description\\" TEXT,\\n \\"start_date\\" TIMESTAMP,\\n \\"end_date\\" TIMESTAMP,\\n \\"recurrence\\" TEXT,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"type_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_types","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE"}},"organizer_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false},"description":{"type":"TEXT","notNull":false},"start_date":{"type":"TIMESTAMP","notNull":false},"end_date":{"type":"TIMESTAMP","notNull":false},"recurrence":{"type":"TEXT","notNull":false},"metadata":{"type":"TEXT","notNull":false},"external_id":{"type":"TEXT","notNull":false},"source":{"type":"TEXT","notNull":false}},"indexes":[{"name":"event_series_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"event_series_meta_type_idx","columns":["_meta_type"]},{"name":"event_series_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_series_type_id_idx","columns":["type_id"]},{"name":"event_series_organizer_id_idx","columns":["organizer_id"]}],"version":"c79f5863"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventType":{"name":"eventtype","className":"EventType","qualifiedName":"@happyvertical/smrt-events:EventType","collection":"eventtypes","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/EventType.ts","packageName":"@happyvertical/smrt-events","fields":{"created_at":{"type":"datetime","required":false},"updated_at":{"type":"datetime","required":false},"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"name":{"type":"text","required":true,"default":"","_meta":{"required":true}},"description":{"type":"text","required":false,"default":""},"schema":{"type":"text","required":false,"default":""},"participantSchema":{"type":"text","required":false,"default":""},"createdAt":{"type":"datetime","required":false},"updatedAt":{"type":"datetime","required":false}},"methods":{"getSchema":{"name":"getSchema","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setSchema":{"name":"setSchema","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getParticipantSchema":{"name":"getParticipantSchema","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setParticipantSchema":{"name":"setParticipantSchema","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getBySlug":{"name":"getBySlug","async":true,"parameters":[{"name":"_slug","type":"string","optional":false}],"returnType":"Promise<EventType | null>","isStatic":true,"isPublic":true}},"decoratorConfig":{"tableStrategy":"sti","api":{"include":["list","get","create","update","delete"]},"mcp":{"include":["list","get","create"]},"cli":{"skipApiCheck":true},"tenantScoped":{"mode":"optional"},"conflictColumns":["tenant_id","slug","context","_meta_type"]},"extends":"SmrtObject","exportName":"EventType","collectionExportName":"EventTypeCollection","displayLabelField":"name","validationRules":[{"field":"name","rule":"required","fieldType":"text"}],"schema":{"tableName":"event_types","ddl":"CREATE TABLE IF NOT EXISTS \\"event_types\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"description\\" TEXT DEFAULT '',\\n \\"schema\\" TEXT DEFAULT '',\\n \\"participant_schema\\" TEXT DEFAULT ''\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"description":{"type":"TEXT","notNull":false,"default":""},"schema":{"type":"TEXT","notNull":false,"default":""},"participant_schema":{"type":"TEXT","notNull":false,"default":""}},"indexes":[{"name":"event_types_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"event_types_meta_type_idx","columns":["_meta_type"]},{"name":"event_types_tenant_id_created_at_idx","columns":["tenant_id","created_at"]}],"version":"922ae3b0"},"importPath":"@happyvertical/smrt-events"}},"moduleType":"smrt","smrtDependencies":["@happyvertical/smrt-assets","@happyvertical/smrt-core","@happyvertical/smrt-places","@happyvertical/smrt-profiles","@happyvertical/smrt-tenancy"],"stampsConstructors":true}`));
21
+ ObjectRegistry.registerPackageManifest(JSON.parse(`{"version":"1.0.0","timestamp":0,"packageName":"@happyvertical/smrt-events","packageVersion":"0.55.8","objects":{"@happyvertical/smrt-events:EventAssetCollection":{"name":"eventassetcollection","className":"EventAssetCollection","qualifiedName":"@happyvertical/smrt-events:EventAssetCollection","collection":"eventassets","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventAssetCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"byRight":{"name":"byRight","async":true,"parameters":[{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<TItem[]>","isStatic":false,"isPublic":true},"byLeft":{"name":"byLeft","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<TItem[]>","isStatic":false,"isPublic":true},"attach":{"name":"attach","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionAttachOptions","optional":true}],"returnType":"Promise<TItem>","isStatic":false,"isPublic":true},"detach":{"name":"detach","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"setLinks":{"name":"setLinks","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightIds","type":"string[]","optional":false},{"name":"opts","type":"JunctionAttachOptions","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"getAssets":{"name":"getAssets","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<Asset[]>","isStatic":false,"isPublic":true},"addAsset":{"name":"addAsset","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"asset","type":"Asset","optional":false},{"name":"relationship","type":"any","optional":true,"default":"attachment"},{"name":"sortOrder","type":"any","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"removeAsset":{"name":"removeAsset","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"assetId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true}},"decoratorConfig":{"api":false,"mcp":false,"cli":false,"tableName":"event_assets"},"extends":"SmrtJunction","extendsTypeArg":"EventAsset","exportName":"EventAssetCollection","collectionExportName":"EventAssetCollectionCollection","schema":{"tableName":"event_assets","ddl":"CREATE TABLE IF NOT EXISTS \\"event_assets\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"event_id\\" UUID NOT NULL,\\n \\"asset_id\\" UUID NOT NULL,\\n \\"relationship\\" TEXT NOT NULL,\\n \\"sort_order\\" INTEGER NOT NULL DEFAULT 0\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false,"unique":false},"event_id":{"type":"UUID","referenceKind":"foreignKey","notNull":true,"unique":false,"foreignKey":{"table":"events","column":"id","onDelete":"CASCADE","onUpdate":"CASCADE"}},"asset_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":true,"unique":false},"relationship":{"type":"TEXT","notNull":true,"unique":false},"sort_order":{"type":"INTEGER","notNull":true,"unique":false,"default":0}},"indexes":[{"name":"event_assets_event_id_asset_id_idx","columns":["event_id","asset_id","relationship"],"unique":true},{"name":"event_assets_slug_context_idx","columns":["slug","context"]},{"name":"event_assets_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_assets_asset_id_idx","columns":["asset_id"]}],"version":"aeebedc6"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventCollection":{"name":"eventcollection","className":"EventCollection","qualifiedName":"@happyvertical/smrt-events:EventCollection","collection":"events","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"getBySeriesId":{"name":"getBySeriesId","async":true,"parameters":[{"name":"seriesId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByPlace":{"name":"getByPlace","async":true,"parameters":[{"name":"placeId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByDateRange":{"name":"getByDateRange","async":true,"parameters":[{"name":"startDate","type":"Date","optional":false},{"name":"endDate","type":"Date","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getUpcoming":{"name":"getUpcoming","async":true,"parameters":[{"name":"limit","type":"number","optional":true}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByStatus":{"name":"getByStatus","async":true,"parameters":[{"name":"status","type":"EventStatus","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByType":{"name":"getByType","async":true,"parameters":[{"name":"typeId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getRootEvents":{"name":"getRootEvents","async":true,"parameters":[],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getByParent":{"name":"getByParent","async":true,"parameters":[{"name":"parentId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getEventTree":{"name":"getEventTree","async":true,"parameters":[{"name":"eventId","type":"string","optional":false}],"returnType":"Promise<Event | null>","isStatic":false,"isPublic":true},"getAssets":{"name":"getAssets","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<Asset[]>","isStatic":false,"isPublic":true},"addAsset":{"name":"addAsset","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"asset","type":"Asset","optional":false},{"name":"relationship","type":"any","optional":true,"default":"attachment"},{"name":"sortOrder","type":"any","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"removeAsset":{"name":"removeAsset","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"assetId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"search":{"name":"search","async":true,"parameters":[{"name":"query","type":"string","optional":false},{"name":"filters","type":"EventSearchFilters","optional":true}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"getInProgress":{"name":"getInProgress","async":true,"parameters":[],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"findByTenant":{"name":"findByTenant","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"findGlobal":{"name":"findGlobal","async":true,"parameters":[],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true},"findWithGlobals":{"name":"findWithGlobals","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<Event[]>","isStatic":false,"isPublic":true}},"decoratorConfig":{},"extends":"SmrtCollection","extendsTypeArg":"Event","exportName":"EventCollection","collectionExportName":"EventCollectionCollection","schema":{"tableName":"events","ddl":"CREATE TABLE IF NOT EXISTS \\"events\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"parent_id\\" UUID,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"series_id\\" UUID,\\n \\"type_id\\" UUID,\\n \\"place_id\\" UUID,\\n \\"description\\" TEXT,\\n \\"start_date\\" TIMESTAMP,\\n \\"end_date\\" TIMESTAMP,\\n \\"all_day\\" BOOLEAN DEFAULT FALSE,\\n \\"time_zone\\" TEXT,\\n \\"status\\" TEXT DEFAULT 'scheduled',\\n \\"round\\" INTEGER,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"parent_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"events","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"series_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_series","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"type_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_types","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"place_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false},"description":{"type":"TEXT","notNull":false},"start_date":{"type":"TIMESTAMP","notNull":false},"end_date":{"type":"TIMESTAMP","notNull":false},"all_day":{"type":"BOOLEAN","notNull":false,"default":false},"time_zone":{"type":"TEXT","notNull":false},"status":{"type":"TEXT","notNull":false,"default":"scheduled"},"round":{"type":"INTEGER","notNull":false},"metadata":{"type":"TEXT","notNull":false},"external_id":{"type":"TEXT","notNull":false},"source":{"type":"TEXT","notNull":false}},"indexes":[{"name":"events_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"events_meta_type_idx","columns":["_meta_type"]},{"name":"events_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"events_parent_id_idx","columns":["parent_id"]},{"name":"events_series_id_idx","columns":["series_id"]},{"name":"events_type_id_idx","columns":["type_id"]},{"name":"events_place_id_idx","columns":["place_id"]}],"version":"8e689646"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventParticipantCollection":{"name":"eventparticipantcollection","className":"EventParticipantCollection","qualifiedName":"@happyvertical/smrt-events:EventParticipantCollection","collection":"eventparticipants","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventParticipantCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"byRight":{"name":"byRight","async":true,"parameters":[{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<TItem[]>","isStatic":false,"isPublic":true},"byLeft":{"name":"byLeft","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<TItem[]>","isStatic":false,"isPublic":true},"attach":{"name":"attach","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionAttachOptions","optional":true}],"returnType":"Promise<TItem>","isStatic":false,"isPublic":true},"detach":{"name":"detach","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightId","type":"string","optional":false},{"name":"opts","type":"JunctionFilterOptions","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"setLinks":{"name":"setLinks","async":true,"parameters":[{"name":"leftId","type":"string","optional":false},{"name":"rightIds","type":"string[]","optional":false},{"name":"opts","type":"JunctionAttachOptions","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"getByPlacement":{"name":"getByPlacement","async":true,"parameters":[{"name":"eventId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"getByGroup":{"name":"getByGroup","async":true,"parameters":[{"name":"eventId","type":"string","optional":false},{"name":"groupId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"getHome":{"name":"getHome","async":true,"parameters":[{"name":"eventId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"getAway":{"name":"getAway","async":true,"parameters":[{"name":"eventId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"search":{"name":"search","async":true,"parameters":[{"name":"filters","type":"ParticipantSearchFilters","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"getParticipantStats":{"name":"getParticipantStats","async":true,"parameters":[{"name":"profileId","type":"string","optional":false},{"name":"eventTypeId","type":"string","optional":true}],"returnType":"Promise<object>","isStatic":false,"isPublic":true},"findByTenant":{"name":"findByTenant","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"findGlobal":{"name":"findGlobal","async":true,"parameters":[],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"findWithGlobals":{"name":"findWithGlobals","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true}},"decoratorConfig":{},"extends":"SmrtJunction","extendsTypeArg":"EventParticipant","exportName":"EventParticipantCollection","collectionExportName":"EventParticipantCollectionCollection","schema":{"tableName":"event_participants","ddl":"CREATE TABLE IF NOT EXISTS \\"event_participants\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"event_id\\" UUID,\\n \\"profile_id\\" UUID,\\n \\"role\\" TEXT DEFAULT '',\\n \\"placement\\" INTEGER,\\n \\"group_id\\" TEXT,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false,"unique":false},"event_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"unique":false,"foreignKey":{"table":"events","column":"id","onDelete":"CASCADE","onUpdate":"CASCADE"}},"profile_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false,"unique":false},"role":{"type":"TEXT","notNull":false,"unique":false,"default":""},"placement":{"type":"INTEGER","notNull":false,"unique":false},"group_id":{"type":"TEXT","notNull":false,"unique":false},"metadata":{"type":"TEXT","notNull":false,"unique":false},"external_id":{"type":"TEXT","notNull":false,"unique":false},"source":{"type":"TEXT","notNull":false,"unique":false}},"indexes":[{"name":"event_participants_event_id_profile_id_idx","columns":["event_id","profile_id","role"],"unique":true,"nullsNotDistinct":true},{"name":"event_participants_slug_context_idx","columns":["slug","context"]},{"name":"event_participants_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_participants_profile_id_idx","columns":["profile_id"]}],"version":"c2faac84"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventSeriesCollection":{"name":"eventseriescollection","className":"EventSeriesCollection","qualifiedName":"@happyvertical/smrt-events:EventSeriesCollection","collection":"eventserieses","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventSeriesCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"getByOrganizer":{"name":"getByOrganizer","async":true,"parameters":[{"name":"organizerId","type":"string","optional":false}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"getActive":{"name":"getActive","async":true,"parameters":[],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"getUpcoming":{"name":"getUpcoming","async":true,"parameters":[{"name":"limit","type":"number","optional":true}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"getByType":{"name":"getByType","async":true,"parameters":[{"name":"typeId","type":"string","optional":false}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"search":{"name":"search","async":true,"parameters":[{"name":"query","type":"string","optional":false},{"name":"filters","type":"EventSeriesSearchFilters","optional":true}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"findByTenant":{"name":"findByTenant","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"findGlobal":{"name":"findGlobal","async":true,"parameters":[],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true},"findWithGlobals":{"name":"findWithGlobals","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventSeries[]>","isStatic":false,"isPublic":true}},"decoratorConfig":{},"extends":"SmrtCollection","extendsTypeArg":"EventSeries","exportName":"EventSeriesCollection","collectionExportName":"EventSeriesCollectionCollection","schema":{"tableName":"event_series","ddl":"CREATE TABLE IF NOT EXISTS \\"event_series\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"type_id\\" UUID,\\n \\"organizer_id\\" UUID,\\n \\"description\\" TEXT,\\n \\"start_date\\" TIMESTAMP,\\n \\"end_date\\" TIMESTAMP,\\n \\"recurrence\\" TEXT,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"type_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_types","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE"}},"organizer_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false},"description":{"type":"TEXT","notNull":false},"start_date":{"type":"TIMESTAMP","notNull":false},"end_date":{"type":"TIMESTAMP","notNull":false},"recurrence":{"type":"TEXT","notNull":false},"metadata":{"type":"TEXT","notNull":false},"external_id":{"type":"TEXT","notNull":false},"source":{"type":"TEXT","notNull":false}},"indexes":[{"name":"event_series_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"event_series_meta_type_idx","columns":["_meta_type"]},{"name":"event_series_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_series_type_id_idx","columns":["type_id"]},{"name":"event_series_organizer_id_idx","columns":["organizer_id"]}],"version":"c79f5863"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventTypeCollection":{"name":"eventtypecollection","className":"EventTypeCollection","qualifiedName":"@happyvertical/smrt-events:EventTypeCollection","collection":"eventtypes","filePath":"/home/runner/work/smrt/smrt/packages/events/src/collections/EventTypeCollection.ts","packageName":"@happyvertical/smrt-events","fields":{},"methods":{"getOrCreate":{"name":"getOrCreate","async":true,"parameters":[{"name":"slug","type":"string","optional":false},{"name":"name","type":"string","optional":true}],"returnType":"Promise<EventType>","isStatic":false,"isPublic":true},"getBySlug":{"name":"getBySlug","async":true,"parameters":[{"name":"slug","type":"string","optional":false}],"returnType":"Promise<EventType | null>","isStatic":false,"isPublic":true},"initializeDefaults":{"name":"initializeDefaults","async":true,"parameters":[],"returnType":"Promise<EventType[]>","isStatic":false,"isPublic":true},"findByTenant":{"name":"findByTenant","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventType[]>","isStatic":false,"isPublic":true},"findGlobal":{"name":"findGlobal","async":true,"parameters":[],"returnType":"Promise<EventType[]>","isStatic":false,"isPublic":true},"findWithGlobals":{"name":"findWithGlobals","async":true,"parameters":[{"name":"tenantId","type":"string","optional":false}],"returnType":"Promise<EventType[]>","isStatic":false,"isPublic":true}},"decoratorConfig":{},"extends":"SmrtCollection","extendsTypeArg":"EventType","exportName":"EventTypeCollection","collectionExportName":"EventTypeCollectionCollection","schema":{"tableName":"event_types","ddl":"CREATE TABLE IF NOT EXISTS \\"event_types\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"description\\" TEXT DEFAULT '',\\n \\"schema\\" TEXT DEFAULT '',\\n \\"participant_schema\\" TEXT DEFAULT ''\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"description":{"type":"TEXT","notNull":false,"default":""},"schema":{"type":"TEXT","notNull":false,"default":""},"participant_schema":{"type":"TEXT","notNull":false,"default":""}},"indexes":[{"name":"event_types_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"event_types_meta_type_idx","columns":["_meta_type"]},{"name":"event_types_tenant_id_created_at_idx","columns":["tenant_id","created_at"]}],"version":"922ae3b0"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:Event":{"name":"event","className":"Event","qualifiedName":"@happyvertical/smrt-events:Event","collection":"events","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/Event.ts","packageName":"@happyvertical/smrt-events","fields":{"created_at":{"type":"datetime","required":false},"updated_at":{"type":"datetime","required":false},"parentId":{"type":"foreignKey","required":false,"related":"Event","_meta":{"nullable":true,"constraint":{"engines":["postgres","sqlite"]}}},"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"name":{"type":"text","required":false,"default":"","description":"What the event is called.","_meta":{"description":"What the event is called."}},"seriesId":{"type":"foreignKey","required":false,"related":"EventSeries","description":"The series this event is part of, if any.","_meta":{"description":"The series this event is part of, if any.","constraint":{"engines":["postgres","sqlite"]}}},"typeId":{"type":"foreignKey","required":false,"related":"EventType","description":"The kind of event.","_meta":{"description":"The kind of event.","constraint":{"engines":["postgres","sqlite"]}}},"placeId":{"type":"crossPackageRef","required":false,"related":"@happyvertical/smrt-places:Place","description":"Where it takes place.","_meta":{"description":"Where it takes place."}},"description":{"type":"text","required":false,"description":"What the event is about.","_meta":{"description":"What the event is about."}},"startDate":{"type":"datetime","required":false,"description":"When it starts.","_meta":{"description":"When it starts."}},"endDate":{"type":"datetime","required":false,"description":"When it ends.","_meta":{"description":"When it ends."}},"allDay":{"type":"boolean","required":false,"default":false,"description":"Whether the event lasts all day.","_meta":{"description":"Whether the event lasts all day."}},"timeZone":{"type":"text","required":false},"status":{"type":"text","required":false,"default":"scheduled","description":"scheduled, in progress, completed, cancelled or postponed.","_meta":{"description":"scheduled, in progress, completed, cancelled or postponed."},"enum":["scheduled","in_progress","completed","cancelled","postponed"]},"round":{"type":"integer","required":false},"metadata":{"type":"text","required":false},"externalId":{"type":"text","required":false},"source":{"type":"text","required":false},"createdAt":{"type":"text","required":false},"updatedAt":{"type":"text","required":false}},"methods":{"getParent":{"name":"getParent","async":true,"parameters":[],"returnType":"Promise<this | null>","isStatic":false,"isPublic":true},"getChildren":{"name":"getChildren","async":true,"parameters":[],"returnType":"Promise<this[]>","isStatic":false,"isPublic":true},"getAncestors":{"name":"getAncestors","async":true,"parameters":[],"returnType":"Promise<this[]>","isStatic":false,"isPublic":true},"getDescendants":{"name":"getDescendants","async":true,"parameters":[],"returnType":"Promise<this[]>","isStatic":false,"isPublic":true},"getHierarchy":{"name":"getHierarchy","async":true,"parameters":[],"returnType":"Promise<HierarchyView<this>>","isStatic":false,"isPublic":true},"moveTo":{"name":"moveTo","async":true,"parameters":[{"name":"newParent","type":"this | string | null","optional":false,"unionBranches":[{"type":"this"},{"type":"string"},{"type":"null"}]}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"getMetadata":{"name":"getMetadata","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setMetadata":{"name":"setMetadata","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"updateMetadata":{"name":"updateMetadata","async":false,"parameters":[{"name":"updates","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"updateStatus":{"name":"updateStatus","async":true,"parameters":[{"name":"newStatus","type":"EventStatus","optional":false}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"getSeries":{"name":"getSeries","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getType":{"name":"getType","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getPlace":{"name":"getPlace","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getRootEvent":{"name":"getRootEvent","async":true,"parameters":[],"returnType":"Promise<Event>","isStatic":false,"isPublic":true},"getParticipants":{"name":"getParticipants","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getAssets":{"name":"getAssets","async":true,"parameters":[{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<Asset[]>","isStatic":false,"isPublic":true},"addAsset":{"name":"addAsset","async":true,"parameters":[{"name":"asset","type":"Asset","optional":false},{"name":"relationship","type":"any","optional":true,"default":"attachment"},{"name":"sortOrder","type":"any","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"removeAsset":{"name":"removeAsset","async":true,"parameters":[{"name":"assetId","type":"string","optional":false},{"name":"relationship","type":"string","optional":true}],"returnType":"Promise<void>","isStatic":false,"isPublic":true},"isInProgress":{"name":"isInProgress","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true},"isRoot":{"name":"isRoot","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true}},"decoratorConfig":{"tableStrategy":"sti","api":{"include":["list","get","create","update","delete"]},"mcp":{"include":["list","get","create","update"]},"cli":{"skipApiCheck":true},"tenantScoped":{"mode":"optional"},"conflictColumns":["tenant_id","slug","context","_meta_type"]},"extends":"SmrtHierarchical","exportName":"Event","collectionExportName":"EventCollection","displayLabelField":"name","schema":{"tableName":"events","ddl":"CREATE TABLE IF NOT EXISTS \\"events\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"parent_id\\" UUID,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"series_id\\" UUID,\\n \\"type_id\\" UUID,\\n \\"place_id\\" UUID,\\n \\"description\\" TEXT,\\n \\"start_date\\" TIMESTAMP,\\n \\"end_date\\" TIMESTAMP,\\n \\"all_day\\" BOOLEAN DEFAULT FALSE,\\n \\"time_zone\\" TEXT,\\n \\"status\\" TEXT DEFAULT 'scheduled',\\n \\"round\\" INTEGER,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"parent_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"events","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"series_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_series","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"type_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_types","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE","engines":["postgres","sqlite"]}},"place_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false},"description":{"type":"TEXT","notNull":false},"start_date":{"type":"TIMESTAMP","notNull":false},"end_date":{"type":"TIMESTAMP","notNull":false},"all_day":{"type":"BOOLEAN","notNull":false,"default":false},"time_zone":{"type":"TEXT","notNull":false},"status":{"type":"TEXT","notNull":false,"default":"scheduled"},"round":{"type":"INTEGER","notNull":false},"metadata":{"type":"TEXT","notNull":false},"external_id":{"type":"TEXT","notNull":false},"source":{"type":"TEXT","notNull":false}},"indexes":[{"name":"events_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"events_meta_type_idx","columns":["_meta_type"]},{"name":"events_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"events_parent_id_idx","columns":["parent_id"]},{"name":"events_series_id_idx","columns":["series_id"]},{"name":"events_type_id_idx","columns":["type_id"]},{"name":"events_place_id_idx","columns":["place_id"]}],"version":"8e689646"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventAsset":{"name":"eventasset","className":"EventAsset","qualifiedName":"@happyvertical/smrt-events:EventAsset","collection":"eventassets","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/EventAsset.ts","packageName":"@happyvertical/smrt-events","fields":{"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"eventId":{"type":"foreignKey","required":true,"related":"Event","_meta":{"required":true}},"assetId":{"type":"crossPackageRef","required":true,"related":"@happyvertical/smrt-assets:Asset"},"relationship":{"type":"text","required":true,"_meta":{"required":true}},"sortOrder":{"type":"integer","required":true,"default":0}},"methods":{},"decoratorConfig":{"tableName":"event_assets","conflictColumns":["event_id","asset_id","relationship"],"api":false,"mcp":false,"cli":false,"tenantScoped":{"mode":"optional"}},"extends":"SmrtObject","exportName":"EventAsset","collectionExportName":"EventAssetCollection","validationRules":[{"field":"eventId","rule":"required","fieldType":"foreignKey"},{"field":"assetId","rule":"required","fieldType":"crossPackageRef"},{"field":"relationship","rule":"required","fieldType":"text"},{"field":"sortOrder","rule":"required","fieldType":"integer"}],"schema":{"tableName":"event_assets","ddl":"CREATE TABLE IF NOT EXISTS \\"event_assets\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"event_id\\" UUID NOT NULL,\\n \\"asset_id\\" UUID NOT NULL,\\n \\"relationship\\" TEXT NOT NULL,\\n \\"sort_order\\" INTEGER NOT NULL DEFAULT 0\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false,"unique":false},"event_id":{"type":"UUID","referenceKind":"foreignKey","notNull":true,"unique":false,"foreignKey":{"table":"events","column":"id","onDelete":"CASCADE","onUpdate":"CASCADE"}},"asset_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":true,"unique":false},"relationship":{"type":"TEXT","notNull":true,"unique":false},"sort_order":{"type":"INTEGER","notNull":true,"unique":false,"default":0}},"indexes":[{"name":"event_assets_event_id_asset_id_idx","columns":["event_id","asset_id","relationship"],"unique":true},{"name":"event_assets_slug_context_idx","columns":["slug","context"]},{"name":"event_assets_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_assets_asset_id_idx","columns":["asset_id"]}],"version":"aeebedc6"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventParticipant":{"name":"eventparticipant","className":"EventParticipant","qualifiedName":"@happyvertical/smrt-events:EventParticipant","collection":"eventparticipants","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/EventParticipant.ts","packageName":"@happyvertical/smrt-events","fields":{"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"eventId":{"type":"foreignKey","required":false,"related":"Event","description":"The event the person takes part in.","_meta":{"description":"The event the person takes part in."}},"profileId":{"type":"crossPackageRef","required":false,"related":"@happyvertical/smrt-profiles:Profile","description":"The person taking part.","_meta":{"description":"The person taking part."}},"role":{"type":"text","required":false,"default":"","description":"What they do there, for example speaker or attendee.","_meta":{"description":"What they do there, for example speaker or attendee."}},"placement":{"type":"integer","required":false},"groupId":{"type":"text","required":false},"metadata":{"type":"text","required":false},"externalId":{"type":"text","required":false},"source":{"type":"text","required":false},"createdAt":{"type":"text","required":false},"updatedAt":{"type":"text","required":false}},"methods":{"getMetadata":{"name":"getMetadata","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setMetadata":{"name":"setMetadata","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"updateMetadata":{"name":"updateMetadata","async":false,"parameters":[{"name":"updates","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getEvent":{"name":"getEvent","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getProfile":{"name":"getProfile","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getGroupParticipants":{"name":"getGroupParticipants","async":true,"parameters":[],"returnType":"Promise<EventParticipant[]>","isStatic":false,"isPublic":true},"isHome":{"name":"isHome","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true},"isAway":{"name":"isAway","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true}},"decoratorConfig":{"conflictColumns":["event_id","profile_id","role"],"api":{"include":["list","get","create","update","delete"]},"mcp":{"include":["list","get","create","update"]},"cli":{"skipApiCheck":true},"tenantScoped":{"mode":"optional"}},"extends":"SmrtObject","exportName":"EventParticipant","collectionExportName":"EventParticipantCollection","schema":{"tableName":"event_participants","ddl":"CREATE TABLE IF NOT EXISTS \\"event_participants\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"event_id\\" UUID,\\n \\"profile_id\\" UUID,\\n \\"role\\" TEXT DEFAULT '',\\n \\"placement\\" INTEGER,\\n \\"group_id\\" TEXT,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false,"unique":false},"event_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"unique":false,"foreignKey":{"table":"events","column":"id","onDelete":"CASCADE","onUpdate":"CASCADE"}},"profile_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false,"unique":false},"role":{"type":"TEXT","notNull":false,"unique":false,"default":""},"placement":{"type":"INTEGER","notNull":false,"unique":false},"group_id":{"type":"TEXT","notNull":false,"unique":false},"metadata":{"type":"TEXT","notNull":false,"unique":false},"external_id":{"type":"TEXT","notNull":false,"unique":false},"source":{"type":"TEXT","notNull":false,"unique":false}},"indexes":[{"name":"event_participants_event_id_profile_id_idx","columns":["event_id","profile_id","role"],"unique":true,"nullsNotDistinct":true},{"name":"event_participants_slug_context_idx","columns":["slug","context"]},{"name":"event_participants_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_participants_profile_id_idx","columns":["profile_id"]}],"version":"c2faac84"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventSeries":{"name":"eventseries","className":"EventSeries","qualifiedName":"@happyvertical/smrt-events:EventSeries","collection":"eventserieses","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/EventSeries.ts","packageName":"@happyvertical/smrt-events","fields":{"created_at":{"type":"datetime","required":false},"updated_at":{"type":"datetime","required":false},"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"name":{"type":"text","required":false,"default":"","description":"What the series is called.","_meta":{"description":"What the series is called."}},"typeId":{"type":"foreignKey","required":false,"related":"EventType","description":"The kind of event in this series.","_meta":{"description":"The kind of event in this series."}},"organizerId":{"type":"crossPackageRef","required":false,"related":"@happyvertical/smrt-profiles:Profile","description":"Who runs the series.","_meta":{"description":"Who runs the series."}},"description":{"type":"text","required":false,"description":"What the series is about.","_meta":{"description":"What the series is about."}},"startDate":{"type":"datetime","required":false,"description":"When the series begins.","_meta":{"description":"When the series begins."}},"endDate":{"type":"datetime","required":false,"description":"When the series ends.","_meta":{"description":"When the series ends."}},"recurrence":{"type":"text","required":false,"description":"How often it repeats.","_meta":{"description":"How often it repeats."}},"metadata":{"type":"text","required":false},"externalId":{"type":"text","required":false},"source":{"type":"text","required":false},"createdAt":{"type":"text","required":false},"updatedAt":{"type":"text","required":false}},"methods":{"getRecurrence":{"name":"getRecurrence","async":false,"parameters":[],"returnType":"RecurrencePattern | null","isStatic":false,"isPublic":true},"setRecurrence":{"name":"setRecurrence","async":false,"parameters":[{"name":"pattern","type":"RecurrencePattern","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getOccurrences":{"name":"getOccurrences","async":false,"parameters":[{"name":"rangeStart","type":"Date","optional":false},{"name":"rangeEnd","type":"Date","optional":false},{"name":"options","type":"object","optional":true,"memberTypes":["string","Date","number"]}],"returnType":"Date[]","isStatic":false,"isPublic":true},"getMetadata":{"name":"getMetadata","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setMetadata":{"name":"setMetadata","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"updateMetadata":{"name":"updateMetadata","async":false,"parameters":[{"name":"updates","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getType":{"name":"getType","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getOrganizer":{"name":"getOrganizer","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"getEvents":{"name":"getEvents","async":true,"parameters":[],"returnType":"any","isStatic":false,"isPublic":true},"isActive":{"name":"isActive","async":false,"parameters":[],"returnType":"boolean","isStatic":false,"isPublic":true}},"decoratorConfig":{"tableStrategy":"sti","api":{"include":["list","get","create","update","delete"]},"mcp":{"include":["list","get","create","update"]},"cli":{"skipApiCheck":true},"tenantScoped":{"mode":"optional"},"conflictColumns":["tenant_id","slug","context","_meta_type"]},"extends":"SmrtObject","exportName":"EventSeries","collectionExportName":"EventSeriesCollection","displayLabelField":"name","schema":{"tableName":"event_series","ddl":"CREATE TABLE IF NOT EXISTS \\"event_series\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"type_id\\" UUID,\\n \\"organizer_id\\" UUID,\\n \\"description\\" TEXT,\\n \\"start_date\\" TIMESTAMP,\\n \\"end_date\\" TIMESTAMP,\\n \\"recurrence\\" TEXT,\\n \\"metadata\\" TEXT,\\n \\"external_id\\" TEXT,\\n \\"source\\" TEXT\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"type_id":{"type":"UUID","referenceKind":"foreignKey","notNull":false,"foreignKey":{"table":"event_types","column":"id","onDelete":"NO ACTION","onUpdate":"CASCADE"}},"organizer_id":{"type":"UUID","referenceKind":"crossPackageRef","notNull":false},"description":{"type":"TEXT","notNull":false},"start_date":{"type":"TIMESTAMP","notNull":false},"end_date":{"type":"TIMESTAMP","notNull":false},"recurrence":{"type":"TEXT","notNull":false},"metadata":{"type":"TEXT","notNull":false},"external_id":{"type":"TEXT","notNull":false},"source":{"type":"TEXT","notNull":false}},"indexes":[{"name":"event_series_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"event_series_meta_type_idx","columns":["_meta_type"]},{"name":"event_series_tenant_id_created_at_idx","columns":["tenant_id","created_at"]},{"name":"event_series_type_id_idx","columns":["type_id"]},{"name":"event_series_organizer_id_idx","columns":["organizer_id"]}],"version":"c79f5863"},"importPath":"@happyvertical/smrt-events"},"@happyvertical/smrt-events:EventType":{"name":"eventtype","className":"EventType","qualifiedName":"@happyvertical/smrt-events:EventType","collection":"eventtypes","filePath":"/home/runner/work/smrt/smrt/packages/events/src/models/EventType.ts","packageName":"@happyvertical/smrt-events","fields":{"created_at":{"type":"datetime","required":false},"updated_at":{"type":"datetime","required":false},"tenantId":{"type":"text","required":false,"_meta":{"sqlType":"UUID","nullable":true,"__tenancy":{"isTenantIdField":true,"autoFilter":true,"required":false,"autoPopulate":true,"nullable":true,"mode":"optional","field":"tenantId","allowSuperAdminBypass":false}}},"name":{"type":"text","required":true,"default":"","description":"What this kind of event is called, for example workshop.","_meta":{"required":true,"description":"What this kind of event is called, for example workshop."}},"description":{"type":"text","required":false,"default":"","description":"What this kind of event is for.","_meta":{"description":"What this kind of event is for."}},"schema":{"type":"text","required":false,"default":""},"participantSchema":{"type":"text","required":false,"default":""},"createdAt":{"type":"datetime","required":false},"updatedAt":{"type":"datetime","required":false}},"methods":{"getSchema":{"name":"getSchema","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setSchema":{"name":"setSchema","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getParticipantSchema":{"name":"getParticipantSchema","async":false,"parameters":[],"returnType":"Record<string, unknown>","isStatic":false,"isPublic":true},"setParticipantSchema":{"name":"setParticipantSchema","async":false,"parameters":[{"name":"data","type":"Record<string, unknown>","optional":false}],"returnType":"void","isStatic":false,"isPublic":true},"getBySlug":{"name":"getBySlug","async":true,"parameters":[{"name":"_slug","type":"string","optional":false}],"returnType":"Promise<EventType | null>","isStatic":true,"isPublic":true}},"decoratorConfig":{"tableStrategy":"sti","api":{"include":["list","get","create","update","delete"]},"mcp":{"include":["list","get","create"]},"cli":{"skipApiCheck":true},"tenantScoped":{"mode":"optional"},"conflictColumns":["tenant_id","slug","context","_meta_type"]},"extends":"SmrtObject","exportName":"EventType","collectionExportName":"EventTypeCollection","displayLabelField":"name","validationRules":[{"field":"name","rule":"required","fieldType":"text"}],"schema":{"tableName":"event_types","ddl":"CREATE TABLE IF NOT EXISTS \\"event_types\\" (\\n \\"id\\" UUID PRIMARY KEY NOT NULL,\\n \\"slug\\" TEXT NOT NULL,\\n \\"context\\" TEXT NOT NULL DEFAULT '',\\n \\"_meta_type\\" TEXT NOT NULL,\\n \\"_meta_data\\" JSON,\\n \\"created_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"updated_at\\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\\n \\"tenant_id\\" UUID,\\n \\"name\\" TEXT DEFAULT '',\\n \\"description\\" TEXT DEFAULT '',\\n \\"schema\\" TEXT DEFAULT '',\\n \\"participant_schema\\" TEXT DEFAULT ''\\n);","columns":{"id":{"type":"UUID","primaryKey":true,"referenceKind":"id","notNull":true},"slug":{"type":"TEXT","notNull":true},"context":{"type":"TEXT","notNull":true,"default":""},"_meta_type":{"type":"TEXT","notNull":true},"_meta_data":{"type":"JSON","notNull":false},"created_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"updated_at":{"type":"TIMESTAMP","notNull":true,"default":"current_timestamp"},"tenant_id":{"type":"UUID","referenceKind":"tenantId","notNull":false},"name":{"type":"TEXT","notNull":false,"default":""},"description":{"type":"TEXT","notNull":false,"default":""},"schema":{"type":"TEXT","notNull":false,"default":""},"participant_schema":{"type":"TEXT","notNull":false,"default":""}},"indexes":[{"name":"event_types_slug_context_meta_type_idx","columns":["tenant_id","slug","context","_meta_type"],"unique":true,"nullsNotDistinct":true},{"name":"event_types_meta_type_idx","columns":["_meta_type"]},{"name":"event_types_tenant_id_created_at_idx","columns":["tenant_id","created_at"]}],"version":"922ae3b0"},"importPath":"@happyvertical/smrt-events"}},"moduleType":"smrt","recipes":[{"id":"events.calendar","className":"CalendarRecipe","label":"Events","summary":"Schedule events, group them in series and track who takes part.","synonyms":["calendar","schedule","meetings","bookings","attendees"],"models":["@happyvertical/smrt-events:Event","@happyvertical/smrt-events:EventType","@happyvertical/smrt-events:EventSeries","@happyvertical/smrt-events:EventParticipant"],"nav":[{"label":"Events","model":"@happyvertical/smrt-events:Event","icon":"calendar","description":"Everything on your calendar, with who and when."},{"label":"Event types","model":"@happyvertical/smrt-events:EventType","icon":"tag","description":"The kinds of events you run, such as workshops or classes."},{"label":"Event series","model":"@happyvertical/smrt-events:EventSeries","icon":"repeat","description":"Repeating schedules, like a class every Tuesday evening."}],"requires":[],"section":{"id":"calendar","label":"Calendar","icon":"calendar","description":"Events and what is scheduled when."},"options":{"@happyvertical/smrt-events:Event":{"fields":{"parentId":{"visibility":"hidden"},"round":{"visibility":"hidden"},"metadata":{"visibility":"hidden"},"externalId":{"visibility":"hidden"},"source":{"visibility":"hidden"},"timeZone":{"visibility":"hidden"}}},"@happyvertical/smrt-events:EventType":{"fields":{"schema":{"visibility":"hidden"},"participantSchema":{"visibility":"hidden"}}},"@happyvertical/smrt-events:EventSeries":{"fields":{"metadata":{"visibility":"hidden"},"externalId":{"visibility":"hidden"},"source":{"visibility":"hidden"}}},"@happyvertical/smrt-events:EventParticipant":{"fields":{"groupId":{"visibility":"hidden"},"placement":{"visibility":"hidden"},"metadata":{"visibility":"hidden"},"externalId":{"visibility":"hidden"},"source":{"visibility":"hidden"}}}},"help":{"markdown":"## Overview\\n\\nEvents is your calendar. Each event has a time and a type, can belong to a\\nseries, and lists who takes part.\\n\\n## Tasks\\n\\n### Schedule an event\\n\\n1. Create a new event.\\n2. Enter the **{field:name}**, the **{field:startDate}** and the\\n **{field:endDate}**.\\n3. Pick the **{field:typeId}**, and the **{field:seriesId}** if it repeats.\\n4. Add the people taking part with their **{field:role}**.\\n\\n### Keep it current\\n\\n1. Update **{field:status}** as the event goes ahead, finishes or is postponed.\\n","fieldRefs":["endDate","name","role","seriesId","startDate","status","typeId"]},"surfaces":[{"kind":"route","path":"/events/meeting","export":"@happyvertical/smrt-events/svelte#MeetingView","label":"Meeting view"}],"runtime":"both","demo":{"mode":"server","reasons":["Needs a server because its package does not build for a browser: node:crypto; and its package depends on @happyvertical/smrt-places, @happyvertical/smrt-profiles, @happyvertical/smrt-tenancy, which do not build for a browser (#3617, #3624, #3626, #3627)."]}}],"smrtDependencies":["@happyvertical/smrt-assets","@happyvertical/smrt-core","@happyvertical/smrt-places","@happyvertical/smrt-profiles","@happyvertical/smrt-tenancy"],"browser":{"status":"server-only","issues":["#3617","#3624","#3626","#3627"],"reason":"node:crypto","via":["@happyvertical/smrt-places","@happyvertical/smrt-profiles","@happyvertical/smrt-tenancy"]},"stampsConstructors":true}`));
22
22
  //#endregion
23
23
  //#region src/calendar/icalendar.ts
24
24
  var CalendarEventValidationError = class extends Error {
@@ -294,11 +294,6 @@ var Event = class extends SmrtHierarchical {
294
294
  description = "";
295
295
  startDate = null;
296
296
  endDate = null;
297
- /**
298
- * True when the event occupies whole calendar days rather than a time
299
- * range. `startDate` is the first day (local midnight in `timeZone`) and
300
- * `endDate`, when set, is the exclusive end (midnight after the last day).
301
- */
302
297
  allDay = false;
303
298
  /**
304
299
  * IANA time zone the event is scheduled in (for example
@@ -474,13 +469,19 @@ var Event = class extends SmrtHierarchical {
474
469
  };
475
470
  __publicField$6(Event, "__smrtPackage__", "@happyvertical/smrt-events");
476
471
  __decorateClass$6([tenantId({ nullable: true })], Event.prototype, "tenantId", 2);
477
- __decorateClass$6([foreignKey("EventSeries", { constraint: { engines: ["postgres", "sqlite"] } })], Event.prototype, "seriesId", 2);
472
+ __decorateClass$6([field({ description: "What the event is called." })], Event.prototype, "name", 2);
473
+ __decorateClass$6([field({ description: "The series this event is part of, if any." }), foreignKey("EventSeries", { constraint: { engines: ["postgres", "sqlite"] } })], Event.prototype, "seriesId", 2);
478
474
  __decorateClass$6([foreignKey("Event", {
479
475
  nullable: true,
480
476
  constraint: { engines: ["postgres", "sqlite"] }
481
477
  })], Event.prototype, "parentId", 2);
482
- __decorateClass$6([foreignKey("EventType", { constraint: { engines: ["postgres", "sqlite"] } })], Event.prototype, "typeId", 2);
483
- __decorateClass$6([crossPackageRef("@happyvertical/smrt-places:Place")], Event.prototype, "placeId", 2);
478
+ __decorateClass$6([field({ description: "The kind of event." }), foreignKey("EventType", { constraint: { engines: ["postgres", "sqlite"] } })], Event.prototype, "typeId", 2);
479
+ __decorateClass$6([field({ description: "Where it takes place." }), crossPackageRef("@happyvertical/smrt-places:Place")], Event.prototype, "placeId", 2);
480
+ __decorateClass$6([field({ description: "What the event is about." })], Event.prototype, "description", 2);
481
+ __decorateClass$6([field({ description: "When it starts." })], Event.prototype, "startDate", 2);
482
+ __decorateClass$6([field({ description: "When it ends." })], Event.prototype, "endDate", 2);
483
+ __decorateClass$6([field({ description: "Whether the event lasts all day." })], Event.prototype, "allDay", 2);
484
+ __decorateClass$6([field({ description: "scheduled, in progress, completed, cancelled or postponed." })], Event.prototype, "status", 2);
484
485
  Event = __decorateClass$6([TenantScoped({ mode: "optional" }), smrt({
485
486
  tableStrategy: "sti",
486
487
  api: { include: [
@@ -851,8 +852,13 @@ var EventSeries = class extends SmrtObject {
851
852
  };
852
853
  __publicField$5(EventSeries, "__smrtPackage__", "@happyvertical/smrt-events");
853
854
  __decorateClass$5([tenantId({ nullable: true })], EventSeries.prototype, "tenantId", 2);
854
- __decorateClass$5([foreignKey("EventType")], EventSeries.prototype, "typeId", 2);
855
- __decorateClass$5([crossPackageRef("@happyvertical/smrt-profiles:Profile")], EventSeries.prototype, "organizerId", 2);
855
+ __decorateClass$5([field({ description: "What the series is called." })], EventSeries.prototype, "name", 2);
856
+ __decorateClass$5([field({ description: "The kind of event in this series." }), foreignKey("EventType")], EventSeries.prototype, "typeId", 2);
857
+ __decorateClass$5([field({ description: "Who runs the series." }), crossPackageRef("@happyvertical/smrt-profiles:Profile")], EventSeries.prototype, "organizerId", 2);
858
+ __decorateClass$5([field({ description: "What the series is about." })], EventSeries.prototype, "description", 2);
859
+ __decorateClass$5([field({ description: "When the series begins." })], EventSeries.prototype, "startDate", 2);
860
+ __decorateClass$5([field({ description: "When the series ends." })], EventSeries.prototype, "endDate", 2);
861
+ __decorateClass$5([field({ description: "How often it repeats." })], EventSeries.prototype, "recurrence", 2);
856
862
  EventSeries = __decorateClass$5([TenantScoped({ mode: "optional" }), smrt({
857
863
  tableStrategy: "sti",
858
864
  api: { include: [
@@ -1424,8 +1430,9 @@ var EventParticipant = class extends SmrtObject {
1424
1430
  };
1425
1431
  __publicField$2(EventParticipant, "__smrtPackage__", "@happyvertical/smrt-events");
1426
1432
  __decorateClass$2([tenantId({ nullable: true })], EventParticipant.prototype, "tenantId", 2);
1427
- __decorateClass$2([foreignKey("Event")], EventParticipant.prototype, "eventId", 2);
1428
- __decorateClass$2([crossPackageRef("@happyvertical/smrt-profiles:Profile")], EventParticipant.prototype, "profileId", 2);
1433
+ __decorateClass$2([field({ description: "The event the person takes part in." }), foreignKey("Event")], EventParticipant.prototype, "eventId", 2);
1434
+ __decorateClass$2([field({ description: "The person taking part." }), crossPackageRef("@happyvertical/smrt-profiles:Profile")], EventParticipant.prototype, "profileId", 2);
1435
+ __decorateClass$2([field({ description: "What they do there, for example speaker or attendee." })], EventParticipant.prototype, "role", 2);
1429
1436
  EventParticipant = __decorateClass$2([TenantScoped({ mode: "optional" }), smrt({
1430
1437
  conflictColumns: [
1431
1438
  "event_id",
@@ -1651,7 +1658,11 @@ var EventType = class extends SmrtObject {
1651
1658
  };
1652
1659
  __publicField(EventType, "__smrtPackage__", "@happyvertical/smrt-events");
1653
1660
  __decorateClass([tenantId({ nullable: true })], EventType.prototype, "tenantId", 2);
1654
- __decorateClass([field({ required: true })], EventType.prototype, "name", 2);
1661
+ __decorateClass([field({
1662
+ required: true,
1663
+ description: "What this kind of event is called, for example workshop."
1664
+ })], EventType.prototype, "name", 2);
1665
+ __decorateClass([field({ description: "What this kind of event is for." })], EventType.prototype, "description", 2);
1655
1666
  EventType = __decorateClass([TenantScoped({ mode: "optional" }), smrt({
1656
1667
  tableStrategy: "sti",
1657
1668
  api: { include: [
@@ -1882,6 +1893,86 @@ var EventTypeCollection = class extends SmrtCollection {
1882
1893
  }
1883
1894
  };
1884
1895
  //#endregion
1885
- export { CalendarEventValidationError, EVENTS_MODULE_META, EVENTS_UI_SLOTS, Event, EventAsset, EventAssetCollection, EventCollection, EventParticipant, EventParticipantCollection, EventSeries, EventSeriesCollection, EventType, EventTypeCollection, calculateDuration, calculateNextOccurrence, checkSchedulingConflict, expandICalendarEvents, expandRecurrence, formatDuration, formatEventDateRange, fromZonedWallTime, generateEventSlug, getEventStatusFromDates, isEventNow, isValidTimeZone, parseICalendarEvents, parseRecurrencePattern, sortEventsByDate, syncICalendarSource, toZonedWallTime, validateEventStatus };
1896
+ //#region src/recipes.ts
1897
+ var CalendarRecipe = class extends SmrtRecipe {
1898
+ static id = "events.calendar";
1899
+ static help = "./calendar.recipe.md";
1900
+ static label = "Events";
1901
+ static summary = "Schedule events, group them in series and track who takes part.";
1902
+ static synonyms = [
1903
+ "calendar",
1904
+ "schedule",
1905
+ "meetings",
1906
+ "bookings",
1907
+ "attendees"
1908
+ ];
1909
+ static section = {
1910
+ id: "calendar",
1911
+ label: "Calendar",
1912
+ icon: "calendar",
1913
+ description: "Events and what is scheduled when."
1914
+ };
1915
+ static models = [
1916
+ Event,
1917
+ EventType,
1918
+ EventSeries,
1919
+ EventParticipant
1920
+ ];
1921
+ static runtime = "both";
1922
+ static surfaces = [{
1923
+ kind: "route",
1924
+ path: "/events/meeting",
1925
+ export: "@happyvertical/smrt-events/svelte#MeetingView",
1926
+ label: "Meeting view"
1927
+ }];
1928
+ static nav = [
1929
+ {
1930
+ label: "Events",
1931
+ model: Event,
1932
+ icon: "calendar",
1933
+ description: "Everything on your calendar, with who and when."
1934
+ },
1935
+ {
1936
+ label: "Event types",
1937
+ model: EventType,
1938
+ icon: "tag",
1939
+ description: "The kinds of events you run, such as workshops or classes."
1940
+ },
1941
+ {
1942
+ label: "Event series",
1943
+ model: EventSeries,
1944
+ icon: "repeat",
1945
+ description: "Repeating schedules, like a class every Tuesday evening."
1946
+ }
1947
+ ];
1948
+ static options = {
1949
+ Event: { fields: {
1950
+ parentId: { visibility: "hidden" },
1951
+ round: { visibility: "hidden" },
1952
+ metadata: { visibility: "hidden" },
1953
+ externalId: { visibility: "hidden" },
1954
+ source: { visibility: "hidden" },
1955
+ timeZone: { visibility: "hidden" }
1956
+ } },
1957
+ EventType: { fields: {
1958
+ schema: { visibility: "hidden" },
1959
+ participantSchema: { visibility: "hidden" }
1960
+ } },
1961
+ EventSeries: { fields: {
1962
+ metadata: { visibility: "hidden" },
1963
+ externalId: { visibility: "hidden" },
1964
+ source: { visibility: "hidden" }
1965
+ } },
1966
+ EventParticipant: { fields: {
1967
+ groupId: { visibility: "hidden" },
1968
+ placement: { visibility: "hidden" },
1969
+ metadata: { visibility: "hidden" },
1970
+ externalId: { visibility: "hidden" },
1971
+ source: { visibility: "hidden" }
1972
+ } }
1973
+ };
1974
+ };
1975
+ //#endregion
1976
+ export { CalendarEventValidationError, CalendarRecipe, EVENTS_MODULE_META, EVENTS_UI_SLOTS, Event, EventAsset, EventAssetCollection, EventCollection, EventParticipant, EventParticipantCollection, EventSeries, EventSeriesCollection, EventType, EventTypeCollection, calculateDuration, calculateNextOccurrence, checkSchedulingConflict, expandICalendarEvents, expandRecurrence, formatDuration, formatEventDateRange, fromZonedWallTime, generateEventSlug, getEventStatusFromDates, isEventNow, isValidTimeZone, parseICalendarEvents, parseRecurrencePattern, sortEventsByDate, syncICalendarSource, toZonedWallTime, validateEventStatus };
1886
1977
 
1887
1978
  //# sourceMappingURL=index.js.map