@messenger-box/platform-server 10.0.3-alpha.6 → 10.0.3-alpha.62
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/lib/containers/containers.js +3 -1
- package/lib/containers/containers.js.map +1 -1
- package/lib/containers/context-services-from-container.d.ts +2 -2
- package/lib/containers/context-services-from-container.js +2 -1
- package/lib/containers/context-services-from-container.js.map +1 -1
- package/lib/graphql/resolvers/channel-member.d.ts +3 -3
- package/lib/graphql/resolvers/channel-member.js +30 -5
- package/lib/graphql/resolvers/channel-member.js.map +1 -1
- package/lib/graphql/resolvers/channel.d.ts +3 -3
- package/lib/graphql/resolvers/channel.js +275 -53
- package/lib/graphql/resolvers/channel.js.map +1 -1
- package/lib/graphql/resolvers/extended-token-account.d.ts +3 -32
- package/lib/graphql/resolvers/extended-token-account.js +90 -23
- package/lib/graphql/resolvers/extended-token-account.js.map +1 -1
- package/lib/graphql/resolvers/index.d.ts +1 -31
- package/lib/graphql/resolvers/post-thread.d.ts +2 -3
- package/lib/graphql/resolvers/post-thread.js +294 -132
- package/lib/graphql/resolvers/post-thread.js.map +1 -1
- package/lib/graphql/resolvers/post.d.ts +2 -3
- package/lib/graphql/resolvers/post.js +697 -234
- package/lib/graphql/resolvers/post.js.map +1 -1
- package/lib/graphql/resolvers/reaction.d.ts +3 -3
- package/lib/graphql/resolvers/reaction.js +96 -14
- package/lib/graphql/resolvers/reaction.js.map +1 -1
- package/lib/graphql/schema/channel-member.graphql +110 -21
- package/lib/graphql/schema/channel-member.graphql.js +1 -1
- package/lib/graphql/schema/channel.graphql +331 -38
- package/lib/graphql/schema/channel.graphql.js +1 -1
- package/lib/graphql/schema/post-thread.graphql +166 -21
- package/lib/graphql/schema/post-thread.graphql.js +1 -1
- package/lib/graphql/schema/post.graphql +280 -40
- package/lib/graphql/schema/post.graphql.js +1 -1
- package/lib/graphql/schema/reaction.graphql +71 -13
- package/lib/graphql/schema/reaction.graphql.js +1 -1
- package/lib/graphql/schema/services.graphql +2 -0
- package/lib/graphql/schema/users.graphql +76 -13
- package/lib/graphql/schema/users.graphql.js +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/interfaces/index.d.ts +0 -1
- package/lib/interfaces/services.d.ts +1 -2
- package/lib/migrations/dbMigrations/AddPostsConfigurationsMigration.d.ts +17 -0
- package/lib/migrations/dbMigrations/AddPostsConfigurationsMigration.js +44 -0
- package/lib/migrations/dbMigrations/AddPostsConfigurationsMigration.js.map +1 -0
- package/lib/migrations/dbMigrations/index.d.ts +1 -0
- package/lib/migrations/index.d.ts +1 -0
- package/lib/migrations/mail-template-migration.js +1 -1
- package/lib/migrations/message-notification-template-migration.d.ts +1 -1
- package/lib/migrations/message-notification-template-migration.js +1 -1
- package/lib/plugins/channel-moleculer-service.d.ts +21 -1
- package/lib/plugins/channel-moleculer-service.js +417 -115
- package/lib/plugins/channel-moleculer-service.js.map +1 -1
- package/lib/plugins/extended-token-account-moleculer-service.d.ts +25 -1
- package/lib/plugins/extended-token-account-moleculer-service.js +348 -22
- package/lib/plugins/extended-token-account-moleculer-service.js.map +1 -1
- package/lib/plugins/messenger-notification-moleculer-service.d.ts +27 -3
- package/lib/plugins/messenger-notification-moleculer-service.js +404 -58
- package/lib/plugins/messenger-notification-moleculer-service.js.map +1 -1
- package/lib/plugins/post-moleculer-service.d.ts +85 -21
- package/lib/plugins/post-moleculer-service.js +986 -256
- package/lib/plugins/post-moleculer-service.js.map +1 -1
- package/lib/plugins/post-thread-moleculer-service.d.ts +33 -1
- package/lib/plugins/post-thread-moleculer-service.js +326 -8
- package/lib/plugins/post-thread-moleculer-service.js.map +1 -1
- package/lib/plugins/reaction-moleculer-service.js +1 -1
- package/lib/plugins/reaction-moleculer-service.js.map +1 -1
- package/lib/preferences/settings/post-settings.d.ts +2 -0
- package/lib/preferences/settings/post-settings.js +47 -9
- package/lib/preferences/settings/post-settings.js.map +1 -1
- package/lib/services/channel-service.d.ts +178 -33
- package/lib/services/channel-service.js +735 -276
- package/lib/services/channel-service.js.map +1 -1
- package/lib/services/extended-token-account-service.d.ts +130 -14
- package/lib/services/extended-token-account-service.js +462 -52
- package/lib/services/extended-token-account-service.js.map +1 -1
- package/lib/services/messenger-notification-service.d.ts +106 -13
- package/lib/services/messenger-notification-service.js +824 -442
- package/lib/services/messenger-notification-service.js.map +1 -1
- package/lib/services/post-service.d.ts +172 -16
- package/lib/services/post-service.js +580 -113
- package/lib/services/post-service.js.map +1 -1
- package/lib/services/post-thread-service.d.ts +114 -5
- package/lib/services/post-thread-service.js +400 -13
- package/lib/services/post-thread-service.js.map +1 -1
- package/lib/services/proxy-services/channel-microservice.d.ts +5 -3
- package/lib/services/proxy-services/channel-microservice.js +19 -10
- package/lib/services/proxy-services/channel-microservice.js.map +1 -1
- package/lib/services/proxy-services/messenger-notification-microservice.d.ts +128 -8
- package/lib/services/proxy-services/messenger-notification-microservice.js +324 -29
- package/lib/services/proxy-services/messenger-notification-microservice.js.map +1 -1
- package/lib/services/proxy-services/post-microservice.d.ts +186 -12
- package/lib/services/proxy-services/post-microservice.js +543 -54
- package/lib/services/proxy-services/post-microservice.js.map +1 -1
- package/lib/services/proxy-services/post-thread-microservice.d.ts +134 -3
- package/lib/services/proxy-services/post-thread-microservice.js +388 -6
- package/lib/services/proxy-services/post-thread-microservice.js.map +1 -1
- package/lib/services/proxy-services/reaction-microservice.d.ts +161 -3
- package/lib/services/proxy-services/reaction-microservice.js +474 -2
- package/lib/services/proxy-services/reaction-microservice.js.map +1 -1
- package/lib/services/reaction-service.d.ts +124 -4
- package/lib/services/reaction-service.js +415 -3
- package/lib/services/reaction-service.js.map +1 -1
- package/lib/store/models/account-token-store.d.ts +1 -1
- package/lib/store/models/account-token-store.js.map +1 -1
- package/lib/store/models/channel.d.ts +2 -3
- package/lib/store/models/channel.js +180 -71
- package/lib/store/models/channel.js.map +1 -1
- package/lib/store/models/post-thread.d.ts +3 -3
- package/lib/store/models/post-thread.js +96 -14
- package/lib/store/models/post-thread.js.map +1 -1
- package/lib/store/models/post.d.ts +2 -3
- package/lib/store/models/post.js +143 -23
- package/lib/store/models/post.js.map +1 -1
- package/lib/store/models/reaction.d.ts +2 -3
- package/lib/store/models/reaction.js +67 -8
- package/lib/store/models/reaction.js.map +1 -1
- package/lib/store/repositories/__tests__/__fixtures__/team-repository.d.ts +3 -3
- package/lib/store/repositories/channel-repository.d.ts +6 -6
- package/lib/store/repositories/channel-repository.js +5 -2
- package/lib/store/repositories/channel-repository.js.map +1 -1
- package/lib/store/repositories/post-repository.d.ts +6 -6
- package/lib/store/repositories/post-repository.js +5 -2
- package/lib/store/repositories/post-repository.js.map +1 -1
- package/lib/store/repositories/post-thread-repository.d.ts +6 -6
- package/lib/store/repositories/post-thread-repository.js +5 -2
- package/lib/store/repositories/post-thread-repository.js.map +1 -1
- package/lib/store/repositories/reaction-repository.d.ts +6 -6
- package/lib/store/repositories/reaction-repository.js +5 -2
- package/lib/store/repositories/reaction-repository.js.map +1 -1
- package/lib/templates/constants/SERVER_TYPES.ts.template +0 -3
- package/lib/templates/repositories/ChannelRepository.ts.template +3 -3
- package/lib/templates/repositories/PostRepository.ts.template +3 -3
- package/lib/templates/repositories/PostThreadRepository.ts.template +3 -3
- package/lib/templates/repositories/ReactionRepository.ts.template +3 -4
- package/lib/templates/services/ChannelService.ts.template +278 -39
- package/lib/templates/services/ExtendedTokenAccountService.ts.template +107 -3
- package/lib/templates/services/MessengerNotificationService.ts.template +94 -19
- package/lib/templates/services/PostService.ts.template +184 -20
- package/lib/templates/services/PostThreadService.ts.template +151 -6
- package/lib/templates/services/ReactionService.ts.template +129 -3
- package/package.json +4 -4
- package/lib/interfaces/context.d.ts +0 -14
- package/lib/store/models/common-options.js +0 -20
- package/lib/store/models/common-options.js.map +0 -1
|
@@ -1,20 +1,78 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
"""
|
|
2
|
+
Reaction: A user reaction to a post (emoji, like, etc.)
|
|
3
|
+
"""
|
|
4
|
+
type Reaction @entity {
|
|
5
|
+
"""
|
|
6
|
+
Unique identifier for the reaction
|
|
7
|
+
"""
|
|
8
|
+
id: ID! @id
|
|
9
|
+
|
|
10
|
+
"""
|
|
11
|
+
Reaction content (emoji, text, etc.)
|
|
12
|
+
"""
|
|
13
|
+
reaction: String! @column
|
|
14
|
+
|
|
15
|
+
"""
|
|
16
|
+
User who made the reaction
|
|
17
|
+
"""
|
|
18
|
+
user: UserAccount! @column(overrideType: "ObjectId")
|
|
19
|
+
|
|
20
|
+
"""
|
|
21
|
+
Post that was reacted to
|
|
22
|
+
"""
|
|
23
|
+
post: Post! @column(overrideType: "ObjectId")
|
|
24
|
+
|
|
25
|
+
"""
|
|
26
|
+
Creation timestamp
|
|
27
|
+
"""
|
|
28
|
+
createdAt: DateTime @column(overrideType: "Date")
|
|
29
|
+
|
|
30
|
+
"""
|
|
31
|
+
Last update timestamp
|
|
32
|
+
"""
|
|
33
|
+
updatedAt: DateTime @column(overrideType: "Date")
|
|
34
|
+
|
|
35
|
+
"""
|
|
36
|
+
Deletion timestamp
|
|
37
|
+
"""
|
|
38
|
+
deletedAt: DateTime @column(overrideType: "Date")
|
|
6
39
|
}
|
|
7
40
|
|
|
8
|
-
|
|
9
|
-
|
|
41
|
+
"""
|
|
42
|
+
Reaction input for creating reactions
|
|
43
|
+
"""
|
|
44
|
+
input ReactionInput {
|
|
45
|
+
"""
|
|
46
|
+
Reaction content
|
|
47
|
+
"""
|
|
48
|
+
reaction: String!
|
|
49
|
+
|
|
50
|
+
"""
|
|
51
|
+
Post identifier to react to
|
|
52
|
+
"""
|
|
10
53
|
post: String!
|
|
11
54
|
}
|
|
12
55
|
|
|
13
|
-
extend type Query{
|
|
14
|
-
|
|
56
|
+
extend type Query {
|
|
57
|
+
"""
|
|
58
|
+
Get all reactions for a specific post
|
|
59
|
+
"""
|
|
60
|
+
getPostReactions(message: ID!): [Reaction] @isAuthenticated
|
|
15
61
|
}
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
62
|
+
|
|
63
|
+
extend type Mutation {
|
|
64
|
+
"""
|
|
65
|
+
Add a reaction to a message
|
|
66
|
+
"""
|
|
67
|
+
addReactionToMessage(reaction: ReactionInput): Reaction @isAuthenticated @addAccountContext
|
|
68
|
+
|
|
69
|
+
"""
|
|
70
|
+
Update an existing reaction
|
|
71
|
+
"""
|
|
72
|
+
updateReactionToMessage(id: ID!, reaction: String!): Reaction @isAuthenticated @addAccountContext
|
|
73
|
+
|
|
74
|
+
"""
|
|
75
|
+
Remove a reaction from a message
|
|
76
|
+
"""
|
|
77
|
+
removeReactionFromMessage(id: ID!): Boolean @isAuthenticated @addAccountContext
|
|
20
78
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var reactionSchema = "
|
|
1
|
+
var reactionSchema = "\"\"\"\nReaction: A user reaction to a post (emoji, like, etc.)\n\"\"\"\ntype Reaction @entity {\n \"\"\"\n Unique identifier for the reaction\n \"\"\"\n id: ID! @id\n \n \"\"\"\n Reaction content (emoji, text, etc.)\n \"\"\"\n reaction: String! @column\n \n \"\"\"\n User who made the reaction\n \"\"\"\n user: UserAccount! @column(overrideType: \"ObjectId\")\n \n \"\"\"\n Post that was reacted to\n \"\"\"\n post: Post! @column(overrideType: \"ObjectId\")\n \n \"\"\"\n Creation timestamp\n \"\"\"\n createdAt: DateTime @column(overrideType: \"Date\")\n \n \"\"\"\n Last update timestamp\n \"\"\"\n updatedAt: DateTime @column(overrideType: \"Date\")\n \n \"\"\"\n Deletion timestamp\n \"\"\"\n deletedAt: DateTime @column(overrideType: \"Date\")\n}\n\n\"\"\"\nReaction input for creating reactions\n\"\"\"\ninput ReactionInput {\n \"\"\"\n Reaction content\n \"\"\"\n reaction: String!\n \n \"\"\"\n Post identifier to react to\n \"\"\"\n post: String!\n}\n\nextend type Query {\n \"\"\"\n Get all reactions for a specific post\n \"\"\"\n getPostReactions(message: ID!): [Reaction] @isAuthenticated\n}\n\nextend type Mutation {\n \"\"\"\n Add a reaction to a message\n \"\"\"\n addReactionToMessage(reaction: ReactionInput): Reaction @isAuthenticated @addAccountContext\n \n \"\"\"\n Update an existing reaction\n \"\"\"\n updateReactionToMessage(id: ID!, reaction: String!): Reaction @isAuthenticated @addAccountContext\n \n \"\"\"\n Remove a reaction from a message\n \"\"\"\n removeReactionFromMessage(id: ID!): Boolean @isAuthenticated @addAccountContext\n}\n";export{reactionSchema as default};//# sourceMappingURL=reaction.graphql.js.map
|
|
@@ -1,23 +1,86 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Messenger user status enumeration
|
|
3
|
+
"""
|
|
1
4
|
enum MessengerUserStatus {
|
|
5
|
+
"""
|
|
6
|
+
User is online and available
|
|
7
|
+
"""
|
|
2
8
|
ONLINE
|
|
9
|
+
|
|
10
|
+
"""
|
|
11
|
+
User is away
|
|
12
|
+
"""
|
|
3
13
|
AWAY
|
|
14
|
+
|
|
15
|
+
"""
|
|
16
|
+
User is busy
|
|
17
|
+
"""
|
|
4
18
|
BUSY
|
|
19
|
+
|
|
20
|
+
"""
|
|
21
|
+
User is invisible/offline
|
|
22
|
+
"""
|
|
5
23
|
INVISIBLE
|
|
6
24
|
}
|
|
7
25
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
26
|
+
"""
|
|
27
|
+
Messenger user: A user within the messenger system
|
|
28
|
+
"""
|
|
29
|
+
type MessengerUser implements IUser @entity {
|
|
30
|
+
"""
|
|
31
|
+
Unique identifier for the user
|
|
32
|
+
"""
|
|
33
|
+
id: ID! @id
|
|
34
|
+
|
|
35
|
+
"""
|
|
36
|
+
User's username
|
|
37
|
+
"""
|
|
38
|
+
username: String @column
|
|
39
|
+
|
|
40
|
+
"""
|
|
41
|
+
User's email address
|
|
42
|
+
"""
|
|
43
|
+
email: String @column
|
|
44
|
+
|
|
45
|
+
"""
|
|
46
|
+
User's current status
|
|
47
|
+
"""
|
|
48
|
+
status: MessengerUserStatus @column
|
|
49
|
+
|
|
50
|
+
"""
|
|
51
|
+
User's avatar URL
|
|
52
|
+
"""
|
|
53
|
+
avatar: String @column
|
|
54
|
+
|
|
55
|
+
"""
|
|
56
|
+
User's display name
|
|
57
|
+
"""
|
|
58
|
+
name: String @column
|
|
59
|
+
|
|
60
|
+
"""
|
|
61
|
+
Last login timestamp
|
|
62
|
+
"""
|
|
63
|
+
lastLogin: String @column(overrideType: "Date")
|
|
64
|
+
|
|
65
|
+
"""
|
|
66
|
+
Channels user is a member of
|
|
67
|
+
"""
|
|
68
|
+
channels: [Channel] @column(overrideType: "ObjectId[]")
|
|
69
|
+
|
|
70
|
+
"""
|
|
71
|
+
Direct message channels
|
|
72
|
+
"""
|
|
73
|
+
directMessages: [Channel] @column(overrideType: "ObjectId[]")
|
|
18
74
|
}
|
|
19
75
|
|
|
20
|
-
extend type Query{
|
|
21
|
-
|
|
22
|
-
|
|
76
|
+
extend type Query {
|
|
77
|
+
"""
|
|
78
|
+
Get users available for chat
|
|
79
|
+
"""
|
|
80
|
+
usersToChat(auth0Id: String!): [UserAccount] @isAuthenticated @addAccountContext
|
|
81
|
+
|
|
82
|
+
"""
|
|
83
|
+
Get current user information
|
|
84
|
+
"""
|
|
85
|
+
currentUser(auth0Id: String!): UserAccount @isAuthenticated @addAccountContext
|
|
23
86
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var usersSchema = "
|
|
1
|
+
var usersSchema = "\"\"\"\nMessenger user status enumeration\n\"\"\"\nenum MessengerUserStatus {\n \"\"\"\n User is online and available\n \"\"\"\n ONLINE\n \n \"\"\"\n User is away\n \"\"\"\n AWAY\n \n \"\"\"\n User is busy\n \"\"\"\n BUSY\n \n \"\"\"\n User is invisible/offline\n \"\"\"\n INVISIBLE\n}\n\n\"\"\"\nMessenger user: A user within the messenger system\n\"\"\"\ntype MessengerUser implements IUser @entity {\n \"\"\"\n Unique identifier for the user\n \"\"\"\n id: ID! @id\n \n \"\"\"\n User's username\n \"\"\"\n username: String @column\n \n \"\"\"\n User's email address\n \"\"\"\n email: String @column\n \n \"\"\"\n User's current status\n \"\"\"\n status: MessengerUserStatus @column\n \n \"\"\"\n User's avatar URL\n \"\"\"\n avatar: String @column\n \n \"\"\"\n User's display name\n \"\"\"\n name: String @column\n \n \"\"\"\n Last login timestamp\n \"\"\"\n lastLogin: String @column(overrideType: \"Date\")\n \n \"\"\"\n Channels user is a member of\n \"\"\"\n channels: [Channel] @column(overrideType: \"ObjectId[]\")\n \n \"\"\"\n Direct message channels\n \"\"\"\n directMessages: [Channel] @column(overrideType: \"ObjectId[]\")\n}\n\nextend type Query {\n \"\"\"\n Get users available for chat\n \"\"\"\n usersToChat(auth0Id: String!): [UserAccount] @isAuthenticated @addAccountContext\n \n \"\"\"\n Get current user information\n \"\"\"\n currentUser(auth0Id: String!): UserAccount @isAuthenticated @addAccountContext\n}\n";export{usersSchema as default};//# sourceMappingURL=users.graphql.js.map
|
package/lib/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {Feature}from'@common-stack/server-core';import MessengerModule from'./module.js';export{DEFAULT_SORTING,PAGINATION_OPTIONS}from'./constants/query.constants.js';export{DEFAULT_NOTIFY_PROPS}from'./constants/default-notify-props.js';export{PostTypes}from'./preferences/settings/post-settings.js';import'./preferences/permissions/inbox-permission-contribution.js';import'./preferences/permissions/inbox-roles-permission-overwrite.js';import'./migrations/message-notification-template-migration.js';export{MailTemplateMigration}from'./migrations/mail-template-migration.js';/* eslint-disable import/no-extraneous-dependencies */
|
|
1
|
+
import {Feature}from'@common-stack/server-core';import MessengerModule from'./module.js';export{DEFAULT_SORTING,PAGINATION_OPTIONS}from'./constants/query.constants.js';export{DEFAULT_NOTIFY_PROPS}from'./constants/default-notify-props.js';export{PostTypes}from'./preferences/settings/post-settings.js';import'./preferences/permissions/inbox-permission-contribution.js';import'./preferences/permissions/inbox-roles-permission-overwrite.js';import'./migrations/message-notification-template-migration.js';export{MailTemplateMigration}from'./migrations/mail-template-migration.js';import'./migrations/dbMigrations/AddPostsConfigurationsMigration.js';/* eslint-disable import/no-extraneous-dependencies */
|
|
2
2
|
var index = new Feature(MessengerModule);export{index as default};//# sourceMappingURL=index.js.map
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":[null],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":[null],"names":[],"mappings":"soBAAA;AAKA,YAAe,IAAI,OAAO,CAAC,eAAe,CAAC"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { IFileInfoService } from '@container-stack/file-info-core';
|
|
2
1
|
import { PubSub } from 'graphql-subscriptions';
|
|
3
|
-
import { IPostThreadService, IReactionService, IMessengerNotificationService, IExtendedTokenAccountService, IPostService, IChannelService } from 'common';
|
|
2
|
+
import { IPostThreadService, IReactionService, IMessengerNotificationService, IExtendedTokenAccountService, IPostService, IChannelService, IFileInfoService } from 'common/server';
|
|
4
3
|
export interface IServices {
|
|
5
4
|
pubsub?: PubSub;
|
|
6
5
|
channelService: IChannelService;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { IConfigurationRegistry } from '@adminide-stack/core';
|
|
2
|
+
import type { Connection } from 'mongoose';
|
|
3
|
+
import { CdmLogger } from '@cdm-logger/core';
|
|
4
|
+
import { IRedisCacheManager } from 'common/server';
|
|
5
|
+
import { BaseConfigurationsMigration } from '@adminide-stack/platform-server';
|
|
6
|
+
export declare class AddPostsConfigurationsMigration extends BaseConfigurationsMigration {
|
|
7
|
+
name: string;
|
|
8
|
+
constructor(db: Connection, configurationRegistry: IConfigurationRegistry, logger: CdmLogger.ILogger, redisCacheManager: IRedisCacheManager);
|
|
9
|
+
get id(): string;
|
|
10
|
+
get policies(): {};
|
|
11
|
+
get roles(): {};
|
|
12
|
+
get permissions(): {};
|
|
13
|
+
get settings(): {
|
|
14
|
+
[path: string]: import("@adminide-stack/core").IConfigurationPropertySchema;
|
|
15
|
+
};
|
|
16
|
+
get permissionsOverride(): {};
|
|
17
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import {__decorate,__param,__metadata}from'tslib';import {injectable,inject}from'inversify';import'@cdm-logger/core';import {SERVER_TYPES}from'common/server';import {PostSettings}from'../../preferences/settings/post-settings.js';import'../../preferences/permissions/inbox-permission-contribution.js';import'../../preferences/permissions/inbox-roles-permission-overwrite.js';import {BaseConfigurationsMigration}from'@adminide-stack/platform-server';var AddPostsConfigurationsMigration_1;
|
|
2
|
+
let AddPostsConfigurationsMigration = AddPostsConfigurationsMigration_1 = class AddPostsConfigurationsMigration extends BaseConfigurationsMigration {
|
|
3
|
+
name = 'posts';
|
|
4
|
+
constructor(db, configurationRegistry, logger, redisCacheManager) {
|
|
5
|
+
super(db, configurationRegistry, redisCacheManager, logger);
|
|
6
|
+
}
|
|
7
|
+
get id() {
|
|
8
|
+
return `${AddPostsConfigurationsMigration_1.name}_20250520`;
|
|
9
|
+
}
|
|
10
|
+
get policies() {
|
|
11
|
+
return {};
|
|
12
|
+
// return Policie
|
|
13
|
+
// sContribution.reduce(
|
|
14
|
+
// (acc, curr) => ({
|
|
15
|
+
// ...acc,
|
|
16
|
+
// ...curr,
|
|
17
|
+
// }),
|
|
18
|
+
// {},
|
|
19
|
+
// );
|
|
20
|
+
}
|
|
21
|
+
get roles() {
|
|
22
|
+
return {};
|
|
23
|
+
// return AccountRolesContribution;
|
|
24
|
+
}
|
|
25
|
+
get permissions() {
|
|
26
|
+
return {};
|
|
27
|
+
// return AccountPermissionsContribution;
|
|
28
|
+
}
|
|
29
|
+
get settings() {
|
|
30
|
+
return PostSettings;
|
|
31
|
+
// return PostSettings.reduce(
|
|
32
|
+
// (acc, curr) => ({
|
|
33
|
+
// ...acc,
|
|
34
|
+
// ...curr,
|
|
35
|
+
// }),
|
|
36
|
+
// {},
|
|
37
|
+
// );
|
|
38
|
+
}
|
|
39
|
+
get permissionsOverride() {
|
|
40
|
+
return {};
|
|
41
|
+
// return AccountRolesPermissionOverwrite;
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
AddPostsConfigurationsMigration = AddPostsConfigurationsMigration_1 = __decorate([injectable(), __param(0, inject('MongoDBConnection')), __param(1, inject(SERVER_TYPES.IConfigurationRegistry)), __param(2, inject('Logger')), __param(3, inject(SERVER_TYPES.IRedisCacheManager)), __metadata("design:paramtypes", [Function, Object, Object, Object])], AddPostsConfigurationsMigration);export{AddPostsConfigurationsMigration};//# sourceMappingURL=AddPostsConfigurationsMigration.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AddPostsConfigurationsMigration.js","sources":["../../../src/migrations/dbMigrations/AddPostsConfigurationsMigration.ts"],"sourcesContent":[null],"names":[],"mappings":";AASO,IAAM,+BAA+B,GAAA,iCAAA,GAArC,MAAM,+BAAgC,SAAQ,2BAA2B,CAAA;MACxE,GAAA;AAEJ,EAAA,WAAA,CAAA,EACiC,EAAc,qBACE,EAA6C,MAE1F,EAAyB,iBAEY,EAAA;SAEhC,CAAA,EAAA,EAAC,qBAAI,EAAA,iBAAwC,EAAA,MAAQ,CAAA;;AAG9D,EAAA,IAAA,EAAI,GAAE;AACF,IAAA,OAAA,CAAA,EAAA,iCAAU,CAAA,IAAgC,CAAA;;AAG9C,EAAA,IAAA,QAAY,GAAA;AACR,IAAA,OAAA,EAAA;;;;;;;;;;AAWJ,EAAA,IAAA,KAAS,GAAA;AACL,IAAA,OAAA,EAAA;;;AAIJ,EAAA,IAAA,WAAe,GAAA;AACX,IAAA,OAAA,EAAA;;;AAIJ,EAAA,IAAA,QAAY,GAAA;AACR,IAAA,OAAA;;;;;;;;;AAUJ,EAAA,IAAA,mBAAuB,GAAA;AACnB,IAAA,OAAA,EAAA;;;;AApDK,+BAA+B,GAAA,iCAAA,GAAA,UAAA,CAAA,CAAA,UAAA,EAAA,EAAA,OAAA,CAAA,CAAA,EAAA,MAAA,CAAA,mBAAA,CAAA,CAAA,EAAA,OAAA,CAAA,CAAA,EAAA,MAAA,CAAA,YAAA,CAAA,sBAAA,CAAA,CAAA,EAAA,OAAA,CAAA,CAAA,EAAA,MAAA,CAAA,QAAA,CAAA,CAAA,EAAA,OAAA,CAAA,CAAA,EAAA,MAAA,CAAA,YAAA,CAAA,kBAAA,CAAA,CAAA,EAAA,UAAA,CAAA,mBAAA,EAAA,CAAA,QAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA,CAAA,CAAA,CAAA,EAAA,+BAAA,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './AddPostsConfigurationsMigration';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {__decorate,__param,__metadata}from'tslib';import {injectable,inject,tagged}from'inversify';import {MailServiceAction,MoleculerServiceName}from'common';import ejsLint from'ejs-lint';import {CommonType,TaggedType}from'@common-stack/core';import {ServiceBroker}from'moleculer';import'@cdm-logger/core';import {config}from'../config/env-config.js';var MailTemplateMigration_1;
|
|
1
|
+
import {__decorate,__param,__metadata}from'tslib';import {injectable,inject,tagged}from'inversify';import {MailServiceAction,MoleculerServiceName}from'common/server';import ejsLint from'ejs-lint';import {CommonType,TaggedType}from'@common-stack/core';import {ServiceBroker}from'moleculer';import'@cdm-logger/core';import {config}from'../config/env-config.js';var MailTemplateMigration_1;
|
|
2
2
|
let MailTemplateMigration = MailTemplateMigration_1 = class MailTemplateMigration {
|
|
3
3
|
logger;
|
|
4
4
|
broker;
|
|
@@ -2,7 +2,7 @@ import { CdmLogger } from '@cdm-logger/core';
|
|
|
2
2
|
import { Connection } from 'mongoose';
|
|
3
3
|
import { IDatabaseMigration, IIResourceUtilizationSettings } from '@adminide-stack/core';
|
|
4
4
|
import { ServiceBroker } from 'moleculer';
|
|
5
|
-
import { MailTemplateId } from 'common';
|
|
5
|
+
import { MailTemplateId } from 'common/server';
|
|
6
6
|
export declare class MessageNotificationTemplateMigration implements IDatabaseMigration {
|
|
7
7
|
private logger;
|
|
8
8
|
private db;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {__decorate,__param,__metadata}from'tslib';import'@cdm-logger/core';import {Connection}from'mongoose';import {MailTemplateId,MailServiceAction,MoleculerServiceName}from'common';import {injectable,inject,tagged}from'inversify';import {CommonType,TaggedType}from'@common-stack/core';import {ServiceBroker}from'moleculer';import {config}from'../config/env-config.js';var MessageNotificationTemplateMigration_1;
|
|
1
|
+
import {__decorate,__param,__metadata}from'tslib';import'@cdm-logger/core';import {Connection}from'mongoose';import {MailTemplateId,MailServiceAction,MoleculerServiceName}from'common/server';import {injectable,inject,tagged}from'inversify';import {CommonType,TaggedType}from'@common-stack/core';import {ServiceBroker}from'moleculer';import {config}from'../config/env-config.js';var MessageNotificationTemplateMigration_1;
|
|
2
2
|
let MessageNotificationTemplateMigration = MessageNotificationTemplateMigration_1 = class MessageNotificationTemplateMigration {
|
|
3
3
|
logger;
|
|
4
4
|
db;
|
|
@@ -1,7 +1,27 @@
|
|
|
1
1
|
import { Service, ServiceBroker } from 'moleculer';
|
|
2
2
|
import { Container } from 'inversify';
|
|
3
|
+
/**
|
|
4
|
+
* Channel Moleculer Service
|
|
5
|
+
*
|
|
6
|
+
* This service exposes channel management functionality through the Moleculer microservice framework,
|
|
7
|
+
* providing distributed access to channel operations across the messenger platform.
|
|
8
|
+
*
|
|
9
|
+
* Key capabilities:
|
|
10
|
+
* - Channel lifecycle management (creation, updates, deletion)
|
|
11
|
+
* - Member management (adding, removing, role assignment)
|
|
12
|
+
* - Direct and public channel handling
|
|
13
|
+
* - Message and post management within channels
|
|
14
|
+
* - Channel visibility and access control
|
|
15
|
+
* - Notification and unread message tracking
|
|
16
|
+
* - Team-based channel organization
|
|
17
|
+
* - Channel discovery and filtering
|
|
18
|
+
* - Event-driven architecture for channel changes
|
|
19
|
+
* - Comprehensive error handling and logging
|
|
20
|
+
* - Service integration through Apollo GraphQL
|
|
21
|
+
*/
|
|
3
22
|
export declare class ChannelMoleculerService extends Service {
|
|
4
|
-
private channelService;
|
|
23
|
+
private readonly channelService;
|
|
24
|
+
private readonly container;
|
|
5
25
|
constructor(broker: ServiceBroker, { container, ...settings }: {
|
|
6
26
|
container: Container;
|
|
7
27
|
});
|