@7365admin1/core 3.32.2-staging.10 → 3.32.2-staging.12
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/CHANGELOG.md +30 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +37 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +37 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,35 @@
|
|
|
1
1
|
# @iservice365/core
|
|
2
2
|
|
|
3
|
+
## 3.34.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 195c268: Fix manpower alert email flood: dedupe daily remark creation per site, skip alerts for sites without recipient emails, send one alert per site per alert time, and enforce a configurable daily alert limit (MANPOWER_ALERT_DAILY_LIMIT, default 50)
|
|
8
|
+
|
|
9
|
+
## 3.34.2
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- d81eaf1: Add request payload and response logging to the three invite endpoints (`createSimpleUserInvite`, `createSimpleMemberInvite`, `createServiceProviderInvite`) to diagnose reports of invites not sending. Logs at info level on success, and includes the payload alongside the existing error log on failure.
|
|
14
|
+
|
|
15
|
+
## 3.34.1
|
|
16
|
+
|
|
17
|
+
### Patch Changes
|
|
18
|
+
|
|
19
|
+
- 8986923: Fix `@7365admin1/node-server-utils` dependency to point at the real published `^1.6.0` instead of a leftover staging prerelease pin (`1.5.1-staging.1`). The stale prerelease caused a duplicate nested copy of node-server-utils to be installed alongside the real one, triggering "Unable to connect to server" errors at startup in consuming apps.
|
|
20
|
+
|
|
21
|
+
## 3.34.0
|
|
22
|
+
|
|
23
|
+
### Minor Changes
|
|
24
|
+
|
|
25
|
+
- 36c0873: Add `MAILER_FROM_EMAIL` config so the mailer's SMTP auth login and display sender can differ, needed for relaying through Brevo (or any provider whose SMTP login differs from the desired sender address). Falls back to the existing behavior when unset.
|
|
26
|
+
|
|
27
|
+
## 3.33.0
|
|
28
|
+
|
|
29
|
+
### Minor Changes
|
|
30
|
+
|
|
31
|
+
- fd94267: release api changes
|
|
32
|
+
|
|
3
33
|
## 3.32.0
|
|
4
34
|
|
|
5
35
|
### Minor Changes
|
package/dist/index.d.ts
CHANGED
|
@@ -7438,6 +7438,7 @@ declare function useChatPrelovedRepo(): {
|
|
|
7438
7438
|
add: (value: TChatPreloved, session?: any) => Promise<string | ObjectId>;
|
|
7439
7439
|
updateById: (_id: string | ObjectId, value: Partial<TChatPreloved>) => Promise<string>;
|
|
7440
7440
|
deleteById: (_id: string | ObjectId) => Promise<string>;
|
|
7441
|
+
createIndexes: () => Promise<string>;
|
|
7441
7442
|
};
|
|
7442
7443
|
|
|
7443
7444
|
declare function useChatPrelovedService(): {
|
|
@@ -7490,6 +7491,7 @@ declare function useChannelPrelovedRepo(): {
|
|
|
7490
7491
|
pages: number;
|
|
7491
7492
|
pageRange: string;
|
|
7492
7493
|
}>;
|
|
7494
|
+
createIndexes: () => Promise<string>;
|
|
7493
7495
|
};
|
|
7494
7496
|
|
|
7495
7497
|
declare function useChannelPrelovedController(): {
|
package/dist/index.js
CHANGED
|
@@ -68694,6 +68694,18 @@ function useChatPrelovedRepo() {
|
|
|
68694
68694
|
throw new import_node_server_utils247.InternalServerError("Unable to connect to server.");
|
|
68695
68695
|
const CHAT_COLLECTION = "chat-preloved";
|
|
68696
68696
|
const collection = db.collection(CHAT_COLLECTION);
|
|
68697
|
+
async function createIndexes() {
|
|
68698
|
+
try {
|
|
68699
|
+
await collection.createIndexes([
|
|
68700
|
+
{ key: { channelId: 1, deletedAt: 1, createdAt: -1 } }
|
|
68701
|
+
]);
|
|
68702
|
+
return `Successfully created indexes for ${CHAT_COLLECTION}.`;
|
|
68703
|
+
} catch (error) {
|
|
68704
|
+
throw new import_node_server_utils247.InternalServerError(
|
|
68705
|
+
"Failed to create indexes on chat-preloved."
|
|
68706
|
+
);
|
|
68707
|
+
}
|
|
68708
|
+
}
|
|
68697
68709
|
async function add(value, session) {
|
|
68698
68710
|
try {
|
|
68699
68711
|
const doc = MChatPreloved(value);
|
|
@@ -68738,7 +68750,7 @@ function useChatPrelovedRepo() {
|
|
|
68738
68750
|
throw new import_node_server_utils247.InternalServerError("Unable to delete chat.");
|
|
68739
68751
|
return "Chat deleted successfully.";
|
|
68740
68752
|
}
|
|
68741
|
-
return { add, updateById, deleteById };
|
|
68753
|
+
return { add, updateById, deleteById, createIndexes };
|
|
68742
68754
|
}
|
|
68743
68755
|
|
|
68744
68756
|
// src/services/chat-preloved.service.ts
|
|
@@ -68795,6 +68807,23 @@ function useChannelPrelovedRepo() {
|
|
|
68795
68807
|
const CHANNEL_COLLECTION = "channel-preloved";
|
|
68796
68808
|
const CHAT_COLLECTION = "chat-preloved";
|
|
68797
68809
|
const collection = db.collection(CHANNEL_COLLECTION);
|
|
68810
|
+
async function createIndexes() {
|
|
68811
|
+
try {
|
|
68812
|
+
await collection.createIndexes([
|
|
68813
|
+
// getByParticipants: exact channel lookup by sender+receiver+post.
|
|
68814
|
+
// Its senderId prefix also serves the senderId branch of getChatLists' $or.
|
|
68815
|
+
{ key: { senderId: 1, receiverId: 1, postId: 1 } },
|
|
68816
|
+
// getChatLists $or: the receiverId branch (senderId is covered by the
|
|
68817
|
+
// compound prefix above).
|
|
68818
|
+
{ key: { receiverId: 1 } }
|
|
68819
|
+
]);
|
|
68820
|
+
return `Successfully created indexes for ${CHANNEL_COLLECTION}.`;
|
|
68821
|
+
} catch (error) {
|
|
68822
|
+
throw new import_node_server_utils248.InternalServerError(
|
|
68823
|
+
"Failed to create indexes on channel-preloved."
|
|
68824
|
+
);
|
|
68825
|
+
}
|
|
68826
|
+
}
|
|
68798
68827
|
async function add(value, session) {
|
|
68799
68828
|
try {
|
|
68800
68829
|
const doc = MChannelPreloved(value);
|
|
@@ -69013,7 +69042,13 @@ function useChannelPrelovedRepo() {
|
|
|
69013
69042
|
throw error;
|
|
69014
69043
|
}
|
|
69015
69044
|
}
|
|
69016
|
-
return {
|
|
69045
|
+
return {
|
|
69046
|
+
add,
|
|
69047
|
+
getByParticipants,
|
|
69048
|
+
getChatLists,
|
|
69049
|
+
getChannelMessages,
|
|
69050
|
+
createIndexes
|
|
69051
|
+
};
|
|
69017
69052
|
}
|
|
69018
69053
|
|
|
69019
69054
|
// src/services/chat-preloved.service.ts
|