@timardex/cluemart-server-shared 1.0.213 → 1.0.214
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-5PTF25RX.mjs → chunk-IFNK65HN.mjs} +53 -8
- package/dist/chunk-IFNK65HN.mjs.map +1 -0
- package/dist/index.cjs +52 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +30 -2
- package/dist/index.d.ts +30 -2
- package/dist/index.mjs +51 -6
- package/dist/index.mjs.map +1 -1
- package/dist/mongoose/index.cjs +50 -4
- package/dist/mongoose/index.cjs.map +1 -1
- package/dist/mongoose/index.d.mts +30 -2
- package/dist/mongoose/index.d.ts +30 -2
- package/dist/mongoose/index.mjs +3 -1
- package/dist/service/index.cjs +50 -6
- package/dist/service/index.cjs.map +1 -1
- package/dist/service/index.mjs +1 -1
- package/package.json +2 -2
- package/dist/chunk-5PTF25RX.mjs.map +0 -1
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _timardex_cluemart_shared from '@timardex/cluemart-shared';
|
|
2
|
-
import { AdType, CreateBulkNotificationInput, NotificationType, EnumUserRole, ChatMessageType, ParticipantType, ChatType, ReportChatUser, OwnerType, SocialMediaType, ResourceImageType, Category, UserLicenceType, AssociateType, ResourceContactDetailsType, TermsAgreement, RelationDate, DateTimeType, LocationGeoType, LocationType, PosterUsageType, GoogleImportedMarket, PushTokenType, RelationType, ResourceActivityType, UserActivityEvent, UserType, VendorType, VendorInfoType, UnregisteredVendorInvitationType, UnregisteredVendorType, EventType, StallType, RefundPolicy, EventInfoType, PartnerType, PostType, PostContentType, AppSettingsType, GameType, GameDocType, SchoolType, EnumUserLicence, EventListItemType, DateTimeWithPriceType } from '@timardex/cluemart-shared';
|
|
2
|
+
import { AdType, CreateBulkNotificationInput, NotificationType, EnumUserRole, ChatMessageType, ParticipantType, ChatType, ReportChatUser, RelatedPostType, OwnerType, SocialMediaType, ResourceImageType, Category, UserLicenceType, AssociateType, ResourceContactDetailsType, TermsAgreement, RelationDate, DateTimeType, LocationGeoType, LocationType, PosterUsageType, GoogleImportedMarket, PushTokenType, RelationType, ResourceActivityType, UserActivityEvent, UserType, VendorType, VendorInfoType, UnregisteredVendorInvitationType, UnregisteredVendorType, EventType, StallType, RefundPolicy, EventInfoType, PartnerType, PostType, PostContentType, AppSettingsType, GameType, GameDocType, SchoolType, EnumUserLicence, EventListItemType, DateTimeWithPriceType } from '@timardex/cluemart-shared';
|
|
3
3
|
import mongoose from 'mongoose';
|
|
4
4
|
export { default as mongoose } from 'mongoose';
|
|
5
5
|
import { NotificationCount, DateTimeType as DateTimeType$1 } from '@timardex/cluemart-shared/types';
|
|
@@ -106,6 +106,9 @@ declare const ChatReportModel: mongoose.Model<SchemaChatReportType, {}, {}, {},
|
|
|
106
106
|
__v: number;
|
|
107
107
|
}, any>;
|
|
108
108
|
|
|
109
|
+
type SchemaRelatedPostType = Omit<RelatedPostType, "postId"> & {
|
|
110
|
+
postId: ObjectId;
|
|
111
|
+
};
|
|
109
112
|
type SchemaOwnerType = Omit<OwnerType, "userId"> & {
|
|
110
113
|
userId: ObjectId;
|
|
111
114
|
};
|
|
@@ -242,6 +245,17 @@ declare const locationsSchema: mongoose.Schema<LocationType, mongoose.Model<Loca
|
|
|
242
245
|
} & {
|
|
243
246
|
__v: number;
|
|
244
247
|
}>;
|
|
248
|
+
declare const relatedPostSchema: mongoose.Schema<SchemaRelatedPostType, mongoose.Model<SchemaRelatedPostType, any, any, any, mongoose.Document<unknown, any, SchemaRelatedPostType, any, {}> & Omit<RelatedPostType, "postId"> & {
|
|
249
|
+
postId: ObjectId;
|
|
250
|
+
} & {
|
|
251
|
+
_id: mongoose.Types.ObjectId;
|
|
252
|
+
} & {
|
|
253
|
+
__v: number;
|
|
254
|
+
}, any>, {}, {}, {}, {}, mongoose.DefaultSchemaOptions, SchemaRelatedPostType, mongoose.Document<unknown, {}, mongoose.FlatRecord<SchemaRelatedPostType>, {}, mongoose.ResolveSchemaOptions<mongoose.DefaultSchemaOptions>> & mongoose.FlatRecord<SchemaRelatedPostType> & {
|
|
255
|
+
_id: mongoose.Types.ObjectId;
|
|
256
|
+
} & {
|
|
257
|
+
__v: number;
|
|
258
|
+
}>;
|
|
245
259
|
declare const baseResourceFields: {
|
|
246
260
|
active: {
|
|
247
261
|
default: boolean;
|
|
@@ -364,6 +378,20 @@ declare const baseResourceFields: {
|
|
|
364
378
|
required: boolean;
|
|
365
379
|
type: StringConstructor;
|
|
366
380
|
};
|
|
381
|
+
relatedPost: {
|
|
382
|
+
required: boolean;
|
|
383
|
+
type: mongoose.Schema<SchemaRelatedPostType, mongoose.Model<SchemaRelatedPostType, any, any, any, mongoose.Document<unknown, any, SchemaRelatedPostType, any, {}> & Omit<RelatedPostType, "postId"> & {
|
|
384
|
+
postId: ObjectId;
|
|
385
|
+
} & {
|
|
386
|
+
_id: mongoose.Types.ObjectId;
|
|
387
|
+
} & {
|
|
388
|
+
__v: number;
|
|
389
|
+
}, any>, {}, {}, {}, {}, mongoose.DefaultSchemaOptions, SchemaRelatedPostType, mongoose.Document<unknown, {}, mongoose.FlatRecord<SchemaRelatedPostType>, {}, mongoose.ResolveSchemaOptions<mongoose.DefaultSchemaOptions>> & mongoose.FlatRecord<SchemaRelatedPostType> & {
|
|
390
|
+
_id: mongoose.Types.ObjectId;
|
|
391
|
+
} & {
|
|
392
|
+
__v: number;
|
|
393
|
+
}>;
|
|
394
|
+
};
|
|
367
395
|
reviewCount: {
|
|
368
396
|
required: boolean;
|
|
369
397
|
type: NumberConstructor;
|
|
@@ -746,4 +774,4 @@ declare function didRemoveAnyEventDates(previousDateTime: EventDateSlot[] | unde
|
|
|
746
774
|
*/
|
|
747
775
|
declare function updateRelationDatesToUnavailable(relationDates: SchemaRelationType["relationDates"], eventDateTime: DateTimeWithPriceType[] | undefined): SchemaRelationType["relationDates"];
|
|
748
776
|
|
|
749
|
-
export { APP_SETTINGS_ID, AdModel, AppSettingModel, type AuthUser, CategorySchema, ChatModel, ChatReportModel, ContactDetailsSchema, EnumPubSubEvents, EventInfoModel, EventModel, GameModel, GoogleImportedMarketModel, type GraphQLContext, NotificationModel, type ObjectId, OwnerTypeSchema, PartnerModel, PostModel, PushTokenModel, RelationModel, RelationTypeSchema, ResourceActivityModel, ResourceImageTypeSchema, type SchemaChatMessageReactionType, type SchemaChatMessageReplyPreviewType, type SchemaChatMessageSeenType, type SchemaChatMessageType, type SchemaChatReportType, type SchemaChatType, type SchemaCreateBulkNotificationInput, type SchemaEventInfoType, type SchemaEventType, type SchemaGameType, type SchemaGoogleImportedMarket, type SchemaNotificationType, type SchemaOwnerType, type SchemaParticipantType, type SchemaPartnerType, type SchemaPostType, type SchemaPushTokenType, type SchemaRelationType, type SchemaUnregisteredVendorInvitationType, type SchemaUnregisteredVendorType, type SchemaUserActivityEvent, type SchemaUserType, type SchemaVendorInfoType, type SchemaVendorType, SchoolModel, SocialMediaTypeSchema, StallTypeSchema, type SubscriptionPayload, UnregisteredVendorModel, UserModel, VendorInfoModel, VendorModel, VerificationTokenModel, type VerificationTokenType, associatesSchema, baseResourceFields, connectToDatabase, convertObjectIdsToStrings, dateTimeSchema, didRemoveAnyEventDates, findEventOrImportedMarketById, locationGeoSchema, locationsSchema, refundPolicySchema, relationDatesSchema, resourceRelationsSchema, saveNotificationsInDb, sendPushNotifications, termsAgreementSchema, updateAdStatuses, updateAllEventDateTimeStatuses, updateRelationDatesToUnavailable, updateSingleDateTimeStatus, updateVendorBasedOnUserLicense, userLicenseSchema };
|
|
777
|
+
export { APP_SETTINGS_ID, AdModel, AppSettingModel, type AuthUser, CategorySchema, ChatModel, ChatReportModel, ContactDetailsSchema, EnumPubSubEvents, EventInfoModel, EventModel, GameModel, GoogleImportedMarketModel, type GraphQLContext, NotificationModel, type ObjectId, OwnerTypeSchema, PartnerModel, PostModel, PushTokenModel, RelationModel, RelationTypeSchema, ResourceActivityModel, ResourceImageTypeSchema, type SchemaChatMessageReactionType, type SchemaChatMessageReplyPreviewType, type SchemaChatMessageSeenType, type SchemaChatMessageType, type SchemaChatReportType, type SchemaChatType, type SchemaCreateBulkNotificationInput, type SchemaEventInfoType, type SchemaEventType, type SchemaGameType, type SchemaGoogleImportedMarket, type SchemaNotificationType, type SchemaOwnerType, type SchemaParticipantType, type SchemaPartnerType, type SchemaPostType, type SchemaPushTokenType, type SchemaRelatedPostType, type SchemaRelationType, type SchemaUnregisteredVendorInvitationType, type SchemaUnregisteredVendorType, type SchemaUserActivityEvent, type SchemaUserType, type SchemaVendorInfoType, type SchemaVendorType, SchoolModel, SocialMediaTypeSchema, StallTypeSchema, type SubscriptionPayload, UnregisteredVendorModel, UserModel, VendorInfoModel, VendorModel, VerificationTokenModel, type VerificationTokenType, associatesSchema, baseResourceFields, connectToDatabase, convertObjectIdsToStrings, dateTimeSchema, didRemoveAnyEventDates, findEventOrImportedMarketById, locationGeoSchema, locationsSchema, refundPolicySchema, relatedPostSchema, relationDatesSchema, resourceRelationsSchema, saveNotificationsInDb, sendPushNotifications, termsAgreementSchema, updateAdStatuses, updateAllEventDateTimeStatuses, updateRelationDatesToUnavailable, updateSingleDateTimeStatus, updateVendorBasedOnUserLicense, userLicenseSchema };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _timardex_cluemart_shared from '@timardex/cluemart-shared';
|
|
2
|
-
import { AdType, CreateBulkNotificationInput, NotificationType, EnumUserRole, ChatMessageType, ParticipantType, ChatType, ReportChatUser, OwnerType, SocialMediaType, ResourceImageType, Category, UserLicenceType, AssociateType, ResourceContactDetailsType, TermsAgreement, RelationDate, DateTimeType, LocationGeoType, LocationType, PosterUsageType, GoogleImportedMarket, PushTokenType, RelationType, ResourceActivityType, UserActivityEvent, UserType, VendorType, VendorInfoType, UnregisteredVendorInvitationType, UnregisteredVendorType, EventType, StallType, RefundPolicy, EventInfoType, PartnerType, PostType, PostContentType, AppSettingsType, GameType, GameDocType, SchoolType, EnumUserLicence, EventListItemType, DateTimeWithPriceType } from '@timardex/cluemart-shared';
|
|
2
|
+
import { AdType, CreateBulkNotificationInput, NotificationType, EnumUserRole, ChatMessageType, ParticipantType, ChatType, ReportChatUser, RelatedPostType, OwnerType, SocialMediaType, ResourceImageType, Category, UserLicenceType, AssociateType, ResourceContactDetailsType, TermsAgreement, RelationDate, DateTimeType, LocationGeoType, LocationType, PosterUsageType, GoogleImportedMarket, PushTokenType, RelationType, ResourceActivityType, UserActivityEvent, UserType, VendorType, VendorInfoType, UnregisteredVendorInvitationType, UnregisteredVendorType, EventType, StallType, RefundPolicy, EventInfoType, PartnerType, PostType, PostContentType, AppSettingsType, GameType, GameDocType, SchoolType, EnumUserLicence, EventListItemType, DateTimeWithPriceType } from '@timardex/cluemart-shared';
|
|
3
3
|
import mongoose from 'mongoose';
|
|
4
4
|
export { default as mongoose } from 'mongoose';
|
|
5
5
|
import { NotificationCount, DateTimeType as DateTimeType$1 } from '@timardex/cluemart-shared/types';
|
|
@@ -106,6 +106,9 @@ declare const ChatReportModel: mongoose.Model<SchemaChatReportType, {}, {}, {},
|
|
|
106
106
|
__v: number;
|
|
107
107
|
}, any>;
|
|
108
108
|
|
|
109
|
+
type SchemaRelatedPostType = Omit<RelatedPostType, "postId"> & {
|
|
110
|
+
postId: ObjectId;
|
|
111
|
+
};
|
|
109
112
|
type SchemaOwnerType = Omit<OwnerType, "userId"> & {
|
|
110
113
|
userId: ObjectId;
|
|
111
114
|
};
|
|
@@ -242,6 +245,17 @@ declare const locationsSchema: mongoose.Schema<LocationType, mongoose.Model<Loca
|
|
|
242
245
|
} & {
|
|
243
246
|
__v: number;
|
|
244
247
|
}>;
|
|
248
|
+
declare const relatedPostSchema: mongoose.Schema<SchemaRelatedPostType, mongoose.Model<SchemaRelatedPostType, any, any, any, mongoose.Document<unknown, any, SchemaRelatedPostType, any, {}> & Omit<RelatedPostType, "postId"> & {
|
|
249
|
+
postId: ObjectId;
|
|
250
|
+
} & {
|
|
251
|
+
_id: mongoose.Types.ObjectId;
|
|
252
|
+
} & {
|
|
253
|
+
__v: number;
|
|
254
|
+
}, any>, {}, {}, {}, {}, mongoose.DefaultSchemaOptions, SchemaRelatedPostType, mongoose.Document<unknown, {}, mongoose.FlatRecord<SchemaRelatedPostType>, {}, mongoose.ResolveSchemaOptions<mongoose.DefaultSchemaOptions>> & mongoose.FlatRecord<SchemaRelatedPostType> & {
|
|
255
|
+
_id: mongoose.Types.ObjectId;
|
|
256
|
+
} & {
|
|
257
|
+
__v: number;
|
|
258
|
+
}>;
|
|
245
259
|
declare const baseResourceFields: {
|
|
246
260
|
active: {
|
|
247
261
|
default: boolean;
|
|
@@ -364,6 +378,20 @@ declare const baseResourceFields: {
|
|
|
364
378
|
required: boolean;
|
|
365
379
|
type: StringConstructor;
|
|
366
380
|
};
|
|
381
|
+
relatedPost: {
|
|
382
|
+
required: boolean;
|
|
383
|
+
type: mongoose.Schema<SchemaRelatedPostType, mongoose.Model<SchemaRelatedPostType, any, any, any, mongoose.Document<unknown, any, SchemaRelatedPostType, any, {}> & Omit<RelatedPostType, "postId"> & {
|
|
384
|
+
postId: ObjectId;
|
|
385
|
+
} & {
|
|
386
|
+
_id: mongoose.Types.ObjectId;
|
|
387
|
+
} & {
|
|
388
|
+
__v: number;
|
|
389
|
+
}, any>, {}, {}, {}, {}, mongoose.DefaultSchemaOptions, SchemaRelatedPostType, mongoose.Document<unknown, {}, mongoose.FlatRecord<SchemaRelatedPostType>, {}, mongoose.ResolveSchemaOptions<mongoose.DefaultSchemaOptions>> & mongoose.FlatRecord<SchemaRelatedPostType> & {
|
|
390
|
+
_id: mongoose.Types.ObjectId;
|
|
391
|
+
} & {
|
|
392
|
+
__v: number;
|
|
393
|
+
}>;
|
|
394
|
+
};
|
|
367
395
|
reviewCount: {
|
|
368
396
|
required: boolean;
|
|
369
397
|
type: NumberConstructor;
|
|
@@ -746,4 +774,4 @@ declare function didRemoveAnyEventDates(previousDateTime: EventDateSlot[] | unde
|
|
|
746
774
|
*/
|
|
747
775
|
declare function updateRelationDatesToUnavailable(relationDates: SchemaRelationType["relationDates"], eventDateTime: DateTimeWithPriceType[] | undefined): SchemaRelationType["relationDates"];
|
|
748
776
|
|
|
749
|
-
export { APP_SETTINGS_ID, AdModel, AppSettingModel, type AuthUser, CategorySchema, ChatModel, ChatReportModel, ContactDetailsSchema, EnumPubSubEvents, EventInfoModel, EventModel, GameModel, GoogleImportedMarketModel, type GraphQLContext, NotificationModel, type ObjectId, OwnerTypeSchema, PartnerModel, PostModel, PushTokenModel, RelationModel, RelationTypeSchema, ResourceActivityModel, ResourceImageTypeSchema, type SchemaChatMessageReactionType, type SchemaChatMessageReplyPreviewType, type SchemaChatMessageSeenType, type SchemaChatMessageType, type SchemaChatReportType, type SchemaChatType, type SchemaCreateBulkNotificationInput, type SchemaEventInfoType, type SchemaEventType, type SchemaGameType, type SchemaGoogleImportedMarket, type SchemaNotificationType, type SchemaOwnerType, type SchemaParticipantType, type SchemaPartnerType, type SchemaPostType, type SchemaPushTokenType, type SchemaRelationType, type SchemaUnregisteredVendorInvitationType, type SchemaUnregisteredVendorType, type SchemaUserActivityEvent, type SchemaUserType, type SchemaVendorInfoType, type SchemaVendorType, SchoolModel, SocialMediaTypeSchema, StallTypeSchema, type SubscriptionPayload, UnregisteredVendorModel, UserModel, VendorInfoModel, VendorModel, VerificationTokenModel, type VerificationTokenType, associatesSchema, baseResourceFields, connectToDatabase, convertObjectIdsToStrings, dateTimeSchema, didRemoveAnyEventDates, findEventOrImportedMarketById, locationGeoSchema, locationsSchema, refundPolicySchema, relationDatesSchema, resourceRelationsSchema, saveNotificationsInDb, sendPushNotifications, termsAgreementSchema, updateAdStatuses, updateAllEventDateTimeStatuses, updateRelationDatesToUnavailable, updateSingleDateTimeStatus, updateVendorBasedOnUserLicense, userLicenseSchema };
|
|
777
|
+
export { APP_SETTINGS_ID, AdModel, AppSettingModel, type AuthUser, CategorySchema, ChatModel, ChatReportModel, ContactDetailsSchema, EnumPubSubEvents, EventInfoModel, EventModel, GameModel, GoogleImportedMarketModel, type GraphQLContext, NotificationModel, type ObjectId, OwnerTypeSchema, PartnerModel, PostModel, PushTokenModel, RelationModel, RelationTypeSchema, ResourceActivityModel, ResourceImageTypeSchema, type SchemaChatMessageReactionType, type SchemaChatMessageReplyPreviewType, type SchemaChatMessageSeenType, type SchemaChatMessageType, type SchemaChatReportType, type SchemaChatType, type SchemaCreateBulkNotificationInput, type SchemaEventInfoType, type SchemaEventType, type SchemaGameType, type SchemaGoogleImportedMarket, type SchemaNotificationType, type SchemaOwnerType, type SchemaParticipantType, type SchemaPartnerType, type SchemaPostType, type SchemaPushTokenType, type SchemaRelatedPostType, type SchemaRelationType, type SchemaUnregisteredVendorInvitationType, type SchemaUnregisteredVendorType, type SchemaUserActivityEvent, type SchemaUserType, type SchemaVendorInfoType, type SchemaVendorType, SchoolModel, SocialMediaTypeSchema, StallTypeSchema, type SubscriptionPayload, UnregisteredVendorModel, UserModel, VendorInfoModel, VendorModel, VerificationTokenModel, type VerificationTokenType, associatesSchema, baseResourceFields, connectToDatabase, convertObjectIdsToStrings, dateTimeSchema, didRemoveAnyEventDates, findEventOrImportedMarketById, locationGeoSchema, locationsSchema, refundPolicySchema, relatedPostSchema, relationDatesSchema, resourceRelationsSchema, saveNotificationsInDb, sendPushNotifications, termsAgreementSchema, updateAdStatuses, updateAllEventDateTimeStatuses, updateRelationDatesToUnavailable, updateSingleDateTimeStatus, updateVendorBasedOnUserLicense, userLicenseSchema };
|
package/dist/index.mjs
CHANGED
|
@@ -3478,12 +3478,6 @@ var gameScreenIdentifierList = [
|
|
|
3478
3478
|
match: "/visitors"
|
|
3479
3479
|
}
|
|
3480
3480
|
];
|
|
3481
|
-
var dateFormat = "DD-MM-YYYY";
|
|
3482
|
-
var timeFormat = "HH:mm";
|
|
3483
|
-
dayjs.extend(customParseFormat);
|
|
3484
|
-
dayjs.extend(utc);
|
|
3485
|
-
dayjs.extend(timezone);
|
|
3486
|
-
dayjs.extend(isSameOrAfter);
|
|
3487
3481
|
var EnumAdShowOn = /* @__PURE__ */ ((EnumAdShowOn2) => {
|
|
3488
3482
|
EnumAdShowOn2["EVENTS_PAGE"] = "Events_page";
|
|
3489
3483
|
EnumAdShowOn2["FRONT_PAGE"] = "Front_page";
|
|
@@ -3559,6 +3553,21 @@ var paymentMethodOptions = mapArrayToOptions(
|
|
|
3559
3553
|
Object.values(EnumPaymentMethod)
|
|
3560
3554
|
);
|
|
3561
3555
|
var CLUEMART_MAIN_DOMAIN_URL = "https://cluemart.co.nz";
|
|
3556
|
+
var dateFormat = "DD-MM-YYYY";
|
|
3557
|
+
var timeFormat = "HH:mm";
|
|
3558
|
+
dayjs.extend(customParseFormat);
|
|
3559
|
+
dayjs.extend(utc);
|
|
3560
|
+
dayjs.extend(timezone);
|
|
3561
|
+
dayjs.extend(isSameOrAfter);
|
|
3562
|
+
var futureTimePeriods = mapArrayToOptions(
|
|
3563
|
+
Object.values(EnumEventDateStatus)
|
|
3564
|
+
).filter(
|
|
3565
|
+
(period) => period.value !== "Starting_Soon" && period.value !== "Canceled" && period.value !== "Rescheduled" && period.value !== "Started" && period.value !== "Ended" && period.value !== "Invalid"
|
|
3566
|
+
/* INVALID */
|
|
3567
|
+
).map((period) => ({
|
|
3568
|
+
label: period.value.replaceAll("_", " "),
|
|
3569
|
+
value: period.value
|
|
3570
|
+
}));
|
|
3562
3571
|
var packagingTypes = [
|
|
3563
3572
|
"Biodegradable",
|
|
3564
3573
|
"Compostable",
|
|
@@ -5093,6 +5102,12 @@ var EVENT_LIST_ITEM = gql`
|
|
|
5093
5102
|
${RESOURCE_IMAGE_FIELDS_FRAGMENT}
|
|
5094
5103
|
${RELATION_DATES_FRAGMENT}
|
|
5095
5104
|
`;
|
|
5105
|
+
var RELATED_POST_FIELDS_FRAGMENT = gql`
|
|
5106
|
+
fragment RelatedPostFields on RelatedPostType {
|
|
5107
|
+
postId
|
|
5108
|
+
postType
|
|
5109
|
+
}
|
|
5110
|
+
`;
|
|
5096
5111
|
var EVENT_INFO = gql`
|
|
5097
5112
|
fragment EventInfoFields on EventInfoType {
|
|
5098
5113
|
_id
|
|
@@ -5182,6 +5197,9 @@ var EVENT = gql`
|
|
|
5182
5197
|
rating
|
|
5183
5198
|
reviewCount
|
|
5184
5199
|
rainOrShine
|
|
5200
|
+
relatedPost {
|
|
5201
|
+
...RelatedPostFields
|
|
5202
|
+
}
|
|
5185
5203
|
socialMedia {
|
|
5186
5204
|
...SocialMediaFields
|
|
5187
5205
|
}
|
|
@@ -5201,6 +5219,7 @@ var EVENT = gql`
|
|
|
5201
5219
|
${CONTACT_DETAILS_FIELDS_FRAGMENT}
|
|
5202
5220
|
${TERMS_AGREEMENT_FIELDS_FRAGMENT}
|
|
5203
5221
|
${RELATION_DATES_FRAGMENT}
|
|
5222
|
+
${RELATED_POST_FIELDS_FRAGMENT}
|
|
5204
5223
|
`;
|
|
5205
5224
|
var GET_EVENTS = gql`
|
|
5206
5225
|
query getEvents($dateStatus: EventDateStatusEnumType) {
|
|
@@ -5367,6 +5386,9 @@ var VENDOR = gql`
|
|
|
5367
5386
|
rating
|
|
5368
5387
|
region
|
|
5369
5388
|
reviewCount
|
|
5389
|
+
relatedPost {
|
|
5390
|
+
...RelatedPostFields
|
|
5391
|
+
}
|
|
5370
5392
|
relations {
|
|
5371
5393
|
relationId
|
|
5372
5394
|
relationDates {
|
|
@@ -5395,6 +5417,7 @@ var VENDOR = gql`
|
|
|
5395
5417
|
${CONTACT_DETAILS_FIELDS_FRAGMENT}
|
|
5396
5418
|
${TERMS_AGREEMENT_FIELDS_FRAGMENT}
|
|
5397
5419
|
${RELATION_DATES_FRAGMENT}
|
|
5420
|
+
${RELATED_POST_FIELDS_FRAGMENT}
|
|
5398
5421
|
`;
|
|
5399
5422
|
var VENDOR_ATTRIBUTES_FRAGMENT = gql`
|
|
5400
5423
|
fragment VendorAttributesFields on VendorAttributesType {
|
|
@@ -5853,6 +5876,9 @@ var PARTNER = gql`
|
|
|
5853
5876
|
rating
|
|
5854
5877
|
region
|
|
5855
5878
|
reviewCount
|
|
5879
|
+
relatedPost {
|
|
5880
|
+
...RelatedPostFields
|
|
5881
|
+
}
|
|
5856
5882
|
socialMedia {
|
|
5857
5883
|
...SocialMediaFields
|
|
5858
5884
|
}
|
|
@@ -5869,6 +5895,7 @@ var PARTNER = gql`
|
|
|
5869
5895
|
${POSTER_USAGE_FIELDS_FRAGMENT}
|
|
5870
5896
|
${SOCIAL_MEDIA_FIELDS_FRAGMENT}
|
|
5871
5897
|
${CONTACT_DETAILS_FIELDS_FRAGMENT}
|
|
5898
|
+
${RELATED_POST_FIELDS_FRAGMENT}
|
|
5872
5899
|
`;
|
|
5873
5900
|
var GET_PARTNERS = gql`
|
|
5874
5901
|
query getPartners {
|
|
@@ -7777,6 +7804,22 @@ var locationsSchema = new MongooseSchema6(
|
|
|
7777
7804
|
{ _id: false }
|
|
7778
7805
|
// Prevents Mongoose from creating an additional _id field for subdocuments
|
|
7779
7806
|
);
|
|
7807
|
+
var relatedPostSchema = new MongooseSchema6(
|
|
7808
|
+
{
|
|
7809
|
+
postId: {
|
|
7810
|
+
ref: "Post",
|
|
7811
|
+
required: true,
|
|
7812
|
+
type: mongoose6.Schema.Types.ObjectId
|
|
7813
|
+
},
|
|
7814
|
+
postType: {
|
|
7815
|
+
enum: Object.values(EnumPostType),
|
|
7816
|
+
required: true,
|
|
7817
|
+
type: String
|
|
7818
|
+
}
|
|
7819
|
+
},
|
|
7820
|
+
{ _id: false }
|
|
7821
|
+
// Prevents Mongoose from creating an additional _id field for subdocuments
|
|
7822
|
+
);
|
|
7780
7823
|
var baseResourceFields = {
|
|
7781
7824
|
active: { default: false, required: true, type: Boolean },
|
|
7782
7825
|
adIds: {
|
|
@@ -7806,6 +7849,7 @@ var baseResourceFields = {
|
|
|
7806
7849
|
promoCodes: { required: false, type: [String] },
|
|
7807
7850
|
rating: { required: false, type: Number },
|
|
7808
7851
|
region: { required: true, type: String },
|
|
7852
|
+
relatedPost: { required: false, type: relatedPostSchema },
|
|
7809
7853
|
reviewCount: { required: false, type: Number },
|
|
7810
7854
|
socialMedia: { required: false, type: [SocialMediaTypeSchema] },
|
|
7811
7855
|
termsAgreement: { required: true, type: termsAgreementSchema }
|
|
@@ -9335,6 +9379,7 @@ export {
|
|
|
9335
9379
|
locationsSchema,
|
|
9336
9380
|
mongoose28 as mongoose,
|
|
9337
9381
|
refundPolicySchema,
|
|
9382
|
+
relatedPostSchema,
|
|
9338
9383
|
relationDatesSchema,
|
|
9339
9384
|
resourceRelationsSchema,
|
|
9340
9385
|
saveNotificationsInDb,
|