@timardex/cluemart-shared 1.2.32 → 1.2.34

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.
Files changed (42) hide show
  1. package/dist/{ad-Cv1V8lgJ.d.ts → ad-BZylIpez.d.ts} +1 -1
  2. package/dist/{ad-IVwm5MLY.d.mts → ad-CiYcsJB7.d.mts} +1 -1
  3. package/dist/{auth-BCxQp_CF.d.ts → auth-CmaB99NK.d.ts} +1 -1
  4. package/dist/{auth-BczaOu28.d.mts → auth-DDtMJHZw.d.mts} +1 -1
  5. package/dist/formFields/index.cjs +0 -7
  6. package/dist/formFields/index.cjs.map +1 -1
  7. package/dist/formFields/index.d.mts +1 -1
  8. package/dist/formFields/index.d.ts +1 -1
  9. package/dist/formFields/index.mjs +0 -7
  10. package/dist/formFields/index.mjs.map +1 -1
  11. package/dist/{global-Bnr6l_NH.d.ts → global-DVYSZ6LR.d.ts} +4 -4
  12. package/dist/{global-_89-F0iL.d.mts → global-ExJZRDGR.d.mts} +4 -4
  13. package/dist/graphql/index.d.mts +2 -2
  14. package/dist/graphql/index.d.ts +2 -2
  15. package/dist/hooks/index.cjs +1 -0
  16. package/dist/hooks/index.cjs.map +1 -1
  17. package/dist/hooks/index.d.mts +3 -3
  18. package/dist/hooks/index.d.ts +3 -3
  19. package/dist/hooks/index.mjs +1 -0
  20. package/dist/hooks/index.mjs.map +1 -1
  21. package/dist/index.cjs +13 -48
  22. package/dist/index.cjs.map +1 -1
  23. package/dist/index.d.mts +6 -13
  24. package/dist/index.d.ts +6 -13
  25. package/dist/index.mjs +11 -45
  26. package/dist/index.mjs.map +1 -1
  27. package/dist/mongoose/index.cjs.map +1 -1
  28. package/dist/mongoose/index.d.mts +3 -3
  29. package/dist/mongoose/index.d.ts +3 -3
  30. package/dist/mongoose/index.mjs +4 -4
  31. package/dist/mongoose/index.mjs.map +1 -1
  32. package/dist/service/index.cjs +17 -49
  33. package/dist/service/index.cjs.map +1 -1
  34. package/dist/service/index.d.mts +4 -11
  35. package/dist/service/index.d.ts +4 -11
  36. package/dist/service/index.mjs +10 -40
  37. package/dist/service/index.mjs.map +1 -1
  38. package/dist/types/index.d.mts +3 -3
  39. package/dist/types/index.d.ts +3 -3
  40. package/dist/utils/index.d.mts +1 -1
  41. package/dist/utils/index.d.ts +1 -1
  42. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/mongoose/index.ts","../../src/mongoose/Ad.ts","../../src/enums/index.ts","../../src/types/global.ts","../../src/types/ad.ts","../../src/types/resourceActivities.ts","../../src/mongoose/global.ts","../../src/mongoose/Relation.ts","../../src/mongoose/event/EventInfo.ts","../../src/mongoose/Chat.ts","../../src/mongoose/Notification.ts","../../src/mongoose/PushToken.ts","../../src/mongoose/ResourceActivity.ts","../../src/mongoose/Testers.ts","../../src/mongoose/User.ts","../../src/mongoose/VerificationToken.ts","../../src/mongoose/vendor/Vendor.ts","../../src/mongoose/vendor/VendorInfo.ts","../../src/mongoose/event/Event.ts"],"sourcesContent":["export * from \"./Ad\";\nexport * from \"./Chat\";\nexport * from \"./global\";\nexport * from \"./Notification\";\nexport * from \"./PushToken\";\nexport * from \"./Relation\";\nexport * from \"./ResourceActivity\";\nexport * from \"./Testers\";\nexport * from \"./User\";\nexport * from \"./VerificationToken\";\nexport * from \"./vendor/Vendor\";\nexport * from \"./vendor/VendorInfo\";\nexport * from \"./event/Event\";\nexport * from \"./event/EventInfo\";\n","import mongoose from \"mongoose\";\n\nimport { EnumResourceType } from \"src/enums\";\nimport {\n AdType,\n EnumAdShowOn,\n EnumAdStatus,\n EnumAdStyle,\n EnumAdType,\n} from \"src/types\";\n\nimport { SocialMediaTypeSchema } from \"./global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst schema = new MongooseSchema<AdType>(\n {\n active: { default: true, type: Boolean },\n adStyle: {\n default: EnumAdStyle.BLOOM,\n enum: Object.values(EnumAdStyle),\n required: true,\n type: String,\n },\n adType: {\n default: EnumAdType.SPONSORED,\n enum: Object.values(EnumAdType),\n required: true,\n type: String,\n },\n // TODO: similar to ViewSchema\n clicks: { default: 0, required: true, type: Number },\n clui: { required: false, type: String },\n end: { required: true, type: Date },\n // TODO: similar to ViewSchema\n impressions: { default: 0, required: true, type: Number },\n resourceCover: { required: true, type: String },\n resourceDescription: { required: true, type: String },\n resourceId: { required: true, type: String },\n resourceLogo: { required: false, type: String },\n resourceName: { required: true, type: String },\n resourceRegion: { required: true, type: String },\n resourceType: {\n enum: Object.values(EnumResourceType),\n required: true,\n type: String,\n },\n showOn: {\n default: EnumAdShowOn.FRONT_PAGE,\n enum: Object.values(EnumAdShowOn),\n required: true,\n type: String,\n },\n socialMedia: [SocialMediaTypeSchema],\n start: { required: true, type: Date },\n status: {\n default: EnumAdStatus.ACTIVE,\n enum: Object.values(EnumAdStatus),\n required: true,\n type: String,\n },\n targetRegion: { required: false, type: String },\n },\n {\n timestamps: true,\n },\n);\n\n// Compound index for background job queries\nschema.index({\n end: 1,\n start: 1,\n status: 1,\n});\n\nexport const AdModel =\n (mongoose.models.Ad as mongoose.Model<AdType>) ||\n mongoose.model<AdType>(\"Ad\", schema);\n","export enum EnumInviteStatus {\n ACCEPTED = \"Accepted\",\n COMPLETED = \"Completed\",\n EXPIRED = \"Expired\",\n NO_STATUS = \"No_Status\",\n PAID = \"Paid\",\n PENDING = \"Pending\",\n REJECTED = \"Rejected\",\n UNAVAILABLE = \"Unavailable\",\n WAITING = \"Waiting\",\n}\n\nexport enum EnumChatType {\n GROUP = \"group\",\n PRIVATE = \"private\",\n RELATION = \"relation\",\n}\n\nexport enum EnumPaymentMethod {\n CASH = \"cash\",\n EFTPOS = \"eftpos\",\n BANK_TRANSFER = \"bank_transfer\",\n PAYPAL = \"paypal\",\n STRIPE = \"stripe\",\n}\n\nexport enum EnumFoodFlavor {\n SALTY = \"Salty\",\n SAVOURY = \"Savoury\",\n SPICY = \"Spicy\",\n SWEET = \"Sweet\",\n}\n\nexport enum EnumResourceType {\n EVENT = \"event\",\n VENDOR = \"vendor\",\n}\n\nexport enum EnumEventType {\n EXPO = \"Expo\",\n FAIR = \"Fair\",\n FESTIVAL = \"Festival\",\n MARKET = \"Market\",\n}\n\nexport enum EnumVendorType {\n STALLHOLDER = \"Stallholder\",\n SHOP = \"Shop\",\n CHARITY = \"Charity\",\n}\n\nexport enum EnumOSPlatform {\n ANDROID = \"android\",\n IOS = \"ios\",\n WEB = \"web\",\n}\n\nexport enum EnumRelationResource {\n EVENT_INVITE_VENDOR = \"event_invite_vendor\",\n VENDOR_APPLICATION_TO_EVENT = \"vendor_application_to_event\",\n}\n\nexport enum EnumNotificationResourceType {\n ADDED_AS_PARTNER_EVENT = \"added_as_partner_event\",\n ADDED_AS_PARTNER_VENDOR = \"added_as_partner_vendor\",\n APPROVED_EVENT = \"approved_event\",\n APPROVED_VENDOR = \"approved_vendor\",\n CREATED_EVENT = \"created_event\",\n CREATED_VENDOR = \"created_vendor\",\n EVENT_INVITE_VENDOR = EnumRelationResource.EVENT_INVITE_VENDOR,\n EVENT_STARTING_SOON = \"event_starting_soon\",\n NEW_CHAT_MESSAGE = \"new_chat_message\",\n VENDOR_APPLICATION_TO_EVENT = EnumRelationResource.VENDOR_APPLICATION_TO_EVENT,\n}\n\nexport enum EnumNotificationType {\n EVENT = EnumResourceType.EVENT,\n VENDOR = EnumResourceType.VENDOR,\n RELATION = \"relation\",\n CHAT = \"chat\",\n SYSTEM = \"system\",\n}\n\nexport enum EnumRegions {\n Auckland = \"Auckland\",\n BayOfPlentyGisborne = \"Bay of Plenty & Gisborne\",\n Canterbury = \"Canterbury\",\n HawkesBay = \"Hawke's Bay\",\n ManawatuWanganui = \"Manawatu-Wanganui\",\n MarlboroughNelson = \"Marlborough & Nelson\",\n Northland = \"Northland\",\n SouthlandOtago = \"Southland & Otago\",\n Taranaki = \"Taranaki\",\n Waikato = \"Waikato\",\n Wellington = \"Wellington\",\n TasmanWestCoast = \"Tasman & West Coast\",\n}\n\nexport enum ImageTypeEnum {\n AVATAR = \"avatar\",\n COVER = \"cover\",\n IMAGE = \"image\",\n LOGO = \"logo\",\n}\n\nexport enum EnumUserLicence {\n PRO_EVENT = \"pro_event\",\n PRO_PLUS_EVENT = \"pro_plus_event\",\n PRO_PLUS_VENDOR = \"pro_plus_vendor\",\n PRO_VENDOR = \"pro_vendor\",\n STANDARD_EVENT = \"standard_event\",\n STANDARD_VENDOR = \"standard_vendor\",\n}\n\nexport enum EnumUserRole {\n ADMIN = \"admin\",\n CUSTOMER = \"customer\",\n MARKETING = \"marketing\",\n MODERATOR = \"moderator\",\n SUPPORT = \"support\",\n}\n\nexport enum EnumSocialMedia {\n FACEBOOK = \"facebook\",\n INSTAGRAM = \"instagram\",\n TIKTOK = \"tiktok\",\n TWITTER = \"twitter\",\n WEBSITE = \"website\",\n YOUTUBE = \"youtube\",\n}\n","import { Request } from \"express\";\nimport mongoose from \"mongoose\";\nimport {\n Control,\n FieldErrors,\n FieldValues,\n UseFormHandleSubmit,\n UseFormReset,\n UseFormSetValue,\n UseFormWatch,\n} from \"react-hook-form\";\n\nimport { SchemaChatType } from \"src/mongoose/Chat\";\nimport { SchemaNotificationType } from \"src/mongoose/Notification\";\n\nimport { EnumResourceType, EnumSocialMedia, EnumUserLicence } from \"../enums\";\n\nimport { EventType } from \"./event\";\nimport { NotificationCount } from \"./notification\";\nimport { RelationDate } from \"./relation\";\nimport { VendorType } from \"./vendor\";\n\nexport type Nullable<T> = {\n [K in keyof T]: T[K] | null | undefined;\n};\n\nexport type DeviceInfo = {\n appBuildNumber: string;\n appId: string;\n appVersion: string;\n brand: string;\n deviceName: string;\n installationId: string;\n manufacturer: string;\n modelName: string;\n osName: string;\n osVersion: string;\n timestamp: string;\n};\n\nexport type TermsAgreement = DeviceInfo & {\n termVersion: string;\n};\n\nexport type ResourceContactDetailsType = {\n email?: string | null;\n landlinePhone?: string | null;\n mobilePhone?: string | null;\n};\n\nexport type ResourceImageType = {\n source: string;\n title: string;\n};\n\nexport type SocialMediaType = {\n name?: EnumSocialMedia;\n link?: string;\n};\n\nexport type PartnerType = {\n email: string;\n resourceId: string;\n resourceType: EnumResourceType;\n licence: EnumUserLicence;\n};\n\nexport type OwnerType = {\n email: string;\n userId: string;\n};\n\nexport interface BaseResourceTypeFormData {\n _id?: string;\n active: boolean;\n contactDetails?: ResourceContactDetailsType | null;\n cover: ResourceImageType;\n coverUpload?: ResourceImageType | null;\n description: string;\n images?: ResourceImageType[] | null;\n imagesUpload?: ResourceImageType[] | null;\n logo?: ResourceImageType | null;\n logoUpload?: ResourceImageType | null;\n name: string;\n owner?: OwnerType | null;\n partners?: PartnerType[] | null;\n promoCodes?: string[] | null;\n region: string;\n socialMedia?: SocialMediaType[] | null;\n termsAgreement?: TermsAgreement | null;\n}\n\nexport type PosterUsageType = {\n month: string;\n count: number;\n};\n\nexport type BaseResourceType = Omit<\n BaseResourceTypeFormData,\n \"_id\" | \"coverUpload\" | \"imagesUpload\" | \"logoUpload\" | \"owner\"\n> & {\n _id: string;\n adIds?: string[] | null;\n createdAt: string;\n deletedAt: string | null;\n owner: OwnerType;\n posterUsage?: PosterUsageType | null;\n relations:\n | {\n relationId: string | null;\n relationDates: RelationDate[] | null;\n }[]\n | null;\n updatedAt: string;\n};\n\nexport type LocationType = {\n city: string;\n coordinates: number[]; // [longitude, latitude]\n country: string;\n fullAddress: string;\n latitude: number;\n longitude: number;\n region: string;\n type: \"Point\"; // Mongoose GeoJSON type\n};\n\nexport type DateTimeType = {\n endDate: string;\n endTime: string;\n startDate: string;\n startTime: string;\n};\n\nexport type Region = {\n latitude: number;\n latitudeDelta: number;\n longitude: number;\n longitudeDelta: number;\n};\n\nexport type GeocodeLocation = Pick<LocationType, \"latitude\" | \"longitude\">;\n\nexport type MapMultiLocation = {\n dateTime: DateTimeType | null;\n location: LocationType | null;\n resourceId?: string;\n resourceName?: string;\n resourceType?: EnumResourceType;\n};\n\nexport interface FormField {\n disabled?: boolean;\n helperText?: string;\n isTextArea?: boolean;\n keyboardType?:\n | \"default\"\n | \"email-address\"\n | \"number-pad\"\n | \"url\"\n | \"decimal-pad\"\n | \"phone-pad\";\n name: string;\n placeholder: string;\n secureTextEntry?: boolean;\n}\n\nexport interface FormDateField {\n dateMode: \"date\" | \"time\";\n helperText?: string;\n name: \"endDate\" | \"endTime\" | \"startDate\" | \"startTime\";\n placeholder: string;\n}\n\nexport interface SubcategoryItems {\n id: string;\n name: string;\n description?: string | null;\n}\n\nexport interface Subcategory {\n id: string;\n name: string;\n items?: SubcategoryItems[] | null;\n}\n\nexport interface Category {\n color?: string | null;\n description?: string | null;\n id: string;\n name: string;\n subcategories: Subcategory[];\n}\n\nexport type OptionItem = {\n value: string;\n label: string;\n};\n\nexport type ImageObjectType = {\n uri: string;\n type: string;\n name: string;\n};\n\nexport interface ResourceConnectionsType {\n events: EventType[] | null;\n vendors: VendorType[] | null;\n}\n\nexport interface CreateFormData<T extends FieldValues> {\n control: Control<T, any>;\n fields: T;\n formState: { errors: FieldErrors<T> };\n handleSubmit: UseFormHandleSubmit<T, any>;\n reset: UseFormReset<T>;\n setValue: UseFormSetValue<T>;\n watch: UseFormWatch<T>;\n}\n\nexport type ObjectId = mongoose.Schema.Types.ObjectId;\n\nexport enum EnumPubSubEvents {\n GET_CHAT_MESSAGE = \"GET_CHAT_MESSAGE\",\n GET_NOTIFICATIONS = \"GET_NOTIFICATIONS\",\n GET_NOTIFICATIONS_COUNT = \"GET_NOTIFICATIONS_COUNT\",\n USER_TYPING = \"USER_TYPING\",\n}\n\nexport interface AuthUser {\n email: string;\n role: string;\n userId: ObjectId;\n}\n\nexport interface SubscriptionPayload {\n getChatMessage?: SchemaChatType;\n userTyping?: SchemaChatType; // NOT USED\n getNotifications?: SchemaNotificationType[];\n // Used only for filtering; not part of the GraphQL schema output\n getNotificationsUserId?: ObjectId;\n getNotificationsCount?: NotificationCount & { userId: ObjectId };\n}\n\nexport interface GraphQLContext {\n user: AuthUser | null;\n pubsub: {\n publish: (\n eventName: EnumPubSubEvents,\n payload: SubscriptionPayload,\n ) => void;\n subscribe: (eventName: EnumPubSubEvents) => AsyncIterable<any>;\n };\n request: Request;\n response: Response;\n}\n\nexport { mongoose };\n","import { EnumResourceType } from \"src/enums\";\n\nimport { CreateFormData, SocialMediaType } from \"./global\";\n\nexport enum EnumAdShowOn {\n FRONT_PAGE = \"Front_page\",\n EVENTS_PAGE = \"Events_page\",\n VENDORS_PAGE = \"Vendors_page\",\n}\n\nexport enum EnumAdStatus {\n ACTIVE = \"Active\",\n PAUSED = \"Paused\",\n EXPIRED = \"Expired\",\n}\n\nexport enum EnumAdType {\n SPONSORED = \"Sponsored\",\n FREE = \"Free\",\n}\n\nexport enum EnumAdStyle {\n BLOOM = \"Bloom\",\n RISE = \"Rise\",\n}\n\nexport interface AdFormData {\n active: boolean;\n adStyle: EnumAdStyle;\n adType: EnumAdType;\n clui?: string | null;\n end: Date; // ISO date string\n resourceCover: string;\n resourceDescription: string;\n resourceId: string;\n resourceLogo?: string | null;\n resourceName: string;\n resourceRegion: string;\n resourceType: EnumResourceType;\n showOn: EnumAdShowOn;\n socialMedia?: SocialMediaType[] | null;\n start?: Date; // ISO date string\n status: EnumAdStatus;\n targetRegion?: string | null;\n}\n\nexport type CreateAdFormData = CreateFormData<AdFormData>;\n\nexport interface AdType extends AdFormData {\n _id: string;\n clicks?: number; // How many times the ad was clicked\n createdAt: Date;\n impressions?: number; // How often the ad was seen\n start: Date; // ISO date string\n updatedAt: Date;\n}\n","import { EnumOSPlatform, EnumResourceType } from \"src/enums\";\n\nexport enum EnumActivity {\n FAVORITE = \"FAVORITE\",\n GOING = \"GOING\",\n INTERESTED = \"INTERESTED\",\n PRESENT = \"PRESENT\",\n VIEW = \"VIEW\",\n}\n\nexport type ResourceActivityEntry = {\n activityType: EnumActivity;\n location: {\n type: \"Point\";\n coordinates: number[]; // [longitude, latitude]\n } | null;\n startDate?: string | null;\n startTime?: string | null;\n timestamp: Date;\n userAgent: EnumOSPlatform;\n userId?: string | null;\n};\n\nexport type ResourceActivityType = {\n _id: string;\n resourceType: EnumResourceType;\n resourceId: string;\n activity: ResourceActivityEntry[];\n};\n\nexport type ResourceActivityInputType = {\n resourceId: string;\n resourceType: string;\n activity: Omit<ResourceActivityEntry, \"timestamp\">;\n};\n","import mongoose from \"mongoose\";\n\nimport { EnumResourceType, EnumUserLicence } from \"src/enums\";\nimport {\n Category,\n ObjectId,\n OwnerType,\n PartnerType,\n PosterUsageType,\n RelationDate,\n ResourceContactDetailsType,\n ResourceImageType,\n SocialMediaType,\n Subcategory,\n TermsAgreement,\n} from \"src/types\";\n\nimport { relationDatesSchema } from \"./Relation\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaOwnerType = Omit<OwnerType, \"userId\"> & {\n userId: ObjectId;\n};\n\nconst OwnerTypeSchema = new MongooseSchema<SchemaOwnerType>(\n {\n email: { required: true, type: String },\n userId: {\n ref: \"User\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport const SocialMediaTypeSchema = new MongooseSchema<SocialMediaType>(\n {\n link: { required: true, type: String },\n name: { required: true, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field\n);\n\nexport const ResourceImageTypeSchema = new MongooseSchema<ResourceImageType>(\n {\n source: { required: false, type: String },\n title: { required: false, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst SubCategorySchema = new MongooseSchema<Subcategory>(\n {\n id: { required: false, type: String },\n items: [\n {\n id: { required: false, type: String },\n name: { required: false, type: String },\n },\n ],\n name: { required: false, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport const CategorySchema = new MongooseSchema<Category>(\n {\n id: { required: true, type: String },\n name: { required: true, type: String },\n subcategories: [SubCategorySchema],\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst PosterUsageTypeSchema = new MongooseSchema<PosterUsageType>(\n {\n count: { default: 0, required: false, type: Number },\n month: { required: false, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport const partnersSchema = new MongooseSchema<PartnerType>(\n {\n email: { required: false, type: String },\n licence: {\n enum: Object.values(EnumUserLicence),\n required: false,\n type: String,\n },\n resourceId: {\n required: false,\n type: String,\n },\n resourceType: {\n enum: Object.values(EnumResourceType),\n required: false,\n type: String,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst ContactDetailsSchema = new MongooseSchema<ResourceContactDetailsType>(\n {\n email: { required: false, type: String },\n landlinePhone: { required: false, type: String },\n mobilePhone: { required: false, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport const termsAgreementSchema = new MongooseSchema<TermsAgreement>(\n {\n appBuildNumber: { required: true, type: String },\n appId: { required: true, type: String },\n appVersion: { required: true, type: String },\n brand: { required: true, type: String },\n deviceName: { required: true, type: String },\n installationId: { required: true, type: String },\n manufacturer: { required: true, type: String },\n modelName: { required: true, type: String },\n osName: { required: true, type: String },\n osVersion: { required: true, type: String },\n termVersion: { required: true, type: String },\n timestamp: { required: true, type: String },\n },\n { _id: false },\n);\n\nconst resourceRelationsSchema = new MongooseSchema<{\n relationId: ObjectId;\n relationDates: RelationDate[];\n}>(\n {\n relationDates: {\n default: [],\n required: false,\n type: [relationDatesSchema],\n },\n relationId: {\n ref: \"Relation\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { _id: false },\n);\n\nexport const baseResourceFields = {\n active: { default: false, required: true, type: Boolean },\n adIds: {\n ref: \"Ad\",\n required: false,\n type: [mongoose.Schema.Types.ObjectId],\n },\n contactDetails: ContactDetailsSchema,\n cover: ResourceImageTypeSchema,\n deletedAt: { default: null, required: false, type: Date },\n description: { required: true, type: String },\n images: [ResourceImageTypeSchema],\n logo: ResourceImageTypeSchema,\n name: { required: true, type: String },\n owner: OwnerTypeSchema,\n partners: {\n required: false,\n type: [partnersSchema],\n },\n posterUsage: PosterUsageTypeSchema,\n promoCodes: { required: false, type: [String] },\n region: { required: true, type: String },\n relations: {\n default: [],\n required: false,\n type: [resourceRelationsSchema],\n },\n socialMedia: [SocialMediaTypeSchema],\n termsAgreement: termsAgreementSchema,\n};\n","import mongoose from \"mongoose\";\n\nimport {\n EnumInviteStatus,\n EnumRelationResource,\n EnumResourceType,\n} from \"src/enums\";\nimport { ObjectId, RelationDate, RelationType } from \"src/types\";\n\nimport { StallTypeSchema } from \"./event/EventInfo\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport const relationDatesSchema = new MongooseSchema<RelationDate>(\n {\n lastUpdateBy: {\n resourceId: { required: false, type: String },\n userEmail: { required: false, type: String },\n },\n paymentReference: { required: false, type: String },\n stallType: StallTypeSchema,\n startDate: { required: false, type: String },\n startTime: { required: false, type: String },\n status: {\n enum: Object.values(EnumInviteStatus),\n required: false,\n type: String,\n },\n },\n { _id: false },\n);\n\nexport type SchemaRelationType = Omit<\n RelationType,\n \"chatId\" | \"eventId\" | \"vendorId\"\n> & {\n chatId: ObjectId;\n eventId: ObjectId;\n vendorId: ObjectId;\n};\n/**\n * This is the schema for the relation type.\n * It is used to define the structure of the relation type in the database.\n * The schema is used by Mongoose to create a model for the relation type.\n */\nexport const RelationTypeSchema = new MongooseSchema<SchemaRelationType>(\n {\n active: { default: true, required: true, type: Boolean },\n chatId: {\n ref: \"Chat\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n deletedAt: { default: null, required: false, type: Date },\n eventId: {\n ref: \"Event\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n lastUpdateBy: {\n enum: Object.values(EnumResourceType),\n required: true,\n type: String,\n },\n relationDates: [relationDatesSchema],\n relationType: {\n enum: Object.values(EnumRelationResource),\n required: true,\n type: String,\n },\n vendorId: {\n ref: \"Vendor\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { timestamps: true },\n);\n\nRelationTypeSchema.index({\n \"relationDates.startDate\": 1,\n \"relationDates.startTime\": 1,\n \"relationDates.status\": 1,\n});\n\n// --- IMPORTANT: bind custom model type ---\nexport const RelationModel =\n (mongoose.models.Relation as mongoose.Model<SchemaRelationType>) ||\n mongoose.model<SchemaRelationType>(\"Relation\", RelationTypeSchema);\n","import mongoose from \"mongoose\";\n\nimport { EnumPaymentMethod } from \"src/enums\";\nimport {\n DateTimeWithPriceType,\n EventInfoType,\n ObjectId,\n PaymentInfoType,\n Requirement,\n StallType,\n} from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport const StallTypeSchema = new MongooseSchema<StallType>(\n {\n electricity: {\n price: { required: false, type: Number },\n selected: { required: false, type: Boolean },\n },\n label: { required: false, type: String },\n price: { required: false, type: Number },\n stallCapacity: { required: false, type: Number },\n },\n {\n _id: false, // Prevents Mongoose from creating an additional _id field for subdocuments\n },\n);\n\nconst dateTimeSchema = new MongooseSchema<DateTimeWithPriceType>(\n {\n endDate: { required: true, type: String },\n endTime: { required: true, type: String },\n stallTypes: [StallTypeSchema],\n startDate: { required: true, type: String },\n startTime: { required: true, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst paymentInfoSchema = new MongooseSchema<PaymentInfoType>(\n {\n accountHolderName: { required: false, type: String },\n accountNumber: { required: false, type: String },\n link: { required: false, type: String },\n paymentMethod: {\n enum: Object.values(EnumPaymentMethod),\n required: true,\n type: String,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field\n);\n\nconst requirementsSchema = new MongooseSchema<Requirement>(\n {\n category: { required: true, type: String },\n label: { required: true, type: String },\n value: { required: true, type: Boolean },\n },\n {\n _id: false, // Prevents Mongoose from creating an additional _id field for\n },\n);\n\nexport type SchemaEventInfoType = Omit<EventInfoType, \"eventId\"> & {\n eventId: ObjectId;\n};\n\n/**\n * This is the schema for the event info type.\n * It is used to define the structure of the event info type in the database.\n * The schema is used by Mongoose to create a model for the event info type.\n */\nconst schema = new MongooseSchema<SchemaEventInfoType>(\n {\n applicationDeadlineHours: { required: true, type: Number },\n dateTime: [dateTimeSchema],\n eventId: {\n ref: \"Event\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n packInTime: { required: true, type: Number },\n paymentDueHours: { required: true, type: Number },\n paymentInfo: [paymentInfoSchema],\n requirements: [requirementsSchema],\n },\n { timestamps: true },\n);\n\nexport const EventInfoModel =\n (mongoose.models.EventInfo as mongoose.Model<SchemaEventInfoType>) ||\n mongoose.model<SchemaEventInfoType>(\"EventInfo\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumChatType } from \"src/enums\";\nimport {\n ChatMessageType,\n ChatType,\n ObjectId,\n ParticipantType,\n} from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaChatMessageType = Omit<ChatMessageType, \"senderId\"> & {\n senderId: ObjectId;\n};\n\nexport type SchemaParticipantType = Omit<ParticipantType, \"userId\"> & {\n userId: ObjectId;\n};\n\nconst MessageSchema = new MongooseSchema<SchemaChatMessageType>(\n {\n content: { required: true, type: String },\n senderAvatar: { required: false, type: String },\n senderId: {\n ref: \"User\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n senderName: { required: true, type: String },\n },\n { timestamps: true },\n);\n\nexport type SchemaChatType = Omit<\n ChatType,\n \"participants\" | \"messages\" | \"resourceInfo\"\n> & {\n participants: SchemaParticipantType[];\n messages: SchemaChatMessageType[];\n resourceInfo: { eventId: ObjectId; vendorId: ObjectId } | null;\n};\n\nexport const ParticipantSchema = new MongooseSchema<SchemaParticipantType>(\n {\n active: { default: true, required: true, type: Boolean },\n email: { required: true, type: String },\n userId: {\n ref: \"User\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst ChatSchema = new MongooseSchema<SchemaChatType>(\n {\n active: { default: true, required: true, type: Boolean },\n chatName: { required: true, type: String },\n chatType: {\n enum: Object.values(EnumChatType),\n required: true,\n type: String,\n },\n deletedAt: { default: null, required: false, type: Date },\n messages: [MessageSchema],\n participants: [ParticipantSchema],\n resourceInfo: {\n eventId: {\n ref: \"Event\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n vendorId: {\n ref: \"Vendor\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n },\n {\n timestamps: true,\n },\n);\n\nexport const ChatModel =\n (mongoose.models.Chat as mongoose.Model<SchemaChatType>) ||\n mongoose.model<SchemaChatType>(\"Chat\", ChatSchema);\n","import mongoose from \"mongoose\";\n\nimport { EnumNotificationResourceType, EnumNotificationType } from \"src/enums\";\nimport {\n CreateBulkNotificationInput,\n NotificationType,\n ObjectId,\n} from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaCreateBulkNotificationInput = Omit<\n CreateBulkNotificationInput,\n \"userIds\"\n> & {\n userIds: ObjectId[];\n};\n\nexport type SchemaNotificationType = Omit<NotificationType, \"userId\"> & {\n userId: ObjectId;\n};\n/**\n * Schema for storing in-app notifications\n * Each notification is tied to a specific user and can be marked as read/unread\n */\nconst schema = new MongooseSchema<SchemaNotificationType>(\n {\n data: {\n resourceId: { required: true, type: String },\n resourceName: { required: true, type: String },\n resourceType: {\n enum: Object.values(EnumNotificationResourceType),\n required: true,\n type: String,\n },\n },\n isRead: { default: false, index: true, required: true, type: Boolean },\n message: { required: true, type: String },\n title: { required: true, type: String },\n type: {\n default: EnumNotificationType.SYSTEM,\n enum: Object.values(EnumNotificationType),\n required: true,\n type: String,\n },\n userId: {\n ref: \"User\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { timestamps: true },\n);\n\n// Compound index for efficient queries\nschema.index({ isRead: 1, userId: 1 });\nschema.index({ createdAt: -1, userId: 1 });\n\nexport const NotificationModel =\n (mongoose.models.Notification as mongoose.Model<SchemaNotificationType>) ||\n mongoose.model<SchemaNotificationType>(\"Notification\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumOSPlatform } from \"src/enums\";\nimport { ObjectId } from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\ntype PushTokenType = {\n _id: string;\n createdAt: Date;\n platform: EnumOSPlatform;\n token: string;\n updatedAt: Date;\n userId: string;\n};\n\nexport type SchemaPushTokenType = Omit<PushTokenType, \"userId\"> & {\n userId: ObjectId;\n};\n\n/**\n * This is the schema for the push token type.\n * It is used to define the structure of the push token type in the database.\n * The schema is used by Mongoose to create a model for the push token type.\n */\nconst schema = new MongooseSchema<SchemaPushTokenType>(\n {\n platform: {\n enum: Object.values(EnumOSPlatform),\n required: true,\n type: String,\n },\n token: { required: true, type: String },\n userId: { required: true, type: mongoose.Schema.Types.ObjectId },\n },\n { timestamps: true },\n);\n\nexport const PushTokenModel =\n (mongoose.models.PushToken as mongoose.Model<SchemaPushTokenType>) ||\n mongoose.model<SchemaPushTokenType>(\"PushToken\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumOSPlatform, EnumResourceType } from \"src/enums\";\nimport {\n EnumActivity,\n ResourceActivityEntry,\n ResourceActivityType,\n} from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst ActivitySchema = new MongooseSchema<ResourceActivityEntry>(\n {\n activityType: {\n enum: Object.values(EnumActivity),\n required: true,\n type: String,\n },\n location: {\n coordinates: {\n required: false,\n type: [Number],\n },\n type: {\n default: \"Point\",\n enum: [\"Point\"],\n required: false,\n type: String,\n },\n },\n startDate: { required: false, type: String },\n startTime: { required: false, type: String },\n timestamp: { default: Date.now, type: Date },\n userAgent: {\n enum: Object.values(EnumOSPlatform),\n required: true,\n type: String,\n },\n userId: { required: false, type: String },\n },\n { _id: false },\n);\n\nconst schema = new MongooseSchema<ResourceActivityType>(\n {\n activity: { default: [], type: [ActivitySchema] },\n resourceId: { required: true, type: String },\n resourceType: {\n enum: Object.values(EnumResourceType),\n required: true,\n type: String,\n },\n },\n { timestamps: true },\n);\n\nschema.index({ resourceId: 1, resourceType: 1 }, { unique: true }); // one per entity\nschema.index({ \"views.location\": \"2dsphere\" });\n\nexport const ResourceActivityModel =\n (mongoose.models.ResourceActivity as mongoose.Model<ResourceActivityType>) ||\n mongoose.model<ResourceActivityType>(\"ResourceActivity\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumOSPlatform, EnumResourceType } from \"src/enums\";\nimport { TesterType } from \"src/types\";\n\nimport { CategorySchema } from \"./global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst TesterSchema = new MongooseSchema<TesterType>(\n {\n active: { default: false, required: true, type: Boolean },\n categories: [CategorySchema],\n companyName: { required: true, type: String },\n email: { required: true, type: String },\n firstName: { required: true, type: String },\n lastName: { required: true, type: String },\n osType: {\n enum: Object.values(EnumOSPlatform),\n required: true,\n type: String,\n },\n region: { required: true, type: String },\n resourceType: {\n enum: Object.values(EnumResourceType),\n required: true,\n type: String,\n },\n },\n {\n timestamps: true,\n },\n);\n\nexport const TesterModel =\n (mongoose.models.Tester as mongoose.Model<TesterType>) ||\n mongoose.model<TesterType>(\"Tester\", TesterSchema);\n","import mongoose from \"mongoose\";\n\nimport { EnumOSPlatform, EnumUserLicence, EnumUserRole } from \"src/enums\";\nimport { ObjectId, UserActivityEvent, UserType } from \"src/types\";\n\nimport {\n partnersSchema,\n ResourceImageTypeSchema,\n termsAgreementSchema,\n} from \"./global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaUserActivityEvent = Omit<UserActivityEvent, \"resourceId\"> & {\n resourceId: ObjectId;\n};\n\nexport type SchemaUserType = Omit<\n UserType,\n \"vendor\" | \"events\" | \"userActivity\" | \"_id\"\n> & {\n _id: ObjectId;\n vendor: ObjectId;\n events: ObjectId[];\n userActivity: {\n favourites: {\n events: ObjectId[];\n vendors: ObjectId[];\n };\n interested: {\n events: SchemaUserActivityEvent[];\n };\n going: {\n events: SchemaUserActivityEvent[];\n };\n present: {\n events: SchemaUserActivityEvent[];\n };\n };\n};\n\nconst userActivityEventSchema = new MongooseSchema<SchemaUserActivityEvent>(\n {\n resourceId: {\n ref: \"Event\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n startDate: { required: false, type: String },\n startTime: { required: false, type: String },\n },\n { _id: false },\n);\n\nconst userActivityFavouritesSchema = new MongooseSchema(\n {\n events: {\n ref: \"Event\",\n required: false,\n type: [mongoose.Schema.Types.ObjectId],\n },\n vendors: {\n ref: \"Vendor\",\n required: false,\n type: [mongoose.Schema.Types.ObjectId],\n },\n },\n { _id: false },\n);\n\n/**\n * This is the schema for the user type.\n * It is used to define the structure of the user type in the database.\n * The schema is used by Mongoose to create a model for the user type.\n */\nconst schema = new MongooseSchema<SchemaUserType>(\n {\n active: { default: false, required: true, type: Boolean },\n avatar: ResourceImageTypeSchema,\n deletedAt: { default: null, required: false, type: Date },\n email: { required: true, type: String },\n events: {\n ref: \"Event\",\n required: false,\n type: [mongoose.Schema.Types.ObjectId],\n },\n firstName: { required: true, type: String },\n isTester: { default: false, required: false, type: Boolean },\n lastName: { required: true, type: String },\n licences: {\n enum: Object.values(EnumUserLicence),\n required: false,\n type: [String],\n },\n partners: {\n required: false,\n type: [partnersSchema],\n },\n password: { required: true, type: String },\n platform: {\n enum: Object.values(EnumOSPlatform),\n required: false,\n type: String,\n },\n preferredRegion: {\n required: true,\n type: String,\n },\n refreshToken: {\n required: false,\n type: String,\n },\n role: {\n default: EnumUserRole.CUSTOMER,\n enum: Object.values(EnumUserRole),\n required: true,\n type: String,\n },\n termsAgreement: termsAgreementSchema,\n userActivity: {\n favourites: {\n default: () => ({ events: [], vendors: [] }),\n type: userActivityFavouritesSchema,\n },\n going: {\n events: [userActivityEventSchema],\n },\n interested: {\n events: [userActivityEventSchema],\n },\n present: {\n events: [userActivityEventSchema],\n },\n },\n vendor: {\n ref: \"Vendor\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { timestamps: true },\n);\n\nschema.index({ \"partners.email\": 1 });\n\nexport const UserModel =\n (mongoose.models.User as mongoose.Model<SchemaUserType>) ||\n mongoose.model<SchemaUserType>(\"User\", schema);\n","import mongoose from \"mongoose\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport interface VerificationTokenType {\n email: string;\n verificationToken: string;\n createdAt: Date;\n}\n\nconst schema = new MongooseSchema<VerificationTokenType>(\n {\n createdAt: {\n default: Date.now,\n expires: 24 * 60 * 60, // 24 hours in seconds (MongoDB TTL expects seconds)\n required: true,\n type: Date,\n }, // Token expires after 1 day\n email: { required: true, type: String },\n verificationToken: { required: true, type: String },\n },\n { timestamps: true },\n);\n\nexport const VerificationTokenModel =\n (mongoose.models.VerificationToken as mongoose.Model<VerificationTokenType>) ||\n mongoose.model<VerificationTokenType>(\"VerificationToken\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumVendorType } from \"src/enums\";\nimport { ObjectId, VendorMenuType, VendorType } from \"src/types\";\n\nimport { baseResourceFields, CategorySchema, SchemaOwnerType } from \"../global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst MenuTypeSchema = new MongooseSchema<VendorMenuType>(\n {\n description: { required: false, type: String },\n name: { required: false, type: String },\n price: { required: false, type: Number },\n productGroups: { required: false, type: [String] },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst LocationsSchema = new MongooseSchema<VendorType[\"locations\"]>(\n {\n dateTime: {\n endDate: { required: false, type: String },\n endTime: { required: false, type: String },\n startDate: { required: false, type: String },\n startTime: { required: false, type: String },\n },\n description: { required: false, type: String },\n location: {\n city: { required: false, type: String },\n coordinates: {\n required: false,\n type: [Number], // [longitude, latitude]\n },\n country: { required: false, type: String },\n fullAddress: { required: false, type: String },\n latitude: { required: false, type: Number },\n longitude: { required: false, type: Number },\n region: { required: false, type: String },\n type: { required: false, type: String }, // Mongoose GeoJSON type\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport type SchemaVendorType = Omit<\n VendorType,\n \"vendorInfoId\" | \"owner\" | \"adIds\"\n> & {\n adIds?: ObjectId[];\n owner: SchemaOwnerType;\n vendorInfoId: ObjectId;\n};\n\nconst schema = new MongooseSchema<SchemaVendorType>(\n {\n ...baseResourceFields, // Importing base resource fields from global.ts\n availability: {\n corporate: { default: false, required: false, type: Boolean },\n private: { default: false, required: false, type: Boolean },\n school: { default: false, required: false, type: Boolean },\n },\n categories: [CategorySchema],\n locations: [LocationsSchema],\n multiLocation: { required: true, type: Boolean },\n products: [MenuTypeSchema],\n vendorInfoId: {\n ref: \"VendorInfo\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n vendorType: {\n enum: Object.values(EnumVendorType),\n required: true,\n type: String,\n },\n },\n { timestamps: true },\n);\n\n// 🔹 Add indexes to speed up regex-based searches\nschema.index({ name: 1 });\nschema.index({ description: 1 });\nschema.index({ region: 1 });\nschema.index({ \"categories.name\": 1 });\nschema.index({ \"partners.email\": 1 });\n\nexport const VendorModel =\n (mongoose.models.Vendor as mongoose.Model<SchemaVendorType>) ||\n mongoose.model<SchemaVendorType>(\"Vendor\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumFoodFlavor } from \"src/enums\";\nimport { ObjectId, VendorAttributes, VendorInfoType } from \"src/types\";\n\nimport { ResourceImageTypeSchema } from \"../global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaVendorInfoType = Omit<VendorInfoType, \"vendorId\"> & {\n vendorId: ObjectId;\n};\n\nconst AttributesSchema = new MongooseSchema<VendorAttributes>(\n {\n details: { required: false, type: String },\n isRequired: { default: false, required: true, type: Boolean },\n },\n { _id: false },\n);\n\nconst schema = new MongooseSchema<SchemaVendorInfoType>(\n {\n compliance: {\n foodBeverageLicense: { default: false, required: false, type: Boolean },\n liabilityInsurance: { default: false, required: false, type: Boolean },\n },\n documents: [ResourceImageTypeSchema],\n product: {\n foodFlavors: {\n enum: Object.values(EnumFoodFlavor),\n required: true,\n type: [String],\n },\n packaging: { required: true, type: [String] },\n priceRange: {\n max: { required: true, type: Number },\n min: { required: true, type: Number },\n },\n producedIn: { required: true, type: [String] },\n },\n requirements: {\n electricity: AttributesSchema,\n gazebo: AttributesSchema,\n table: AttributesSchema,\n },\n stallInfo: {\n size: {\n depth: { required: true, type: Number },\n width: { required: true, type: Number },\n },\n },\n vendorId: {\n ref: \"Vendor\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { timestamps: true },\n);\n\nexport const VendorInfoModel =\n (mongoose.models.VendorInfo as mongoose.Model<SchemaVendorInfoType>) ||\n mongoose.model<SchemaVendorInfoType>(\"VendorInfo\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumEventType } from \"src/enums\";\nimport { DateTimeType, EventType, LocationType, ObjectId } from \"src/types\";\n\nimport { baseResourceFields, SchemaOwnerType } from \"../global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst locationsSchema = new MongooseSchema<LocationType>(\n {\n city: { required: true, type: String },\n coordinates: {\n required: true,\n type: [Number], // [longitude, latitude]\n },\n country: { required: true, type: String },\n fullAddress: { required: true, type: String },\n latitude: { required: true, type: Number },\n longitude: { required: true, type: Number },\n region: { required: true, type: String },\n type: {\n default: \"Point\",\n enum: [\"Point\"],\n required: true,\n type: String,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst dateTimeSchema = new MongooseSchema<DateTimeType>(\n {\n endDate: { required: true, type: String },\n endTime: { required: true, type: String },\n startDate: { required: true, type: String },\n startTime: { required: true, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport type SchemaEventType = Omit<\n EventType,\n \"eventInfoId\" | \"owner\" | \"adIds\"\n> & {\n adIds?: ObjectId[];\n eventInfoId: ObjectId;\n owner: SchemaOwnerType;\n};\n\n/**\n * This is the schema for the event type.\n * It is used to define the structure of the event type in the database.\n * The schema is used by Mongoose to create a model for the event type.\n */\nconst schema = new MongooseSchema<SchemaEventType>(\n {\n ...baseResourceFields, // Importing base resource fields from global.ts\n dateTime: [dateTimeSchema],\n eventInfoId: {\n ref: \"EventInfo\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n eventType: {\n enum: Object.values(EnumEventType),\n required: true,\n type: String,\n },\n location: {\n required: true,\n type: locationsSchema,\n },\n nzbn: { required: true, type: String },\n provider: { required: false, type: String },\n rainOrShine: { required: true, type: Boolean },\n tags: { required: true, type: [String] },\n },\n { timestamps: true },\n);\n\n// 🔹 Add indexes to speed up regex-based searches\nschema.index({ name: 1 });\nschema.index({ description: 1 });\nschema.index({ region: 1 });\nschema.index({ location: \"2dsphere\" });\nschema.index({ tags: 1 });\nschema.index({ \"partners.email\": 1 });\n\nexport const EventModel =\n (mongoose.models.Event as mongoose.Model<SchemaEventType>) ||\n mongoose.model<SchemaEventType>(\"Event\", schema);\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,mBAAqB;;;ACAd,IAAK,mBAAL,kBAAKC,sBAAL;AACL,EAAAA,kBAAA,cAAW;AACX,EAAAA,kBAAA,eAAY;AACZ,EAAAA,kBAAA,aAAU;AACV,EAAAA,kBAAA,eAAY;AACZ,EAAAA,kBAAA,UAAO;AACP,EAAAA,kBAAA,aAAU;AACV,EAAAA,kBAAA,cAAW;AACX,EAAAA,kBAAA,iBAAc;AACd,EAAAA,kBAAA,aAAU;AATA,SAAAA;AAAA,GAAA;AAYL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,WAAQ;AACR,EAAAA,cAAA,aAAU;AACV,EAAAA,cAAA,cAAW;AAHD,SAAAA;AAAA,GAAA;AAML,IAAK,oBAAL,kBAAKC,uBAAL;AACL,EAAAA,mBAAA,UAAO;AACP,EA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M,OAAO;AAAA,EAC5C;AAAA,EACA,EAAE,KAAK,MAAM;AAAA;AACf;AAgBA,IAAMG,WAAS,IAAIH;AAAA,EACjB;AAAA,IACE,GAAG;AAAA;AAAA,IACH,UAAU,CAACE,eAAc;AAAA,IACzB,aAAa;AAAA,MACX,KAAK;AAAA,MACL,UAAU;AAAA,MACV,MAAM,kBAAAD,QAAS,OAAO,MAAM;AAAA,IAC9B;AAAA,IACA,WAAW;AAAA,MACT,MAAM,OAAO,OAAO,aAAa;AAAA,MACjC,UAAU;AAAA,MACV,MAAM;AAAA,IACR;AAAA,IACA,UAAU;AAAA,MACR,UAAU;AAAA,MACV,MAAM;AAAA,IACR;AAAA,IACA,MAAM,EAAE,UAAU,MAAM,MAAM,OAAO;AAAA,IACrC,UAAU,EAAE,UAAU,OAAO,MAAM,OAAO;AAAA,IAC1C,aAAa,EAAE,UAAU,MAAM,MAAM,QAAQ;AAAA,IAC7C,MAAM,EAAE,UAAU,MAAM,MAAM,CAAC,MAAM,EAAE;AAAA,EACzC;AAAA,EACA,EAAE,YAAY,KAAK;AACrB;AAGAE,SAAO,MAAM,EAAE,MAAM,EAAE,CAAC;AACxBA,SAAO,MAAM,EAAE,aAAa,EAAE,CAAC;AAC/BA,SAAO,MAAM,EAAE,QAAQ,EAAE,CAAC;AAC1BA,SAAO,MAAM,EAAE,UAAU,WAAW,CAAC;AACrCA,SAAO,MAAM,EAAE,MAAM,EAAE,CAAC;AACxBA,SAAO,MAAM,EAAE,kBAAkB,EAAE,CAAC;AAE7B,IAAM,aACV,kBAAAF,QAAS,OAAO,SACjB,kBAAAA,QAAS,MAAuB,SAASE,QAAM;","names":["import_mongoose","EnumInviteStatus","EnumChatType","EnumPaymentMethod","EnumFoodFlavor","EnumResourceType","EnumEventType","EnumVendorType","EnumOSPlatform","EnumRelationResource","EnumNotificationResourceType","EnumNotificationType","EnumUserLicence","EnumUserRole","EnumAdShowOn","EnumAdStatus","EnumAdType","EnumAdStyle","EnumActivity","import_mongoose","import_mongoose","import_mongoose","mongoose","MongooseSchema","mongoose","MongooseSchema","mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","dateTimeSchema","schema"]}
1
+ {"version":3,"sources":["../../src/mongoose/index.ts","../../src/mongoose/Ad.ts","../../src/enums/index.ts","../../src/types/global.ts","../../src/types/ad.ts","../../src/types/resourceActivities.ts","../../src/mongoose/global.ts","../../src/mongoose/Relation.ts","../../src/mongoose/event/EventInfo.ts","../../src/mongoose/Chat.ts","../../src/mongoose/Notification.ts","../../src/mongoose/PushToken.ts","../../src/mongoose/ResourceActivity.ts","../../src/mongoose/Testers.ts","../../src/mongoose/User.ts","../../src/mongoose/VerificationToken.ts","../../src/mongoose/vendor/Vendor.ts","../../src/mongoose/vendor/VendorInfo.ts","../../src/mongoose/event/Event.ts"],"sourcesContent":["export * from \"./Ad\";\nexport * from \"./Chat\";\nexport * from \"./global\";\nexport * from \"./Notification\";\nexport * from \"./PushToken\";\nexport * from \"./Relation\";\nexport * from \"./ResourceActivity\";\nexport * from \"./Testers\";\nexport * from \"./User\";\nexport * from \"./VerificationToken\";\nexport * from \"./vendor/Vendor\";\nexport * from \"./vendor/VendorInfo\";\nexport * from \"./event/Event\";\nexport * from \"./event/EventInfo\";\n","import mongoose from \"mongoose\";\n\nimport { EnumResourceType } from \"src/enums\";\nimport {\n AdType,\n EnumAdShowOn,\n EnumAdStatus,\n EnumAdStyle,\n EnumAdType,\n} from \"src/types\";\n\nimport { SocialMediaTypeSchema } from \"./global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst schema = new MongooseSchema<AdType>(\n {\n active: { default: true, type: Boolean },\n adStyle: {\n default: EnumAdStyle.BLOOM,\n enum: Object.values(EnumAdStyle),\n required: true,\n type: String,\n },\n adType: {\n default: EnumAdType.SPONSORED,\n enum: Object.values(EnumAdType),\n required: true,\n type: String,\n },\n // TODO: similar to ViewSchema\n clicks: { default: 0, required: true, type: Number },\n clui: { required: false, type: String },\n end: { required: true, type: Date },\n // TODO: similar to ViewSchema\n impressions: { default: 0, required: true, type: Number },\n resourceCover: { required: true, type: String },\n resourceDescription: { required: true, type: String },\n resourceId: { required: true, type: String },\n resourceLogo: { required: false, type: String },\n resourceName: { required: true, type: String },\n resourceRegion: { required: true, type: String },\n resourceType: {\n enum: Object.values(EnumResourceType),\n required: true,\n type: String,\n },\n showOn: {\n default: EnumAdShowOn.FRONT_PAGE,\n enum: Object.values(EnumAdShowOn),\n required: true,\n type: String,\n },\n socialMedia: [SocialMediaTypeSchema],\n start: { required: true, type: Date },\n status: {\n default: EnumAdStatus.ACTIVE,\n enum: Object.values(EnumAdStatus),\n required: true,\n type: String,\n },\n targetRegion: { required: false, type: String },\n },\n {\n timestamps: true,\n },\n);\n\n// Compound index for background job queries\nschema.index({\n end: 1,\n start: 1,\n status: 1,\n});\n\nexport const AdModel =\n (mongoose.models.Ad as mongoose.Model<AdType>) ||\n mongoose.model<AdType>(\"Ad\", schema);\n","export enum EnumInviteStatus {\n ACCEPTED = \"Accepted\",\n COMPLETED = \"Completed\",\n EXPIRED = \"Expired\",\n NO_STATUS = \"No_Status\",\n PAID = \"Paid\",\n PENDING = \"Pending\",\n REJECTED = \"Rejected\",\n UNAVAILABLE = \"Unavailable\",\n WAITING = \"Waiting\",\n}\n\nexport enum EnumChatType {\n GROUP = \"group\",\n PRIVATE = \"private\",\n RELATION = \"relation\",\n}\n\nexport enum EnumPaymentMethod {\n CASH = \"cash\",\n EFTPOS = \"eftpos\",\n BANK_TRANSFER = \"bank_transfer\",\n PAYPAL = \"paypal\",\n STRIPE = \"stripe\",\n}\n\nexport enum EnumFoodFlavor {\n SALTY = \"Salty\",\n SAVOURY = \"Savoury\",\n SPICY = \"Spicy\",\n SWEET = \"Sweet\",\n}\n\nexport enum EnumResourceType {\n EVENT = \"event\",\n VENDOR = \"vendor\",\n}\n\nexport enum EnumEventType {\n EXPO = \"Expo\",\n FAIR = \"Fair\",\n FESTIVAL = \"Festival\",\n MARKET = \"Market\",\n}\n\nexport enum EnumVendorType {\n STALLHOLDER = \"Stallholder\",\n SHOP = \"Shop\",\n CHARITY = \"Charity\",\n}\n\nexport enum EnumOSPlatform {\n ANDROID = \"android\",\n IOS = \"ios\",\n WEB = \"web\",\n}\n\nexport enum EnumRelationResource {\n EVENT_INVITE_VENDOR = \"event_invite_vendor\",\n VENDOR_APPLICATION_TO_EVENT = \"vendor_application_to_event\",\n}\n\nexport enum EnumNotificationResourceType {\n ADDED_AS_PARTNER_EVENT = \"added_as_partner_event\",\n ADDED_AS_PARTNER_VENDOR = \"added_as_partner_vendor\",\n APPROVED_EVENT = \"approved_event\",\n APPROVED_VENDOR = \"approved_vendor\",\n CREATED_EVENT = \"created_event\",\n CREATED_VENDOR = \"created_vendor\",\n EVENT_INVITE_VENDOR = EnumRelationResource.EVENT_INVITE_VENDOR,\n EVENT_STARTING_SOON = \"event_starting_soon\",\n NEW_CHAT_MESSAGE = \"new_chat_message\",\n VENDOR_APPLICATION_TO_EVENT = EnumRelationResource.VENDOR_APPLICATION_TO_EVENT,\n}\n\nexport enum EnumNotificationType {\n EVENT = EnumResourceType.EVENT,\n VENDOR = EnumResourceType.VENDOR,\n RELATION = \"relation\",\n CHAT = \"chat\",\n SYSTEM = \"system\",\n}\n\nexport enum EnumRegions {\n Auckland = \"Auckland\",\n BayOfPlentyGisborne = \"Bay of Plenty & Gisborne\",\n Canterbury = \"Canterbury\",\n HawkesBay = \"Hawke's Bay\",\n ManawatuWanganui = \"Manawatu-Wanganui\",\n MarlboroughNelson = \"Marlborough & Nelson\",\n Northland = \"Northland\",\n SouthlandOtago = \"Southland & Otago\",\n Taranaki = \"Taranaki\",\n Waikato = \"Waikato\",\n Wellington = \"Wellington\",\n TasmanWestCoast = \"Tasman & West Coast\",\n}\n\nexport enum ImageTypeEnum {\n AVATAR = \"avatar\",\n COVER = \"cover\",\n IMAGE = \"image\",\n LOGO = \"logo\",\n}\n\nexport enum EnumUserLicence {\n PRO_EVENT = \"pro_event\",\n PRO_PLUS_EVENT = \"pro_plus_event\",\n PRO_PLUS_VENDOR = \"pro_plus_vendor\",\n PRO_VENDOR = \"pro_vendor\",\n STANDARD_EVENT = \"standard_event\",\n STANDARD_VENDOR = \"standard_vendor\",\n}\n\nexport enum EnumUserRole {\n ADMIN = \"admin\",\n CUSTOMER = \"customer\",\n MARKETING = \"marketing\",\n MODERATOR = \"moderator\",\n SUPPORT = \"support\",\n}\n\nexport enum EnumSocialMedia {\n FACEBOOK = \"facebook\",\n INSTAGRAM = \"instagram\",\n TIKTOK = \"tiktok\",\n TWITTER = \"twitter\",\n WEBSITE = \"website\",\n YOUTUBE = \"youtube\",\n}\n","import { Request } from \"express\";\nimport mongoose from \"mongoose\";\nimport {\n Control,\n FieldErrors,\n FieldValues,\n UseFormHandleSubmit,\n UseFormReset,\n UseFormSetValue,\n UseFormWatch,\n} from \"react-hook-form\";\n\nimport { SchemaChatType } from \"src/mongoose/Chat\";\nimport { SchemaNotificationType } from \"src/mongoose/Notification\";\n\nimport { EnumResourceType, EnumSocialMedia, EnumUserLicence } from \"../enums\";\n\nimport { EventType } from \"./event\";\nimport { NotificationCount } from \"./notification\";\nimport { RelationDate } from \"./relation\";\nimport { VendorType } from \"./vendor\";\n\nexport type Nullable<T> = {\n [K in keyof T]: T[K] | null | undefined;\n};\n\nexport type DeviceInfo = {\n appBuildNumber: string;\n appId: string;\n appVersion: string;\n brand: string;\n deviceName: string;\n installationId: string;\n manufacturer: string;\n modelName: string;\n osName: string;\n osVersion: string;\n timestamp: string;\n};\n\nexport type TermsAgreement = DeviceInfo & {\n termVersion: string;\n};\n\nexport type ResourceContactDetailsType = {\n email?: string | null;\n landlinePhone?: string | null;\n mobilePhone?: string | null;\n};\n\nexport type ResourceImageType = {\n source: string;\n title: string;\n};\n\nexport type SocialMediaType = {\n name?: EnumSocialMedia;\n link?: string;\n};\n\nexport type PartnerType = {\n email: string;\n resourceId: string;\n resourceType: EnumResourceType;\n licence: EnumUserLicence;\n};\n\nexport type OwnerType = {\n email: string;\n userId: string;\n};\n\nexport interface BaseResourceTypeFormData {\n _id?: string;\n active: boolean;\n contactDetails?: ResourceContactDetailsType | null;\n cover: ResourceImageType;\n coverUpload?: ResourceImageType | null;\n description: string;\n images?: ResourceImageType[] | null;\n imagesUpload?: ResourceImageType[] | null;\n logo?: ResourceImageType | null;\n logoUpload?: ResourceImageType | null;\n name: string;\n owner?: OwnerType | null;\n partners?: PartnerType[] | null;\n promoCodes?: string[] | null;\n region: string;\n socialMedia?: SocialMediaType[] | null;\n termsAgreement?: TermsAgreement | null;\n}\n\nexport type PosterUsageType = {\n month: string;\n count: number;\n};\n\nexport type BaseResourceType = Omit<\n BaseResourceTypeFormData,\n \"_id\" | \"coverUpload\" | \"imagesUpload\" | \"logoUpload\" | \"owner\"\n> & {\n _id: string;\n adIds?: string[] | null;\n createdAt: string;\n deletedAt: string | null;\n owner: OwnerType;\n posterUsage?: PosterUsageType | null;\n relations:\n | {\n relationId: string | null;\n relationDates: RelationDate[] | null;\n }[]\n | null;\n updatedAt: string;\n};\n\nexport type LocationType = {\n city: string;\n coordinates: number[]; // [longitude, latitude]\n country: string;\n fullAddress: string;\n latitude: number;\n longitude: number;\n region: string;\n type: \"Point\"; // Mongoose GeoJSON type\n};\n\nexport type DateTimeType = {\n endDate: string;\n endTime: string;\n startDate: string;\n startTime: string;\n};\n\nexport type Region = {\n latitude: number;\n latitudeDelta: number;\n longitude: number;\n longitudeDelta: number;\n};\n\nexport type GeocodeLocation = Pick<LocationType, \"latitude\" | \"longitude\">;\n\nexport type MapMultiLocation = {\n dateTime: DateTimeType | null;\n location: LocationType | null;\n resourceId?: string;\n resourceName?: string;\n resourceType?: EnumResourceType;\n};\n\nexport interface FormField {\n disabled?: boolean;\n helperText?: string;\n isTextArea?: boolean;\n keyboardType?:\n | \"default\"\n | \"email-address\"\n | \"number-pad\"\n | \"url\"\n | \"decimal-pad\"\n | \"phone-pad\";\n name: string;\n placeholder: string;\n secureTextEntry?: boolean;\n}\n\nexport interface FormDateField {\n dateMode: \"date\" | \"time\";\n helperText?: string;\n name: \"endDate\" | \"endTime\" | \"startDate\" | \"startTime\";\n placeholder: string;\n}\n\nexport interface SubcategoryItems {\n id: string;\n name: string;\n description?: string | null;\n}\n\nexport interface Subcategory {\n id: string;\n name: string;\n items?: SubcategoryItems[] | null;\n}\n\nexport interface Category {\n color?: string | null;\n description?: string | null;\n id: string;\n name: string;\n subcategories: Subcategory[];\n}\n\nexport type OptionItem = {\n value: string;\n label: string;\n};\n\nexport type ImageObjectType = {\n uri: string;\n type: string;\n name: string;\n};\n\nexport interface ResourceConnectionsType {\n events: EventType[] | null;\n vendors: VendorType[] | null;\n}\n\nexport interface CreateFormData<T extends FieldValues> {\n control: Control<T, any>;\n fields: T;\n formState: { errors: FieldErrors<T> };\n handleSubmit: UseFormHandleSubmit<T, any>;\n reset: UseFormReset<T>;\n setValue: UseFormSetValue<T>;\n watch: UseFormWatch<T>;\n}\n\nexport type ObjectId = mongoose.Schema.Types.ObjectId;\n\nexport enum EnumPubSubEvents {\n GET_CHAT_MESSAGE = \"GET_CHAT_MESSAGE\",\n GET_NOTIFICATIONS = \"GET_NOTIFICATIONS\",\n GET_NOTIFICATIONS_COUNT = \"GET_NOTIFICATIONS_COUNT\",\n USER_TYPING = \"USER_TYPING\",\n}\n\nexport interface AuthUser {\n email: string;\n role: string;\n userId: ObjectId;\n}\n\nexport interface SubscriptionPayload {\n getChatMessage?: SchemaChatType;\n userTyping?: SchemaChatType; // NOT USED\n getNotifications?: SchemaNotificationType[];\n // Used only for filtering; not part of the GraphQL schema output\n getNotificationsUserId?: ObjectId;\n getNotificationsCount?: NotificationCount & { userId: ObjectId };\n}\n\nexport interface GraphQLContext {\n user: AuthUser | null;\n pubsub: {\n publish: (\n eventName: EnumPubSubEvents,\n payload: SubscriptionPayload,\n ) => void;\n subscribe: (eventName: EnumPubSubEvents) => AsyncIterable<any>;\n };\n request: Request;\n response: Response;\n}\n\nexport { mongoose };\n","import { EnumResourceType } from \"src/enums\";\n\nimport { CreateFormData, SocialMediaType } from \"./global\";\n\nexport enum EnumAdShowOn {\n FRONT_PAGE = \"Front_page\",\n EVENTS_PAGE = \"Events_page\",\n VENDORS_PAGE = \"Vendors_page\",\n}\n\nexport enum EnumAdStatus {\n ACTIVE = \"Active\",\n PAUSED = \"Paused\",\n EXPIRED = \"Expired\",\n}\n\nexport enum EnumAdType {\n SPONSORED = \"Sponsored\",\n FREE = \"Free\",\n}\n\nexport enum EnumAdStyle {\n BLOOM = \"Bloom\",\n RISE = \"Rise\",\n}\n\nexport interface AdFormData {\n active: boolean;\n adStyle: EnumAdStyle;\n adType: EnumAdType;\n clui?: string | null;\n end: Date; // ISO date string\n resourceCover: string;\n resourceDescription: string;\n resourceId: string;\n resourceLogo?: string | null;\n resourceName: string;\n resourceRegion: string;\n resourceType: EnumResourceType;\n showOn: EnumAdShowOn;\n socialMedia?: SocialMediaType[] | null;\n start?: Date; // ISO date string\n status: EnumAdStatus;\n targetRegion?: string | null;\n}\n\nexport type CreateAdFormData = CreateFormData<AdFormData>;\n\nexport interface AdType extends AdFormData {\n _id: string;\n clicks?: number; // How many times the ad was clicked\n createdAt: Date;\n impressions?: number; // How often the ad was seen\n start: Date; // ISO date string\n updatedAt: Date;\n}\n","import { EnumOSPlatform, EnumResourceType } from \"src/enums\";\n\nexport enum EnumActivity {\n FAVORITE = \"FAVORITE\",\n GOING = \"GOING\",\n INTERESTED = \"INTERESTED\",\n PRESENT = \"PRESENT\",\n VIEW = \"VIEW\",\n}\n\nexport type ResourceActivityEntry = {\n activityType: EnumActivity;\n location: {\n type: \"Point\";\n coordinates: number[]; // [longitude, latitude]\n } | null;\n startDate?: string | null;\n startTime?: string | null;\n timestamp: Date;\n userAgent: EnumOSPlatform;\n userId?: string | null;\n};\n\nexport type ResourceActivityType = {\n _id: string;\n resourceType: EnumResourceType;\n resourceId: string;\n activity: ResourceActivityEntry[];\n};\n\nexport type ResourceActivityInputType = {\n resourceId: string;\n resourceType: string;\n activity: Omit<ResourceActivityEntry, \"timestamp\">;\n};\n","import mongoose from \"mongoose\";\n\nimport { EnumResourceType, EnumUserLicence } from \"src/enums\";\nimport {\n Category,\n ObjectId,\n OwnerType,\n PartnerType,\n PosterUsageType,\n RelationDate,\n ResourceContactDetailsType,\n ResourceImageType,\n SocialMediaType,\n Subcategory,\n TermsAgreement,\n} from \"src/types\";\n\nimport { relationDatesSchema } from \"./Relation\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaOwnerType = Omit<OwnerType, \"userId\"> & {\n userId: ObjectId;\n};\n\nconst OwnerTypeSchema = new MongooseSchema<SchemaOwnerType>(\n {\n email: { required: true, type: String },\n userId: {\n ref: \"User\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport const SocialMediaTypeSchema = new MongooseSchema<SocialMediaType>(\n {\n link: { required: true, type: String },\n name: { required: true, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field\n);\n\nexport const ResourceImageTypeSchema = new MongooseSchema<ResourceImageType>(\n {\n source: { required: false, type: String },\n title: { required: false, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst SubCategorySchema = new MongooseSchema<Subcategory>(\n {\n id: { required: false, type: String },\n items: [\n {\n id: { required: false, type: String },\n name: { required: false, type: String },\n },\n ],\n name: { required: false, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport const CategorySchema = new MongooseSchema<Category>(\n {\n id: { required: true, type: String },\n name: { required: true, type: String },\n subcategories: [SubCategorySchema],\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst PosterUsageTypeSchema = new MongooseSchema<PosterUsageType>(\n {\n count: { default: 0, required: false, type: Number },\n month: { required: false, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport const partnersSchema = new MongooseSchema<PartnerType>(\n {\n email: { required: false, type: String },\n licence: {\n enum: Object.values(EnumUserLicence),\n required: false,\n type: String,\n },\n resourceId: {\n required: false,\n type: String,\n },\n resourceType: {\n enum: Object.values(EnumResourceType),\n required: false,\n type: String,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst ContactDetailsSchema = new MongooseSchema<ResourceContactDetailsType>(\n {\n email: { required: false, type: String },\n landlinePhone: { required: false, type: String },\n mobilePhone: { required: false, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport const termsAgreementSchema = new MongooseSchema<TermsAgreement>(\n {\n appBuildNumber: { required: true, type: String },\n appId: { required: true, type: String },\n appVersion: { required: true, type: String },\n brand: { required: true, type: String },\n deviceName: { required: true, type: String },\n installationId: { required: true, type: String },\n manufacturer: { required: true, type: String },\n modelName: { required: true, type: String },\n osName: { required: true, type: String },\n osVersion: { required: true, type: String },\n termVersion: { required: true, type: String },\n timestamp: { required: true, type: String },\n },\n { _id: false },\n);\n\nconst resourceRelationsSchema = new MongooseSchema<{\n relationId: ObjectId;\n relationDates: RelationDate[];\n}>(\n {\n relationDates: {\n default: [],\n required: false,\n type: [relationDatesSchema],\n },\n relationId: {\n ref: \"Relation\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { _id: false },\n);\n\nexport const baseResourceFields = {\n active: { default: false, required: true, type: Boolean },\n adIds: {\n ref: \"Ad\",\n required: false,\n type: [mongoose.Schema.Types.ObjectId],\n },\n contactDetails: ContactDetailsSchema,\n cover: ResourceImageTypeSchema,\n deletedAt: { default: null, required: false, type: Date },\n description: { required: true, type: String },\n images: [ResourceImageTypeSchema],\n logo: ResourceImageTypeSchema,\n name: { required: true, type: String },\n owner: OwnerTypeSchema,\n partners: {\n required: false,\n type: [partnersSchema],\n },\n posterUsage: PosterUsageTypeSchema,\n promoCodes: { required: false, type: [String] },\n region: { required: true, type: String },\n relations: {\n default: [],\n required: false,\n type: [resourceRelationsSchema],\n },\n socialMedia: [SocialMediaTypeSchema],\n termsAgreement: termsAgreementSchema,\n};\n","import mongoose from \"mongoose\";\n\nimport {\n EnumInviteStatus,\n EnumRelationResource,\n EnumResourceType,\n} from \"src/enums\";\nimport { ObjectId, RelationDate, RelationType } from \"src/types\";\n\nimport { StallTypeSchema } from \"./event/EventInfo\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport const relationDatesSchema = new MongooseSchema<RelationDate>(\n {\n lastUpdateBy: {\n resourceId: { required: false, type: String },\n userEmail: { required: false, type: String },\n },\n paymentReference: { required: false, type: String },\n stallType: StallTypeSchema,\n startDate: { required: false, type: String },\n startTime: { required: false, type: String },\n status: {\n enum: Object.values(EnumInviteStatus),\n required: false,\n type: String,\n },\n },\n { _id: false },\n);\n\nexport type SchemaRelationType = Omit<\n RelationType,\n \"chatId\" | \"eventId\" | \"vendorId\"\n> & {\n chatId: ObjectId;\n eventId: ObjectId;\n vendorId: ObjectId;\n};\n/**\n * This is the schema for the relation type.\n * It is used to define the structure of the relation type in the database.\n * The schema is used by Mongoose to create a model for the relation type.\n */\nexport const RelationTypeSchema = new MongooseSchema<SchemaRelationType>(\n {\n active: { default: true, required: true, type: Boolean },\n chatId: {\n ref: \"Chat\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n deletedAt: { default: null, required: false, type: Date },\n eventId: {\n ref: \"Event\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n lastUpdateBy: {\n enum: Object.values(EnumResourceType),\n required: true,\n type: String,\n },\n relationDates: [relationDatesSchema],\n relationType: {\n enum: Object.values(EnumRelationResource),\n required: true,\n type: String,\n },\n vendorId: {\n ref: \"Vendor\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { timestamps: true },\n);\n\nRelationTypeSchema.index({\n \"relationDates.startDate\": 1,\n \"relationDates.startTime\": 1,\n \"relationDates.status\": 1,\n});\n\n// --- IMPORTANT: bind custom model type ---\nexport const RelationModel =\n (mongoose.models.Relation as mongoose.Model<SchemaRelationType>) ||\n mongoose.model<SchemaRelationType>(\"Relation\", RelationTypeSchema);\n","import mongoose from \"mongoose\";\n\nimport { EnumPaymentMethod } from \"src/enums\";\nimport {\n DateTimeWithPriceType,\n EventInfoType,\n ObjectId,\n PaymentInfoType,\n Requirement,\n StallType,\n} from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport const StallTypeSchema = new MongooseSchema<StallType>(\n {\n electricity: {\n price: { required: false, type: Number },\n selected: { required: false, type: Boolean },\n },\n label: { required: false, type: String },\n price: { required: false, type: Number },\n stallCapacity: { required: false, type: Number },\n },\n {\n _id: false, // Prevents Mongoose from creating an additional _id field for subdocuments\n },\n);\n\nconst dateTimeSchema = new MongooseSchema<DateTimeWithPriceType>(\n {\n endDate: { required: true, type: String },\n endTime: { required: true, type: String },\n stallTypes: [StallTypeSchema],\n startDate: { required: true, type: String },\n startTime: { required: true, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst paymentInfoSchema = new MongooseSchema<PaymentInfoType>(\n {\n accountHolderName: { required: false, type: String },\n accountNumber: { required: false, type: String },\n link: { required: false, type: String },\n paymentMethod: {\n enum: Object.values(EnumPaymentMethod),\n required: true,\n type: String,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field\n);\n\nconst requirementsSchema = new MongooseSchema<Requirement>(\n {\n category: { required: true, type: String },\n label: { required: true, type: String },\n value: { required: true, type: Boolean },\n },\n {\n _id: false, // Prevents Mongoose from creating an additional _id field for\n },\n);\n\nexport type SchemaEventInfoType = Omit<EventInfoType, \"eventId\"> & {\n eventId: ObjectId;\n};\n\n/**\n * This is the schema for the event info type.\n * It is used to define the structure of the event info type in the database.\n * The schema is used by Mongoose to create a model for the event info type.\n */\nconst schema = new MongooseSchema<SchemaEventInfoType>(\n {\n applicationDeadlineHours: { required: true, type: Number },\n dateTime: [dateTimeSchema],\n eventId: {\n ref: \"Event\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n packInTime: { required: true, type: Number },\n paymentDueHours: { required: true, type: Number },\n paymentInfo: [paymentInfoSchema],\n requirements: [requirementsSchema],\n },\n { timestamps: true },\n);\n\nexport const EventInfoModel =\n (mongoose.models.EventInfo as mongoose.Model<SchemaEventInfoType>) ||\n mongoose.model<SchemaEventInfoType>(\"EventInfo\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumChatType } from \"src/enums\";\nimport {\n ChatMessageType,\n ChatType,\n ObjectId,\n ParticipantType,\n} from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaChatMessageType = Omit<ChatMessageType, \"senderId\"> & {\n senderId: ObjectId;\n};\n\nexport type SchemaParticipantType = Omit<ParticipantType, \"userId\"> & {\n userId: ObjectId;\n};\n\nconst MessageSchema = new MongooseSchema<SchemaChatMessageType>(\n {\n content: { required: true, type: String },\n senderAvatar: { required: false, type: String },\n senderId: {\n ref: \"User\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n senderName: { required: true, type: String },\n },\n { timestamps: true },\n);\n\nexport type SchemaChatType = Omit<\n ChatType,\n \"participants\" | \"messages\" | \"resourceInfo\"\n> & {\n participants: SchemaParticipantType[];\n messages: SchemaChatMessageType[];\n resourceInfo: { eventId: ObjectId; vendorId: ObjectId } | null;\n};\n\nexport const ParticipantSchema = new MongooseSchema<SchemaParticipantType>(\n {\n active: { default: true, required: true, type: Boolean },\n email: { required: true, type: String },\n userId: {\n ref: \"User\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst ChatSchema = new MongooseSchema<SchemaChatType>(\n {\n active: { default: true, required: true, type: Boolean },\n chatName: { required: true, type: String },\n chatType: {\n enum: Object.values(EnumChatType),\n required: true,\n type: String,\n },\n deletedAt: { default: null, required: false, type: Date },\n messages: [MessageSchema],\n participants: [ParticipantSchema],\n resourceInfo: {\n eventId: {\n ref: \"Event\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n vendorId: {\n ref: \"Vendor\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n },\n {\n timestamps: true,\n },\n);\n\nexport const ChatModel =\n (mongoose.models.Chat as mongoose.Model<SchemaChatType>) ||\n mongoose.model<SchemaChatType>(\"Chat\", ChatSchema);\n","import mongoose from \"mongoose\";\n\nimport { EnumNotificationResourceType, EnumNotificationType } from \"src/enums\";\nimport {\n CreateBulkNotificationInput,\n NotificationType,\n ObjectId,\n} from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaCreateBulkNotificationInput = Omit<\n CreateBulkNotificationInput,\n \"userIds\"\n> & {\n userIds: ObjectId[];\n};\n\nexport type SchemaNotificationType = Omit<NotificationType, \"userId\"> & {\n userId: ObjectId;\n};\n/**\n * Schema for storing in-app notifications\n * Each notification is tied to a specific user and can be marked as read/unread\n */\nconst schema = new MongooseSchema<SchemaNotificationType>(\n {\n data: {\n resourceId: { required: true, type: String },\n resourceName: { required: true, type: String },\n resourceType: {\n enum: Object.values(EnumNotificationResourceType),\n required: true,\n type: String,\n },\n },\n isRead: { default: false, index: true, required: true, type: Boolean },\n message: { required: true, type: String },\n title: { required: true, type: String },\n type: {\n default: EnumNotificationType.SYSTEM,\n enum: Object.values(EnumNotificationType),\n required: true,\n type: String,\n },\n userId: {\n ref: \"User\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { timestamps: true },\n);\n\n// Compound index for efficient queries\nschema.index({ isRead: 1, userId: 1 });\nschema.index({ createdAt: -1, userId: 1 });\n\nexport const NotificationModel =\n (mongoose.models.Notification as mongoose.Model<SchemaNotificationType>) ||\n mongoose.model<SchemaNotificationType>(\"Notification\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumOSPlatform } from \"src/enums\";\nimport { ObjectId } from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\ntype PushTokenType = {\n _id: string;\n createdAt: Date;\n platform: EnumOSPlatform;\n token: string;\n updatedAt: Date;\n userId: string;\n};\n\nexport type SchemaPushTokenType = Omit<PushTokenType, \"userId\"> & {\n userId: ObjectId;\n};\n\n/**\n * This is the schema for the push token type.\n * It is used to define the structure of the push token type in the database.\n * The schema is used by Mongoose to create a model for the push token type.\n */\nconst schema = new MongooseSchema<SchemaPushTokenType>(\n {\n platform: {\n enum: Object.values(EnumOSPlatform),\n required: true,\n type: String,\n },\n token: { required: true, type: String },\n userId: { required: true, type: mongoose.Schema.Types.ObjectId },\n },\n { timestamps: true },\n);\n\nexport const PushTokenModel =\n (mongoose.models.PushToken as mongoose.Model<SchemaPushTokenType>) ||\n mongoose.model<SchemaPushTokenType>(\"PushToken\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumOSPlatform, EnumResourceType } from \"src/enums\";\nimport {\n EnumActivity,\n ResourceActivityEntry,\n ResourceActivityType,\n} from \"src/types\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst ActivitySchema = new MongooseSchema<ResourceActivityEntry>(\n {\n activityType: {\n enum: Object.values(EnumActivity),\n required: true,\n type: String,\n },\n location: {\n coordinates: {\n required: false,\n type: [Number],\n },\n type: {\n default: \"Point\",\n enum: [\"Point\"],\n required: false,\n type: String,\n },\n },\n startDate: { required: false, type: String },\n startTime: { required: false, type: String },\n timestamp: { default: Date.now, type: Date },\n userAgent: {\n enum: Object.values(EnumOSPlatform),\n required: true,\n type: String,\n },\n userId: { required: false, type: String },\n },\n { _id: false },\n);\n\nconst schema = new MongooseSchema<ResourceActivityType>(\n {\n activity: { default: [], type: [ActivitySchema] },\n resourceId: { required: true, type: String },\n resourceType: {\n enum: Object.values(EnumResourceType),\n required: true,\n type: String,\n },\n },\n { timestamps: true },\n);\n\nschema.index({ resourceId: 1, resourceType: 1 }, { unique: true }); // one per entity\nschema.index({ \"views.location\": \"2dsphere\" });\n\nexport const ResourceActivityModel =\n (mongoose.models.ResourceActivity as mongoose.Model<ResourceActivityType>) ||\n mongoose.model<ResourceActivityType>(\"ResourceActivity\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumOSPlatform, EnumResourceType } from \"src/enums\";\nimport { TesterType } from \"src/types\";\n\nimport { CategorySchema } from \"./global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst TesterSchema = new MongooseSchema<TesterType>(\n {\n active: { default: false, required: true, type: Boolean },\n categories: [CategorySchema],\n companyName: { required: true, type: String },\n email: { required: true, type: String },\n firstName: { required: true, type: String },\n lastName: { required: true, type: String },\n osType: {\n enum: Object.values(EnumOSPlatform),\n required: true,\n type: String,\n },\n region: { required: true, type: String },\n resourceType: {\n enum: Object.values(EnumResourceType),\n required: true,\n type: String,\n },\n },\n {\n timestamps: true,\n },\n);\n\nexport const TesterModel =\n (mongoose.models.Tester as mongoose.Model<TesterType>) ||\n mongoose.model<TesterType>(\"Tester\", TesterSchema);\n","import mongoose from \"mongoose\";\n\nimport { EnumOSPlatform, EnumUserLicence, EnumUserRole } from \"src/enums\";\nimport { ObjectId, UserActivityEvent, UserType } from \"src/types\";\n\nimport {\n partnersSchema,\n ResourceImageTypeSchema,\n termsAgreementSchema,\n} from \"./global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaUserActivityEvent = Omit<UserActivityEvent, \"resourceId\"> & {\n resourceId: ObjectId;\n};\n\nexport type SchemaUserType = Omit<\n UserType,\n \"vendor\" | \"events\" | \"userActivity\" | \"_id\"\n> & {\n _id: ObjectId;\n vendor: ObjectId;\n events: ObjectId[];\n userActivity: {\n favourites: {\n events: ObjectId[];\n vendors: ObjectId[];\n };\n interested: {\n events: SchemaUserActivityEvent[];\n };\n going: {\n events: SchemaUserActivityEvent[];\n };\n present: {\n events: SchemaUserActivityEvent[];\n };\n };\n};\n\nconst userActivityEventSchema = new MongooseSchema<SchemaUserActivityEvent>(\n {\n resourceId: {\n ref: \"Event\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n startDate: { required: false, type: String },\n startTime: { required: false, type: String },\n },\n { _id: false },\n);\n\nconst userActivityFavouritesSchema = new MongooseSchema(\n {\n events: {\n ref: \"Event\",\n required: false,\n type: [mongoose.Schema.Types.ObjectId],\n },\n vendors: {\n ref: \"Vendor\",\n required: false,\n type: [mongoose.Schema.Types.ObjectId],\n },\n },\n { _id: false },\n);\n\n/**\n * This is the schema for the user type.\n * It is used to define the structure of the user type in the database.\n * The schema is used by Mongoose to create a model for the user type.\n */\nconst schema = new MongooseSchema<SchemaUserType>(\n {\n active: { default: false, required: true, type: Boolean },\n avatar: ResourceImageTypeSchema,\n deletedAt: { default: null, required: false, type: Date },\n email: { required: true, type: String },\n events: {\n ref: \"Event\",\n required: false,\n type: [mongoose.Schema.Types.ObjectId],\n },\n firstName: { required: true, type: String },\n isTester: { default: false, required: false, type: Boolean },\n lastName: { required: true, type: String },\n licences: {\n enum: Object.values(EnumUserLicence),\n required: false,\n type: [String],\n },\n partners: {\n required: false,\n type: [partnersSchema],\n },\n password: { required: true, type: String },\n platform: {\n enum: Object.values(EnumOSPlatform),\n required: false,\n type: String,\n },\n preferredRegion: {\n required: true,\n type: String,\n },\n refreshToken: {\n required: false,\n type: String,\n },\n role: {\n default: EnumUserRole.CUSTOMER,\n enum: Object.values(EnumUserRole),\n required: true,\n type: String,\n },\n termsAgreement: termsAgreementSchema,\n userActivity: {\n favourites: {\n default: () => ({ events: [], vendors: [] }),\n type: userActivityFavouritesSchema,\n },\n going: {\n events: [userActivityEventSchema],\n },\n interested: {\n events: [userActivityEventSchema],\n },\n present: {\n events: [userActivityEventSchema],\n },\n },\n vendor: {\n ref: \"Vendor\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { timestamps: true },\n);\n\nschema.index({ \"partners.email\": 1 });\n\nexport const UserModel =\n (mongoose.models.User as mongoose.Model<SchemaUserType>) ||\n mongoose.model<SchemaUserType>(\"User\", schema);\n","import mongoose from \"mongoose\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport interface VerificationTokenType {\n email: string;\n verificationToken: string;\n createdAt: Date;\n}\n\nconst schema = new MongooseSchema<VerificationTokenType>(\n {\n createdAt: {\n default: Date.now,\n expires: 24 * 60 * 60, // 24 hours in seconds (MongoDB TTL expects seconds)\n required: true,\n type: Date,\n }, // Token expires after 1 day\n email: { required: true, type: String },\n verificationToken: { required: true, type: String },\n },\n { timestamps: true },\n);\n\nexport const VerificationTokenModel =\n (mongoose.models\n .VerificationToken as mongoose.Model<VerificationTokenType>) ||\n mongoose.model<VerificationTokenType>(\"VerificationToken\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumVendorType } from \"src/enums\";\nimport { ObjectId, VendorMenuType, VendorType } from \"src/types\";\n\nimport { baseResourceFields, CategorySchema, SchemaOwnerType } from \"../global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst MenuTypeSchema = new MongooseSchema<VendorMenuType>(\n {\n description: { required: false, type: String },\n name: { required: false, type: String },\n price: { required: false, type: Number },\n productGroups: { required: false, type: [String] },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst LocationsSchema = new MongooseSchema<VendorType[\"locations\"]>(\n {\n dateTime: {\n endDate: { required: false, type: String },\n endTime: { required: false, type: String },\n startDate: { required: false, type: String },\n startTime: { required: false, type: String },\n },\n description: { required: false, type: String },\n location: {\n city: { required: false, type: String },\n coordinates: {\n required: false,\n type: [Number], // [longitude, latitude]\n },\n country: { required: false, type: String },\n fullAddress: { required: false, type: String },\n latitude: { required: false, type: Number },\n longitude: { required: false, type: Number },\n region: { required: false, type: String },\n type: { required: false, type: String }, // Mongoose GeoJSON type\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport type SchemaVendorType = Omit<\n VendorType,\n \"vendorInfoId\" | \"owner\" | \"adIds\"\n> & {\n adIds?: ObjectId[];\n owner: SchemaOwnerType;\n vendorInfoId: ObjectId;\n};\n\nconst schema = new MongooseSchema<SchemaVendorType>(\n {\n ...baseResourceFields, // Importing base resource fields from global.ts\n availability: {\n corporate: { default: false, required: false, type: Boolean },\n private: { default: false, required: false, type: Boolean },\n school: { default: false, required: false, type: Boolean },\n },\n categories: [CategorySchema],\n locations: [LocationsSchema],\n multiLocation: { required: true, type: Boolean },\n products: [MenuTypeSchema],\n vendorInfoId: {\n ref: \"VendorInfo\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n vendorType: {\n enum: Object.values(EnumVendorType),\n required: true,\n type: String,\n },\n },\n { timestamps: true },\n);\n\n// 🔹 Add indexes to speed up regex-based searches\nschema.index({ name: 1 });\nschema.index({ description: 1 });\nschema.index({ region: 1 });\nschema.index({ \"categories.name\": 1 });\nschema.index({ \"partners.email\": 1 });\n\nexport const VendorModel =\n (mongoose.models.Vendor as mongoose.Model<SchemaVendorType>) ||\n mongoose.model<SchemaVendorType>(\"Vendor\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumFoodFlavor } from \"src/enums\";\nimport { ObjectId, VendorAttributes, VendorInfoType } from \"src/types\";\n\nimport { ResourceImageTypeSchema } from \"../global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nexport type SchemaVendorInfoType = Omit<VendorInfoType, \"vendorId\"> & {\n vendorId: ObjectId;\n};\n\nconst AttributesSchema = new MongooseSchema<VendorAttributes>(\n {\n details: { required: false, type: String },\n isRequired: { default: false, required: true, type: Boolean },\n },\n { _id: false },\n);\n\nconst schema = new MongooseSchema<SchemaVendorInfoType>(\n {\n compliance: {\n foodBeverageLicense: { default: false, required: false, type: Boolean },\n liabilityInsurance: { default: false, required: false, type: Boolean },\n },\n documents: [ResourceImageTypeSchema],\n product: {\n foodFlavors: {\n enum: Object.values(EnumFoodFlavor),\n required: true,\n type: [String],\n },\n packaging: { required: true, type: [String] },\n priceRange: {\n max: { required: true, type: Number },\n min: { required: true, type: Number },\n },\n producedIn: { required: true, type: [String] },\n },\n requirements: {\n electricity: AttributesSchema,\n gazebo: AttributesSchema,\n table: AttributesSchema,\n },\n stallInfo: {\n size: {\n depth: { required: true, type: Number },\n width: { required: true, type: Number },\n },\n },\n vendorId: {\n ref: \"Vendor\",\n required: true,\n type: mongoose.Schema.Types.ObjectId,\n },\n },\n { timestamps: true },\n);\n\nexport const VendorInfoModel =\n (mongoose.models.VendorInfo as mongoose.Model<SchemaVendorInfoType>) ||\n mongoose.model<SchemaVendorInfoType>(\"VendorInfo\", schema);\n","import mongoose from \"mongoose\";\n\nimport { EnumEventType } from \"src/enums\";\nimport { DateTimeType, EventType, LocationType, ObjectId } from \"src/types\";\n\nimport { baseResourceFields, SchemaOwnerType } from \"../global\";\n\nconst MongooseSchema = mongoose.Schema;\n\nconst locationsSchema = new MongooseSchema<LocationType>(\n {\n city: { required: true, type: String },\n coordinates: {\n required: true,\n type: [Number], // [longitude, latitude]\n },\n country: { required: true, type: String },\n fullAddress: { required: true, type: String },\n latitude: { required: true, type: Number },\n longitude: { required: true, type: Number },\n region: { required: true, type: String },\n type: {\n default: \"Point\",\n enum: [\"Point\"],\n required: true,\n type: String,\n },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nconst dateTimeSchema = new MongooseSchema<DateTimeType>(\n {\n endDate: { required: true, type: String },\n endTime: { required: true, type: String },\n startDate: { required: true, type: String },\n startTime: { required: true, type: String },\n },\n { _id: false }, // Prevents Mongoose from creating an additional _id field for subdocuments\n);\n\nexport type SchemaEventType = Omit<\n EventType,\n \"eventInfoId\" | \"owner\" | \"adIds\"\n> & {\n adIds?: ObjectId[];\n eventInfoId: ObjectId;\n owner: SchemaOwnerType;\n};\n\n/**\n * This is the schema for the event type.\n * It is used to define the structure of the event type in the database.\n * The schema is used by Mongoose to create a model for the event type.\n */\nconst schema = new MongooseSchema<SchemaEventType>(\n {\n ...baseResourceFields, // Importing base resource fields from global.ts\n dateTime: [dateTimeSchema],\n eventInfoId: {\n ref: \"EventInfo\",\n required: false,\n type: mongoose.Schema.Types.ObjectId,\n },\n eventType: {\n enum: Object.values(EnumEventType),\n required: true,\n type: String,\n },\n location: {\n required: true,\n type: locationsSchema,\n },\n nzbn: { required: true, type: String },\n provider: { required: false, type: String },\n rainOrShine: { required: true, type: Boolean },\n tags: { required: true, type: [String] },\n },\n { timestamps: true },\n);\n\n// 🔹 Add indexes to speed up regex-based searches\nschema.index({ name: 1 });\nschema.index({ description: 1 });\nschema.index({ region: 1 });\nschema.index({ location: \"2dsphere\" });\nschema.index({ tags: 1 });\nschema.index({ \"partners.email\": 1 });\n\nexport const EventModel =\n (mongoose.models.Event as mongoose.Model<SchemaEventType>) ||\n mongoose.model<SchemaEventType>(\"Event\", schema);\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,mBAAqB;;;ACAd,IAAK,mBAAL,kBAAKC,sBAAL;AACL,EAAAA,kBAAA,cAAW;AACX,EAAAA,kBAAA,eAAY;AACZ,EAAAA,kBAAA,aAAU;AACV,EAAAA,kBAAA,eAAY;AACZ,EAAAA,kBAAA,UAAO;AACP,EAAAA,kBAAA,aAAU;AACV,EAAAA,kBAAA,cAAW;AACX,EAAAA,kBAAA,iBAAc;AACd,EAAAA,kBAAA,aAAU;AATA,SAAAA;AAAA,GAAA;AAYL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,WAAQ;AACR,EAAAA,cAAA,a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AAE,UAAU,MAAM,MAAM,OAAO;AAAA,IACxC,WAAW,EAAE,UAAU,MAAM,MAAM,OAAO;AAAA,IAC1C,WAAW,EAAE,UAAU,MAAM,MAAM,OAAO;AAAA,EAC5C;AAAA,EACA,EAAE,KAAK,MAAM;AAAA;AACf;AAgBA,IAAMG,WAAS,IAAIH;AAAA,EACjB;AAAA,IACE,GAAG;AAAA;AAAA,IACH,UAAU,CAACE,eAAc;AAAA,IACzB,aAAa;AAAA,MACX,KAAK;AAAA,MACL,UAAU;AAAA,MACV,MAAM,kBAAAD,QAAS,OAAO,MAAM;AAAA,IAC9B;AAAA,IACA,WAAW;AAAA,MACT,MAAM,OAAO,OAAO,aAAa;AAAA,MACjC,UAAU;AAAA,MACV,MAAM;AAAA,IACR;AAAA,IACA,UAAU;AAAA,MACR,UAAU;AAAA,MACV,MAAM;AAAA,IACR;AAAA,IACA,MAAM,EAAE,UAAU,MAAM,MAAM,OAAO;AAAA,IACrC,UAAU,EAAE,UAAU,OAAO,MAAM,OAAO;AAAA,IAC1C,aAAa,EAAE,UAAU,MAAM,MAAM,QAAQ;AAAA,IAC7C,MAAM,EAAE,UAAU,MAAM,MAAM,CAAC,MAAM,EAAE;AAAA,EACzC;AAAA,EACA,EAAE,YAAY,KAAK;AACrB;AAGAE,SAAO,MAAM,EAAE,MAAM,EAAE,CAAC;AACxBA,SAAO,MAAM,EAAE,aAAa,EAAE,CAAC;AAC/BA,SAAO,MAAM,EAAE,QAAQ,EAAE,CAAC;AAC1BA,SAAO,MAAM,EAAE,UAAU,WAAW,CAAC;AACrCA,SAAO,MAAM,EAAE,MAAM,EAAE,CAAC;AACxBA,SAAO,MAAM,EAAE,kBAAkB,EAAE,CAAC;AAE7B,IAAM,aACV,kBAAAF,QAAS,OAAO,SACjB,kBAAAA,QAAS,MAAuB,SAASE,QAAM;","names":["import_mongoose","EnumInviteStatus","EnumChatType","EnumPaymentMethod","EnumFoodFlavor","EnumResourceType","EnumEventType","EnumVendorType","EnumOSPlatform","EnumRelationResource","EnumNotificationResourceType","EnumNotificationType","EnumUserLicence","EnumUserRole","EnumAdShowOn","EnumAdStatus","EnumAdType","EnumAdStyle","EnumActivity","import_mongoose","import_mongoose","import_mongoose","mongoose","MongooseSchema","mongoose","MongooseSchema","mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","schema","import_mongoose","MongooseSchema","mongoose","dateTimeSchema","schema"]}
@@ -1,7 +1,7 @@
1
1
  import mongoose from 'mongoose';
2
- import { A as AdType, T as TesterType, f as UserActivityEvent, U as UserType } from '../ad-IVwm5MLY.mjs';
3
- import { p as OwnerType, q as ObjectId, r as SocialMediaType, s as ResourceImageType, C as Category, P as PartnerType, T as TermsAgreement, D as DeviceInfo, t as ResourceContactDetailsType, u as PosterUsageType, v as RelationDate, e as RelationType, V as VendorType, g as VendorInfoType, E as EventType, S as StallType, c as EventInfoType } from '../global-_89-F0iL.mjs';
4
- export { A as ChatModel, I as NotificationModel, z as ParticipantSchema, w as SchemaChatMessageType, y as SchemaChatType, G as SchemaCreateBulkNotificationInput, H as SchemaNotificationType, x as SchemaParticipantType } from '../global-_89-F0iL.mjs';
2
+ import { A as AdType, T as TesterType, f as UserActivityEvent, U as UserType } from '../ad-CiYcsJB7.mjs';
3
+ import { p as OwnerType, q as ObjectId, r as SocialMediaType, s as ResourceImageType, C as Category, P as PartnerType, T as TermsAgreement, D as DeviceInfo, t as ResourceContactDetailsType, u as PosterUsageType, v as RelationDate, e as RelationType, V as VendorType, g as VendorInfoType, E as EventType, S as StallType, c as EventInfoType } from '../global-ExJZRDGR.mjs';
4
+ export { A as ChatModel, I as NotificationModel, z as ParticipantSchema, w as SchemaChatMessageType, y as SchemaChatType, G as SchemaCreateBulkNotificationInput, H as SchemaNotificationType, x as SchemaParticipantType } from '../global-ExJZRDGR.mjs';
5
5
  import { EnumOSPlatform } from '../enums/index.mjs';
6
6
  import { R as ResourceActivityType } from '../resourceActivities-BIjtlOGp.mjs';
7
7
  import 'express';
@@ -1,7 +1,7 @@
1
1
  import mongoose from 'mongoose';
2
- import { A as AdType, T as TesterType, f as UserActivityEvent, U as UserType } from '../ad-Cv1V8lgJ.js';
3
- import { p as OwnerType, q as ObjectId, r as SocialMediaType, s as ResourceImageType, C as Category, P as PartnerType, T as TermsAgreement, D as DeviceInfo, t as ResourceContactDetailsType, u as PosterUsageType, v as RelationDate, e as RelationType, V as VendorType, g as VendorInfoType, E as EventType, S as StallType, c as EventInfoType } from '../global-Bnr6l_NH.js';
4
- export { A as ChatModel, I as NotificationModel, z as ParticipantSchema, w as SchemaChatMessageType, y as SchemaChatType, G as SchemaCreateBulkNotificationInput, H as SchemaNotificationType, x as SchemaParticipantType } from '../global-Bnr6l_NH.js';
2
+ import { A as AdType, T as TesterType, f as UserActivityEvent, U as UserType } from '../ad-BZylIpez.js';
3
+ import { p as OwnerType, q as ObjectId, r as SocialMediaType, s as ResourceImageType, C as Category, P as PartnerType, T as TermsAgreement, D as DeviceInfo, t as ResourceContactDetailsType, u as PosterUsageType, v as RelationDate, e as RelationType, V as VendorType, g as VendorInfoType, E as EventType, S as StallType, c as EventInfoType } from '../global-DVYSZ6LR.js';
4
+ export { A as ChatModel, I as NotificationModel, z as ParticipantSchema, w as SchemaChatMessageType, y as SchemaChatType, G as SchemaCreateBulkNotificationInput, H as SchemaNotificationType, x as SchemaParticipantType } from '../global-DVYSZ6LR.js';
5
5
  import { EnumOSPlatform } from '../enums/index.js';
6
6
  import { R as ResourceActivityType } from '../resourceActivities-B4roVKtQ.js';
7
7
  import 'express';
@@ -1,7 +1,3 @@
1
- import {
2
- NotificationModel,
3
- PushTokenModel
4
- } from "../chunk-NPHPFWQH.mjs";
5
1
  import {
6
2
  EnumActivity
7
3
  } from "../chunk-4OLDTZXH.mjs";
@@ -11,6 +7,10 @@ import {
11
7
  EnumAdStyle,
12
8
  EnumAdType
13
9
  } from "../chunk-XXZPSRMS.mjs";
10
+ import {
11
+ NotificationModel,
12
+ PushTokenModel
13
+ } from "../chunk-NPHPFWQH.mjs";
14
14
  import {
15
15
  EnumChatType,
16
16
  EnumEventType,