@timardex/cluemart-server-shared 1.0.141 → 1.0.143
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-7PPWLIUD.mjs → chunk-FA5DXWVE.mjs} +114 -8
- package/dist/chunk-FA5DXWVE.mjs.map +1 -0
- package/dist/index.cjs +113 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +113 -7
- package/dist/index.mjs.map +1 -1
- package/dist/mongoose/index.cjs +113 -7
- package/dist/mongoose/index.cjs.map +1 -1
- package/dist/mongoose/index.mjs +1 -1
- package/dist/service/index.cjs +113 -7
- package/dist/service/index.cjs.map +1 -1
- package/dist/service/index.mjs +1 -1
- package/package.json +2 -2
- package/dist/chunk-7PPWLIUD.mjs.map +0 -1
package/dist/mongoose/index.mjs
CHANGED
package/dist/service/index.cjs
CHANGED
|
@@ -6797,22 +6797,24 @@ var EnumNotificationResourceType = /* @__PURE__ */ ((EnumNotificationResourceTyp
|
|
|
6797
6797
|
EnumNotificationResourceType22["CREATED_EVENT"] = "created_event";
|
|
6798
6798
|
EnumNotificationResourceType22["CREATED_PARTNER"] = "created_partner";
|
|
6799
6799
|
EnumNotificationResourceType22["CREATED_VENDOR"] = "created_vendor";
|
|
6800
|
+
EnumNotificationResourceType22["DAILY_CLUE_GAME"] = "daily_clue_game";
|
|
6800
6801
|
EnumNotificationResourceType22["DEACTIVATED_EVENT"] = "deactivated_event";
|
|
6801
6802
|
EnumNotificationResourceType22["DEACTIVATED_PARTNER"] = "deactivated_partner";
|
|
6802
6803
|
EnumNotificationResourceType22["DEACTIVATED_VENDOR"] = "deactivated_vendor";
|
|
6803
|
-
EnumNotificationResourceType22["DOWNGRADED_EVENT"] = "downgraded_event";
|
|
6804
|
-
EnumNotificationResourceType22["DOWNGRADED_PARTNER"] = "downgraded_partner";
|
|
6805
|
-
EnumNotificationResourceType22["DOWNGRADED_VENDOR"] = "downgraded_vendor";
|
|
6806
6804
|
EnumNotificationResourceType22["DECLINED_EVENT"] = "declined_event";
|
|
6807
6805
|
EnumNotificationResourceType22["DECLINED_PARTNER"] = "declined_partner";
|
|
6808
6806
|
EnumNotificationResourceType22["DECLINED_VENDOR"] = "declined_vendor";
|
|
6809
|
-
EnumNotificationResourceType22["
|
|
6807
|
+
EnumNotificationResourceType22["DOWNGRADED_EVENT"] = "downgraded_event";
|
|
6808
|
+
EnumNotificationResourceType22["DOWNGRADED_PARTNER"] = "downgraded_partner";
|
|
6809
|
+
EnumNotificationResourceType22["DOWNGRADED_VENDOR"] = "downgraded_vendor";
|
|
6810
6810
|
EnumNotificationResourceType22["EVENT_INVITE_VENDOR"] = "event_invite_vendor";
|
|
6811
6811
|
EnumNotificationResourceType22["EVENT_STARTING_SOON"] = "event_starting_soon";
|
|
6812
6812
|
EnumNotificationResourceType22["EXPIRATION_REMINDER_EVENT"] = "expiration_reminder_event";
|
|
6813
6813
|
EnumNotificationResourceType22["EXPIRATION_REMINDER_PARTNER"] = "expiration_reminder_partner";
|
|
6814
6814
|
EnumNotificationResourceType22["EXPIRATION_REMINDER_VENDOR"] = "expiration_reminder_vendor";
|
|
6815
6815
|
EnumNotificationResourceType22["NEW_CHAT_MESSAGE"] = "new_chat_message";
|
|
6816
|
+
EnumNotificationResourceType22["NEW_POST_CREATED"] = "new_post_created";
|
|
6817
|
+
EnumNotificationResourceType22["REGISTERED_USER_BY_SCHOOL_CODE"] = "registered_user_by_school_code";
|
|
6816
6818
|
EnumNotificationResourceType22["SYSTEM_ALERT"] = "system_alert";
|
|
6817
6819
|
EnumNotificationResourceType22["VENDOR_APPLICATION_TO_EVENT"] = "vendor_application_to_event";
|
|
6818
6820
|
return EnumNotificationResourceType22;
|
|
@@ -6890,6 +6892,100 @@ var EnumSubscriptionStatus = /* @__PURE__ */ ((EnumSubscriptionStatus22) => {
|
|
|
6890
6892
|
EnumSubscriptionStatus22["TRIALING"] = "trialing";
|
|
6891
6893
|
return EnumSubscriptionStatus22;
|
|
6892
6894
|
})(EnumSubscriptionStatus || {});
|
|
6895
|
+
var OBJECT_ID_PATH_SEGMENT = "[a-f0-9]{24}";
|
|
6896
|
+
var OBJECT_ID_PATH_SEGMENT_END = `${OBJECT_ID_PATH_SEGMENT}$`;
|
|
6897
|
+
var gameScreenIdentifierList = [
|
|
6898
|
+
{
|
|
6899
|
+
clue: "Where your actions turn into a timeline.",
|
|
6900
|
+
id: "activities",
|
|
6901
|
+
match: "/profile/activities"
|
|
6902
|
+
},
|
|
6903
|
+
{
|
|
6904
|
+
clue: "Where conversations happen without speaking.",
|
|
6905
|
+
id: "chat",
|
|
6906
|
+
match: "/profile/chat"
|
|
6907
|
+
},
|
|
6908
|
+
{
|
|
6909
|
+
clue: "The place to redefine who you are.",
|
|
6910
|
+
id: "edit-profile",
|
|
6911
|
+
match: "/profile/edit-profile"
|
|
6912
|
+
},
|
|
6913
|
+
{
|
|
6914
|
+
clue: "A single moment worth showing up for.",
|
|
6915
|
+
id: "single-event",
|
|
6916
|
+
match: new RegExp(`^/events/${OBJECT_ID_PATH_SEGMENT_END}`)
|
|
6917
|
+
},
|
|
6918
|
+
{
|
|
6919
|
+
clue: "What\u2019s happening around you, right now.",
|
|
6920
|
+
id: "events-near-me",
|
|
6921
|
+
match: "/events/events-near-me"
|
|
6922
|
+
},
|
|
6923
|
+
{
|
|
6924
|
+
clue: "A collection of things worth attending.",
|
|
6925
|
+
id: "events",
|
|
6926
|
+
match: "/events"
|
|
6927
|
+
},
|
|
6928
|
+
{
|
|
6929
|
+
clue: "What\u2019s happening in a wider area \u2014 not just nearby.",
|
|
6930
|
+
id: "events-region",
|
|
6931
|
+
match: /^\/events\/region\/[^/]+$/
|
|
6932
|
+
},
|
|
6933
|
+
{
|
|
6934
|
+
clue: "Where fun becomes a challenge.",
|
|
6935
|
+
id: "games",
|
|
6936
|
+
match: "/games"
|
|
6937
|
+
},
|
|
6938
|
+
{
|
|
6939
|
+
clue: "Your starting point for everything.",
|
|
6940
|
+
id: "home",
|
|
6941
|
+
match: "/"
|
|
6942
|
+
},
|
|
6943
|
+
{
|
|
6944
|
+
clue: "Where the app whispers what you shouldn\u2019t miss.",
|
|
6945
|
+
id: "notifications",
|
|
6946
|
+
match: "/notifications"
|
|
6947
|
+
},
|
|
6948
|
+
{
|
|
6949
|
+
clue: "Where you fine-tune your experience.",
|
|
6950
|
+
id: "options",
|
|
6951
|
+
match: "/options"
|
|
6952
|
+
},
|
|
6953
|
+
{
|
|
6954
|
+
clue: "An organisation or creator supporting the community.",
|
|
6955
|
+
id: "single-partner",
|
|
6956
|
+
match: new RegExp(`^/partners/${OBJECT_ID_PATH_SEGMENT_END}`)
|
|
6957
|
+
},
|
|
6958
|
+
{
|
|
6959
|
+
clue: "Organisations and creators supporting the community.",
|
|
6960
|
+
id: "partners",
|
|
6961
|
+
match: "/partners"
|
|
6962
|
+
},
|
|
6963
|
+
{
|
|
6964
|
+
clue: "A single published post in full view.",
|
|
6965
|
+
id: "single-visitor-post",
|
|
6966
|
+
match: new RegExp(`^/visitors/post/${OBJECT_ID_PATH_SEGMENT_END}`)
|
|
6967
|
+
},
|
|
6968
|
+
{
|
|
6969
|
+
clue: "Your identity, on display.",
|
|
6970
|
+
id: "profile",
|
|
6971
|
+
match: "/profile"
|
|
6972
|
+
},
|
|
6973
|
+
{
|
|
6974
|
+
clue: "One stallholder offering something valuable.",
|
|
6975
|
+
id: "single-vendor",
|
|
6976
|
+
match: new RegExp(`^/vendors/${OBJECT_ID_PATH_SEGMENT_END}`)
|
|
6977
|
+
},
|
|
6978
|
+
{
|
|
6979
|
+
clue: "Where every stallholder waits under the right category.",
|
|
6980
|
+
id: "vendors",
|
|
6981
|
+
match: "/vendors"
|
|
6982
|
+
},
|
|
6983
|
+
{
|
|
6984
|
+
clue: "Where you browse articles and posts from around the platform.",
|
|
6985
|
+
id: "visitors",
|
|
6986
|
+
match: "/visitors"
|
|
6987
|
+
}
|
|
6988
|
+
];
|
|
6893
6989
|
var EnumGameType = /* @__PURE__ */ ((EnumGameType2) => {
|
|
6894
6990
|
EnumGameType2["DAILY_CLUE"] = "dailyClue";
|
|
6895
6991
|
return EnumGameType2;
|
|
@@ -10905,7 +11001,16 @@ var schoolSchema = create$3().shape({
|
|
|
10905
11001
|
});
|
|
10906
11002
|
var PKG = "@timardex/cluemart-shared";
|
|
10907
11003
|
var IMAGE_EXTENSION = ".webp";
|
|
10908
|
-
var posterIds = [
|
|
11004
|
+
var posterIds = [
|
|
11005
|
+
"mini-market1",
|
|
11006
|
+
"mini-market2",
|
|
11007
|
+
"mini-market3",
|
|
11008
|
+
"mini-market4",
|
|
11009
|
+
"mini-market5",
|
|
11010
|
+
"poster1",
|
|
11011
|
+
"poster2",
|
|
11012
|
+
"poster3"
|
|
11013
|
+
];
|
|
10909
11014
|
var posterFiles = Object.fromEntries(
|
|
10910
11015
|
posterIds.map((id) => [id, `${id}${IMAGE_EXTENSION}`])
|
|
10911
11016
|
);
|
|
@@ -11046,7 +11151,7 @@ async function saveNotificationsInDb(payload) {
|
|
|
11046
11151
|
// src/service/sendPushNotifications.ts
|
|
11047
11152
|
var import_expo_server_sdk = require("expo-server-sdk");
|
|
11048
11153
|
|
|
11049
|
-
// node_modules/@timardex/cluemart-shared/dist/chunk-
|
|
11154
|
+
// node_modules/@timardex/cluemart-shared/dist/chunk-ZR4TGWTS.mjs
|
|
11050
11155
|
var EnumOSPlatform2 = /* @__PURE__ */ ((EnumOSPlatform22) => {
|
|
11051
11156
|
EnumOSPlatform22["ANDROID"] = "android";
|
|
11052
11157
|
EnumOSPlatform22["IOS"] = "ios";
|
|
@@ -12461,7 +12566,8 @@ var import_mongoose21 = __toESM(require("mongoose"));
|
|
|
12461
12566
|
var MongooseSchema20 = import_mongoose21.default.Schema;
|
|
12462
12567
|
var schema15 = new MongooseSchema20(
|
|
12463
12568
|
{
|
|
12464
|
-
|
|
12569
|
+
// New schools are active by default
|
|
12570
|
+
active: { default: true, required: true, type: Boolean },
|
|
12465
12571
|
contactDetails: { required: false, type: ContactDetailsSchema },
|
|
12466
12572
|
deletedAt: { default: null, required: false, type: Date },
|
|
12467
12573
|
location: {
|