@timardex/cluemart-server-shared 1.0.63 → 1.0.64
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-QGZKB5FC.mjs → chunk-DS5E2QOI.mjs} +92 -175
- package/dist/chunk-DS5E2QOI.mjs.map +1 -0
- package/dist/index.cjs +90 -173
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +10 -10
- package/dist/index.d.ts +10 -10
- package/dist/index.mjs +90 -173
- package/dist/index.mjs.map +1 -1
- package/dist/mongoose/index.cjs +90 -173
- package/dist/mongoose/index.cjs.map +1 -1
- package/dist/mongoose/index.d.mts +10 -10
- package/dist/mongoose/index.d.ts +10 -10
- package/dist/mongoose/index.mjs +1 -1
- package/dist/service/index.cjs +90 -173
- package/dist/service/index.cjs.map +1 -1
- package/dist/service/index.mjs +1 -1
- package/package.json +2 -2
- package/dist/chunk-QGZKB5FC.mjs.map +0 -1
|
@@ -8426,6 +8426,42 @@ var LOCATION_FIELDS_FRAGMENT = gql`
|
|
|
8426
8426
|
type
|
|
8427
8427
|
}
|
|
8428
8428
|
`;
|
|
8429
|
+
var EVENT_LIST_ITEM = gql`
|
|
8430
|
+
fragment EventListItemFields on EventListItemType {
|
|
8431
|
+
_id
|
|
8432
|
+
active
|
|
8433
|
+
claimed
|
|
8434
|
+
cover {
|
|
8435
|
+
...ResourceImageFields
|
|
8436
|
+
}
|
|
8437
|
+
createdAt
|
|
8438
|
+
dateTime {
|
|
8439
|
+
...EventDateTimeFields
|
|
8440
|
+
}
|
|
8441
|
+
deletedAt
|
|
8442
|
+
description
|
|
8443
|
+
eventType
|
|
8444
|
+
googlePlaceId
|
|
8445
|
+
images {
|
|
8446
|
+
...ResourceImageFields
|
|
8447
|
+
}
|
|
8448
|
+
location {
|
|
8449
|
+
...LocationFields
|
|
8450
|
+
}
|
|
8451
|
+
logo {
|
|
8452
|
+
...ResourceImageFields
|
|
8453
|
+
}
|
|
8454
|
+
name
|
|
8455
|
+
rainOrShine
|
|
8456
|
+
rating
|
|
8457
|
+
region
|
|
8458
|
+
reviewCount
|
|
8459
|
+
updatedAt
|
|
8460
|
+
}
|
|
8461
|
+
${EVENT_DATETIME_FIELDS_FRAGMENT}
|
|
8462
|
+
${LOCATION_FIELDS_FRAGMENT}
|
|
8463
|
+
${RESOURCE_IMAGE_FIELDS_FRAGMENT}
|
|
8464
|
+
`;
|
|
8429
8465
|
var EVENT_INFO = gql`
|
|
8430
8466
|
fragment EventInfoFields on EventInfoType {
|
|
8431
8467
|
_id
|
|
@@ -8529,10 +8565,10 @@ var EVENT = gql`
|
|
|
8529
8565
|
var GET_EVENTS = gql`
|
|
8530
8566
|
query getEvents {
|
|
8531
8567
|
events {
|
|
8532
|
-
...
|
|
8568
|
+
...EventListItemFields
|
|
8533
8569
|
}
|
|
8534
8570
|
}
|
|
8535
|
-
${
|
|
8571
|
+
${EVENT_LIST_ITEM}
|
|
8536
8572
|
`;
|
|
8537
8573
|
var GET_EVENT = gql`
|
|
8538
8574
|
query getEvent($_id: ID!) {
|
|
@@ -8545,26 +8581,26 @@ var GET_EVENT = gql`
|
|
|
8545
8581
|
var GET_EVENTS_BY_REGION = gql`
|
|
8546
8582
|
query getEventsByRegion($region: String!) {
|
|
8547
8583
|
eventsByRegion(region: $region) {
|
|
8548
|
-
...
|
|
8584
|
+
...EventListItemFields
|
|
8549
8585
|
}
|
|
8550
8586
|
}
|
|
8551
|
-
${
|
|
8587
|
+
${EVENT_LIST_ITEM}
|
|
8552
8588
|
`;
|
|
8553
8589
|
var SEARCH_EVENTS = gql`
|
|
8554
8590
|
query searchEvents($search: String!, $region: String) {
|
|
8555
8591
|
eventsSearch(search: $search, region: $region) {
|
|
8556
|
-
...
|
|
8592
|
+
...EventListItemFields
|
|
8557
8593
|
}
|
|
8558
8594
|
}
|
|
8559
|
-
${
|
|
8595
|
+
${EVENT_LIST_ITEM}
|
|
8560
8596
|
`;
|
|
8561
8597
|
var GET_EVENTS_NEAR_ME = gql`
|
|
8562
8598
|
query getEventsNearMe($latitude: Float!, $longitude: Float!, $radius: Int) {
|
|
8563
8599
|
eventsNearMe(latitude: $latitude, longitude: $longitude, radius: $radius) {
|
|
8564
|
-
...
|
|
8600
|
+
...EventListItemFields
|
|
8565
8601
|
}
|
|
8566
8602
|
}
|
|
8567
|
-
${
|
|
8603
|
+
${EVENT_LIST_ITEM}
|
|
8568
8604
|
`;
|
|
8569
8605
|
var GET_EVENT_INFO = gql`
|
|
8570
8606
|
query getEventInfo($eventId: ID!) {
|
|
@@ -9196,36 +9232,6 @@ var SEARCH_PARTNERS = gql`
|
|
|
9196
9232
|
}
|
|
9197
9233
|
${PARTNER}
|
|
9198
9234
|
`;
|
|
9199
|
-
var USER_ACTIVITY_EVENT_FRAGMENT = gql`
|
|
9200
|
-
fragment UserActivityEventFields on UserActivityEventType {
|
|
9201
|
-
_id
|
|
9202
|
-
active
|
|
9203
|
-
cover {
|
|
9204
|
-
...ResourceImageFields
|
|
9205
|
-
}
|
|
9206
|
-
dateTime {
|
|
9207
|
-
...EventDateTimeFields
|
|
9208
|
-
}
|
|
9209
|
-
description
|
|
9210
|
-
eventType
|
|
9211
|
-
location {
|
|
9212
|
-
...LocationFields
|
|
9213
|
-
}
|
|
9214
|
-
logo {
|
|
9215
|
-
...ResourceImageFields
|
|
9216
|
-
}
|
|
9217
|
-
name
|
|
9218
|
-
rainOrShine
|
|
9219
|
-
region
|
|
9220
|
-
socialMedia {
|
|
9221
|
-
...SocialMediaFields
|
|
9222
|
-
}
|
|
9223
|
-
}
|
|
9224
|
-
${SOCIAL_MEDIA_FIELDS_FRAGMENT}
|
|
9225
|
-
${LOCATION_FIELDS_FRAGMENT}
|
|
9226
|
-
${RESOURCE_IMAGE_FIELDS_FRAGMENT}
|
|
9227
|
-
${EVENT_DATETIME_FIELDS_FRAGMENT}
|
|
9228
|
-
`;
|
|
9229
9235
|
var GET_USERS = gql`
|
|
9230
9236
|
query getUsers {
|
|
9231
9237
|
users {
|
|
@@ -9271,7 +9277,7 @@ var GET_USER_ACTIVITIES = gql`
|
|
|
9271
9277
|
userActivities {
|
|
9272
9278
|
favourites {
|
|
9273
9279
|
events {
|
|
9274
|
-
...
|
|
9280
|
+
...EventListItemFields
|
|
9275
9281
|
}
|
|
9276
9282
|
vendors {
|
|
9277
9283
|
...VendorFields
|
|
@@ -9279,24 +9285,23 @@ var GET_USER_ACTIVITIES = gql`
|
|
|
9279
9285
|
}
|
|
9280
9286
|
going {
|
|
9281
9287
|
events {
|
|
9282
|
-
...
|
|
9288
|
+
...EventListItemFields
|
|
9283
9289
|
}
|
|
9284
9290
|
}
|
|
9285
9291
|
interested {
|
|
9286
9292
|
events {
|
|
9287
|
-
...
|
|
9293
|
+
...EventListItemFields
|
|
9288
9294
|
}
|
|
9289
9295
|
}
|
|
9290
9296
|
present {
|
|
9291
9297
|
events {
|
|
9292
|
-
...
|
|
9298
|
+
...EventListItemFields
|
|
9293
9299
|
}
|
|
9294
9300
|
}
|
|
9295
9301
|
}
|
|
9296
9302
|
}
|
|
9297
|
-
${
|
|
9303
|
+
${EVENT_LIST_ITEM}
|
|
9298
9304
|
${VENDOR}
|
|
9299
|
-
${USER_ACTIVITY_EVENT_FRAGMENT}
|
|
9300
9305
|
`;
|
|
9301
9306
|
var NOTIFICATION_FRAGMENT = gql`
|
|
9302
9307
|
fragment NotificationFields on Notification {
|
|
@@ -9453,7 +9458,7 @@ var GET_RESOURCE_CONNECTIONS = gql`
|
|
|
9453
9458
|
) {
|
|
9454
9459
|
resourceConnections(resourceId: $resourceId, resourceType: $resourceType) {
|
|
9455
9460
|
events {
|
|
9456
|
-
...
|
|
9461
|
+
...EventListItemFields
|
|
9457
9462
|
}
|
|
9458
9463
|
vendors {
|
|
9459
9464
|
...VendorFields
|
|
@@ -9461,7 +9466,7 @@ var GET_RESOURCE_CONNECTIONS = gql`
|
|
|
9461
9466
|
}
|
|
9462
9467
|
}
|
|
9463
9468
|
${VENDOR}
|
|
9464
|
-
${
|
|
9469
|
+
${EVENT_LIST_ITEM}
|
|
9465
9470
|
`;
|
|
9466
9471
|
var CREATE_RELATION_MUTATION = gql`
|
|
9467
9472
|
mutation createRelation($input: RelationInputType!) {
|
|
@@ -9969,6 +9974,13 @@ var UPDATE_APP_SETTINGS_MUTATION = gql`
|
|
|
9969
9974
|
updateAppSettings(input: $input)
|
|
9970
9975
|
}
|
|
9971
9976
|
`;
|
|
9977
|
+
var CRAWL_GOOGLE_MARKETS_MUTATION = gql`
|
|
9978
|
+
mutation crawlGoogleMarkets {
|
|
9979
|
+
crawlGoogleMarkets {
|
|
9980
|
+
message
|
|
9981
|
+
}
|
|
9982
|
+
}
|
|
9983
|
+
`;
|
|
9972
9984
|
var APP_SETTINGS_FIELDS_FRAGMENT = gql`
|
|
9973
9985
|
fragment AppSettingsFields on AppSettingsType {
|
|
9974
9986
|
_id
|
|
@@ -9986,97 +9998,6 @@ var GET_APP_SETTINGS = gql`
|
|
|
9986
9998
|
}
|
|
9987
9999
|
${APP_SETTINGS_FIELDS_FRAGMENT}
|
|
9988
10000
|
`;
|
|
9989
|
-
var CRAWL_GOOGLE_MARKETS_MUTATION = gql`
|
|
9990
|
-
mutation crawlGoogleMarkets {
|
|
9991
|
-
crawlGoogleMarkets {
|
|
9992
|
-
message
|
|
9993
|
-
}
|
|
9994
|
-
}
|
|
9995
|
-
`;
|
|
9996
|
-
var GOOGLE_IMPORTED_MARKETS_FIELDS_FRAGMENT = gql`
|
|
9997
|
-
fragment GoogleImportedMarketsFields on GoogleImportedMarketType {
|
|
9998
|
-
_id
|
|
9999
|
-
accessibilityOptions
|
|
10000
|
-
address
|
|
10001
|
-
addressComponents {
|
|
10002
|
-
longName
|
|
10003
|
-
shortName
|
|
10004
|
-
types
|
|
10005
|
-
}
|
|
10006
|
-
allowsDogs
|
|
10007
|
-
businessStatus
|
|
10008
|
-
claimed
|
|
10009
|
-
createdAt
|
|
10010
|
-
dateTime {
|
|
10011
|
-
...EventDateTimeFields
|
|
10012
|
-
}
|
|
10013
|
-
goodForChildren
|
|
10014
|
-
goodForGroups
|
|
10015
|
-
googleMapsUrl
|
|
10016
|
-
googlePlaceId
|
|
10017
|
-
image
|
|
10018
|
-
importedAt
|
|
10019
|
-
liveMusic
|
|
10020
|
-
location {
|
|
10021
|
-
lat
|
|
10022
|
-
lng
|
|
10023
|
-
}
|
|
10024
|
-
name
|
|
10025
|
-
openingHours
|
|
10026
|
-
parkingOptions
|
|
10027
|
-
paymentOptions
|
|
10028
|
-
phone
|
|
10029
|
-
photos
|
|
10030
|
-
rating
|
|
10031
|
-
region
|
|
10032
|
-
restroom
|
|
10033
|
-
reviewCount
|
|
10034
|
-
slug
|
|
10035
|
-
updatedAt
|
|
10036
|
-
website
|
|
10037
|
-
}
|
|
10038
|
-
${EVENT_DATETIME_FIELDS_FRAGMENT}
|
|
10039
|
-
`;
|
|
10040
|
-
var GET_GOOGLE_IMPORTED_MARKETS = gql`
|
|
10041
|
-
query getGoogleImportedMarkets {
|
|
10042
|
-
googleImportedMarkets {
|
|
10043
|
-
...GoogleImportedMarketsFields
|
|
10044
|
-
}
|
|
10045
|
-
}
|
|
10046
|
-
${GOOGLE_IMPORTED_MARKETS_FIELDS_FRAGMENT}
|
|
10047
|
-
`;
|
|
10048
|
-
var GET_GOOGLE_IMPORTED_MARKETS_BY_REGION = gql`
|
|
10049
|
-
query getGoogleImportedMarketsByRegion($region: String!) {
|
|
10050
|
-
googleImportedMarketsByRegion(region: $region) {
|
|
10051
|
-
...GoogleImportedMarketsFields
|
|
10052
|
-
}
|
|
10053
|
-
}
|
|
10054
|
-
${GOOGLE_IMPORTED_MARKETS_FIELDS_FRAGMENT}
|
|
10055
|
-
`;
|
|
10056
|
-
var SEARCH_GOOGLE_IMPORTED_MARKETS = gql`
|
|
10057
|
-
query searchGoogleImportedMarkets($search: String!, $region: String) {
|
|
10058
|
-
googleImportedMarketsSearch(search: $search, region: $region) {
|
|
10059
|
-
...GoogleImportedMarketsFields
|
|
10060
|
-
}
|
|
10061
|
-
}
|
|
10062
|
-
${GOOGLE_IMPORTED_MARKETS_FIELDS_FRAGMENT}
|
|
10063
|
-
`;
|
|
10064
|
-
var GET_GOOGLE_IMPORTED_MARKETS_NEAR_ME = gql`
|
|
10065
|
-
query getGoogleImportedMarketsNearMe(
|
|
10066
|
-
$latitude: Float!
|
|
10067
|
-
$longitude: Float!
|
|
10068
|
-
$radius: Int
|
|
10069
|
-
) {
|
|
10070
|
-
googleImportedMarketsNearMe(
|
|
10071
|
-
lat: $latitude
|
|
10072
|
-
lng: $longitude
|
|
10073
|
-
radius: $radius
|
|
10074
|
-
) {
|
|
10075
|
-
...GoogleImportedMarketsFields
|
|
10076
|
-
}
|
|
10077
|
-
}
|
|
10078
|
-
${GOOGLE_IMPORTED_MARKETS_FIELDS_FRAGMENT}
|
|
10079
|
-
`;
|
|
10080
10001
|
var nzBankAccountRegex = /^\d{2}-\d{4}-\d{7}-\d{2}$/;
|
|
10081
10002
|
var nzbnRegex = /^94\d{11}$/;
|
|
10082
10003
|
var normalizedUrlTransform = () => create$6().trim().transform(
|
|
@@ -11082,6 +11003,29 @@ var dateTimeSchema3 = new MongooseSchema3(
|
|
|
11082
11003
|
{ _id: false }
|
|
11083
11004
|
// Prevents Mongoose from creating an additional _id field for subdocuments
|
|
11084
11005
|
);
|
|
11006
|
+
var locationsSchema = new MongooseSchema3(
|
|
11007
|
+
{
|
|
11008
|
+
city: { required: true, type: String },
|
|
11009
|
+
coordinates: {
|
|
11010
|
+
required: true,
|
|
11011
|
+
type: [Number]
|
|
11012
|
+
// [longitude, latitude]
|
|
11013
|
+
},
|
|
11014
|
+
country: { required: true, type: String },
|
|
11015
|
+
fullAddress: { required: true, type: String },
|
|
11016
|
+
latitude: { required: true, type: Number },
|
|
11017
|
+
longitude: { required: true, type: Number },
|
|
11018
|
+
region: { required: true, type: String },
|
|
11019
|
+
type: {
|
|
11020
|
+
default: "Point",
|
|
11021
|
+
enum: ["Point"],
|
|
11022
|
+
required: true,
|
|
11023
|
+
type: String
|
|
11024
|
+
}
|
|
11025
|
+
},
|
|
11026
|
+
{ _id: false }
|
|
11027
|
+
// Prevents Mongoose from creating an additional _id field for subdocuments
|
|
11028
|
+
);
|
|
11085
11029
|
var baseResourceFields = {
|
|
11086
11030
|
active: { default: false, required: true, type: Boolean },
|
|
11087
11031
|
adIds: {
|
|
@@ -11231,14 +11175,6 @@ var ChatModel = mongoose5.models.Chat || mongoose5.model("Chat", ChatSchema);
|
|
|
11231
11175
|
// src/mongoose/GoogleImportedMarket.ts
|
|
11232
11176
|
import mongoose6 from "mongoose";
|
|
11233
11177
|
var MongooseSchema6 = mongoose6.Schema;
|
|
11234
|
-
var locationSchema2 = new MongooseSchema6(
|
|
11235
|
-
{
|
|
11236
|
-
lat: { required: true, type: Number },
|
|
11237
|
-
lng: { required: true, type: Number }
|
|
11238
|
-
},
|
|
11239
|
-
{ _id: false }
|
|
11240
|
-
// Prevents Mongoose from creating an additional _id field for subdocuments
|
|
11241
|
-
);
|
|
11242
11178
|
var addressComponentSchema = new MongooseSchema6(
|
|
11243
11179
|
{
|
|
11244
11180
|
longName: { required: false, type: String },
|
|
@@ -11250,12 +11186,18 @@ var addressComponentSchema = new MongooseSchema6(
|
|
|
11250
11186
|
var schema3 = new MongooseSchema6(
|
|
11251
11187
|
{
|
|
11252
11188
|
accessibilityOptions: { required: false, type: Object },
|
|
11189
|
+
active: { default: false, required: true, type: Boolean },
|
|
11253
11190
|
address: { required: true, type: String },
|
|
11254
11191
|
addressComponents: { required: false, type: [addressComponentSchema] },
|
|
11255
11192
|
allowsDogs: { required: false, type: Boolean },
|
|
11256
11193
|
businessStatus: { required: false, type: String },
|
|
11257
11194
|
claimed: { default: false, required: true, type: Boolean },
|
|
11195
|
+
cover: {
|
|
11196
|
+
required: false,
|
|
11197
|
+
type: ResourceImageTypeSchema
|
|
11198
|
+
},
|
|
11258
11199
|
dateTime: [dateTimeSchema3],
|
|
11200
|
+
deletedAt: { default: null, required: false, type: Date },
|
|
11259
11201
|
goodForChildren: { required: false, type: Boolean },
|
|
11260
11202
|
goodForGroups: { required: false, type: Boolean },
|
|
11261
11203
|
googleMapsUrl: { required: false, type: String },
|
|
@@ -11265,22 +11207,20 @@ var schema3 = new MongooseSchema6(
|
|
|
11265
11207
|
unique: true
|
|
11266
11208
|
// unique, indexed
|
|
11267
11209
|
},
|
|
11268
|
-
|
|
11269
|
-
// photo_reference
|
|
11210
|
+
images: { required: false, type: [ResourceImageTypeSchema] },
|
|
11211
|
+
// array of photo_reference
|
|
11270
11212
|
importedAt: { default: () => /* @__PURE__ */ new Date(), required: true, type: Date },
|
|
11271
11213
|
liveMusic: { required: false, type: Boolean },
|
|
11272
11214
|
location: {
|
|
11273
11215
|
required: false,
|
|
11274
11216
|
// optional because lat/lng may expire after 30 days
|
|
11275
|
-
type:
|
|
11217
|
+
type: locationsSchema
|
|
11276
11218
|
},
|
|
11277
11219
|
name: { required: true, type: String },
|
|
11278
11220
|
openingHours: { required: false, type: [String] },
|
|
11279
11221
|
parkingOptions: { required: false, type: Object },
|
|
11280
11222
|
paymentOptions: { required: false, type: Object },
|
|
11281
11223
|
phone: { required: false, type: String },
|
|
11282
|
-
photos: { required: false, type: [String] },
|
|
11283
|
-
// array of photo_reference
|
|
11284
11224
|
rating: { required: false, type: Number },
|
|
11285
11225
|
region: { required: false, type: String },
|
|
11286
11226
|
restroom: { required: false, type: Boolean },
|
|
@@ -11874,29 +11814,6 @@ var VendorInfoModel = mongoose14.models.VendorInfo || mongoose14.model("VendorIn
|
|
|
11874
11814
|
// src/mongoose/event/Event.ts
|
|
11875
11815
|
import mongoose15 from "mongoose";
|
|
11876
11816
|
var MongooseSchema15 = mongoose15.Schema;
|
|
11877
|
-
var locationsSchema = new MongooseSchema15(
|
|
11878
|
-
{
|
|
11879
|
-
city: { required: true, type: String },
|
|
11880
|
-
coordinates: {
|
|
11881
|
-
required: true,
|
|
11882
|
-
type: [Number]
|
|
11883
|
-
// [longitude, latitude]
|
|
11884
|
-
},
|
|
11885
|
-
country: { required: true, type: String },
|
|
11886
|
-
fullAddress: { required: true, type: String },
|
|
11887
|
-
latitude: { required: true, type: Number },
|
|
11888
|
-
longitude: { required: true, type: Number },
|
|
11889
|
-
region: { required: true, type: String },
|
|
11890
|
-
type: {
|
|
11891
|
-
default: "Point",
|
|
11892
|
-
enum: ["Point"],
|
|
11893
|
-
required: true,
|
|
11894
|
-
type: String
|
|
11895
|
-
}
|
|
11896
|
-
},
|
|
11897
|
-
{ _id: false }
|
|
11898
|
-
// Prevents Mongoose from creating an additional _id field for subdocuments
|
|
11899
|
-
);
|
|
11900
11817
|
var schema11 = new MongooseSchema15(
|
|
11901
11818
|
{
|
|
11902
11819
|
...baseResourceFields,
|
|
@@ -12032,6 +11949,7 @@ export {
|
|
|
12032
11949
|
termsAgreementSchema,
|
|
12033
11950
|
resourceRelationsSchema,
|
|
12034
11951
|
dateTimeSchema3 as dateTimeSchema,
|
|
11952
|
+
locationsSchema,
|
|
12035
11953
|
baseResourceFields,
|
|
12036
11954
|
AdModel,
|
|
12037
11955
|
ParticipantSchema,
|
|
@@ -12045,7 +11963,6 @@ export {
|
|
|
12045
11963
|
VerificationTokenModel,
|
|
12046
11964
|
VendorModel,
|
|
12047
11965
|
VendorInfoModel,
|
|
12048
|
-
locationsSchema,
|
|
12049
11966
|
EventModel,
|
|
12050
11967
|
PartnerModel,
|
|
12051
11968
|
PostModel,
|
|
@@ -12076,4 +11993,4 @@ react/cjs/react.development.js:
|
|
|
12076
11993
|
* LICENSE file in the root directory of this source tree.
|
|
12077
11994
|
*)
|
|
12078
11995
|
*/
|
|
12079
|
-
//# sourceMappingURL=chunk-
|
|
11996
|
+
//# sourceMappingURL=chunk-DS5E2QOI.mjs.map
|