itlab-internal-services 2.0.2 → 2.1.1
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/env.d.ts +5 -0
- package/dist/env.js +8 -0
- package/dist/guards/index.d.ts +0 -2
- package/dist/guards/index.js +0 -2
- package/dist/guards/perms.guard.js +1 -1
- package/dist/index.d.ts +1 -4
- package/dist/index.js +1 -4
- package/dist/modules/authentication/authentication.module.d.ts +7 -0
- package/dist/modules/authentication/authentication.module.js +26 -0
- package/dist/modules/authentication/index.d.ts +3 -0
- package/dist/{services → modules/authentication}/index.js +5 -8
- package/dist/modules/authentication/internal/index.d.ts +3 -0
- package/dist/modules/authentication/internal/index.js +19 -0
- package/dist/modules/authentication/internal/internal.constants.d.ts +5 -0
- package/dist/modules/authentication/internal/internal.constants.js +8 -0
- package/dist/modules/authentication/internal/internal.decorators.d.ts +1 -0
- package/dist/modules/authentication/internal/internal.decorators.js +9 -0
- package/dist/modules/authentication/internal/internal.guard.d.ts +4 -0
- package/dist/modules/authentication/internal/internal.guard.js +18 -0
- package/dist/modules/authentication/internal/internal.strategy.d.ts +10 -0
- package/dist/modules/authentication/internal/internal.strategy.js +36 -0
- package/dist/modules/authentication/jwt/index.d.ts +3 -0
- package/dist/modules/authentication/jwt/index.js +19 -0
- package/dist/modules/authentication/jwt/jwt.constants.d.ts +8 -0
- package/dist/modules/authentication/jwt/jwt.constants.js +10 -0
- package/dist/modules/authentication/jwt/jwt.decorators.d.ts +5 -0
- package/dist/modules/authentication/jwt/jwt.decorators.js +21 -0
- package/dist/modules/authentication/jwt/jwt.guard.d.ts +9 -0
- package/dist/modules/authentication/jwt/jwt.guard.js +37 -0
- package/dist/modules/authentication/jwt/jwt.strategy.d.ts +9 -0
- package/dist/modules/authentication/jwt/jwt.strategy.js +35 -0
- package/dist/modules/database/database.module-options.d.ts +4 -0
- package/dist/modules/database/database.module.d.ts +6 -0
- package/dist/modules/database/database.module.js +69 -0
- package/dist/modules/database/index.d.ts +5 -0
- package/dist/modules/database/index.js +11 -0
- package/dist/{services → modules/database/model-service}/model.service.d.ts +25 -25
- package/dist/{services → modules/database/model-service}/model.service.js +11 -11
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-account.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-books.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-comments.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-content.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-demo-hive.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-events.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-hackschool.schemas.d.ts +3 -3
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-newsroom.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-podcasts.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-team.schemas.d.ts +1 -1
- package/dist/{model-schemas → modules/database/model-service/schemas}/hub-tech-radar.schemas.d.ts +2 -2
- package/dist/{services → modules/database/populate-service}/populate.service.d.ts +1 -1
- package/dist/{services → modules/database/populate-service}/populate.service.js +2 -2
- package/dist/{services → modules/database/service-mapper-service}/service-mapper.service.d.ts +1 -1
- package/dist/{services → modules/database/service-mapper-service}/service-mapper.service.js +1 -1
- package/dist/modules/index.d.ts +3 -0
- package/dist/modules/index.js +19 -0
- package/dist/{services → modules/services/account-service}/account.service.d.ts +3 -3
- package/dist/{services → modules/services/account-service}/account.service.js +10 -16
- package/dist/modules/services/comment-service/comment-service.definitions.d.ts +5 -0
- package/dist/modules/services/comment-service/comment-service.definitions.js +28 -0
- package/dist/{services → modules/services/comment-service}/comment.service.d.ts +6 -10
- package/dist/{services → modules/services/comment-service}/comment.service.js +15 -36
- package/dist/{services → modules/services/content-service}/content.service.d.ts +5 -5
- package/dist/{services → modules/services/content-service}/content.service.js +14 -19
- package/dist/modules/services/index.d.ts +9 -0
- package/dist/modules/services/index.js +22 -0
- package/dist/modules/services/mail-service/mail-service.definitions.d.ts +13 -0
- package/dist/modules/services/mail-service/mail-service.definitions.js +55 -0
- package/dist/modules/services/mail-service/mail.service.d.ts +11 -0
- package/dist/{services → modules/services/mail-service}/mail.service.js +19 -30
- package/dist/modules/services/search-service/search-service.definitions.d.ts +6 -0
- package/dist/modules/services/search-service/search-service.definitions.js +32 -0
- package/dist/modules/services/search-service/search.service.d.ts +11 -0
- package/dist/modules/services/search-service/search.service.js +46 -0
- package/dist/modules/services/services.module-utils.d.ts +7 -0
- package/dist/modules/services/services.module-utils.js +15 -0
- package/dist/modules/services/services.module.d.ts +7 -0
- package/dist/modules/services/services.module.js +30 -0
- package/dist/swagger.config.js +2 -2
- package/package.json +3 -3
- package/dist/guards/internal.guard.d.ts +0 -15
- package/dist/guards/internal.guard.js +0 -49
- package/dist/guards/jwt.guard.d.ts +0 -25
- package/dist/guards/jwt.guard.js +0 -74
- package/dist/itlab.interfaces.d.ts +0 -4
- package/dist/itlab.module-definition.d.ts +0 -4
- package/dist/itlab.module-definition.js +0 -10
- package/dist/itlab.module.d.ts +0 -3
- package/dist/itlab.module.js +0 -32
- package/dist/mongo.factory.d.ts +0 -6
- package/dist/mongo.factory.js +0 -34
- package/dist/services/index.d.ts +0 -8
- package/dist/services/mail.service.d.ts +0 -23
- package/dist/services/search.service.d.ts +0 -16
- package/dist/services/search.service.js +0 -71
- /package/dist/{itlab.interfaces.js → modules/database/database.module-options.js} +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-account.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-books.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-comments.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-content.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-demo-hive.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-events.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-hackschool.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-newsroom.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-podcasts.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-team.schemas.js +0 -0
- /package/dist/{model-schemas → modules/database/model-service/schemas}/hub-tech-radar.schemas.js +0 -0
|
@@ -23,17 +23,17 @@
|
|
|
23
23
|
/// <reference types="mongoose/types/virtuals" />
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
import { Connection, Schema } from 'mongoose';
|
|
26
|
-
import { AccountModel } from '
|
|
27
|
-
import { BookModel } from '
|
|
28
|
-
import { CommentModel } from '
|
|
29
|
-
import { ContentModel } from '
|
|
30
|
-
import { DemoModel } from '
|
|
31
|
-
import { EventModel } from '
|
|
32
|
-
import { CourseModel, DocModel, ThreadModel } from '
|
|
33
|
-
import { NewsModel } from '
|
|
34
|
-
import { PodcastModel } from '
|
|
35
|
-
import { MemberModel } from '
|
|
36
|
-
import { BlipModel, RadarModel } from '
|
|
26
|
+
import { AccountModel } from './schemas/hub-account.schemas';
|
|
27
|
+
import { BookModel } from './schemas/hub-books.schemas';
|
|
28
|
+
import { CommentModel } from './schemas/hub-comments.schemas';
|
|
29
|
+
import { ContentModel } from './schemas/hub-content.schemas';
|
|
30
|
+
import { DemoModel } from './schemas/hub-demo-hive.schemas';
|
|
31
|
+
import { EventModel } from './schemas/hub-events.schemas';
|
|
32
|
+
import { CourseModel, DocModel, ThreadModel } from './schemas/hub-hackschool.schemas';
|
|
33
|
+
import { NewsModel } from './schemas/hub-newsroom.schemas';
|
|
34
|
+
import { PodcastModel } from './schemas/hub-podcasts.schemas';
|
|
35
|
+
import { MemberModel } from './schemas/hub-team.schemas';
|
|
36
|
+
import { BlipModel, RadarModel } from './schemas/hub-tech-radar.schemas';
|
|
37
37
|
export declare class ModelService {
|
|
38
38
|
private readonly connection;
|
|
39
39
|
constructor(connection: Connection);
|
|
@@ -42,98 +42,98 @@ export declare class ModelService {
|
|
|
42
42
|
_id: import("mongoose").Types.ObjectId;
|
|
43
43
|
}, Schema<AccountModel, import("mongoose").Model<AccountModel, any, any, any, import("mongoose").Document<unknown, any, AccountModel> & AccountModel & {
|
|
44
44
|
_id: import("mongoose").Types.ObjectId;
|
|
45
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, AccountModel, import("mongoose").Document<unknown, {}, AccountModel
|
|
45
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, AccountModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<AccountModel>> & import("mongoose").FlatRecord<AccountModel> & {
|
|
46
46
|
_id: import("mongoose").Types.ObjectId;
|
|
47
47
|
}>>;
|
|
48
48
|
commentModel: () => import("mongoose").Model<CommentModel, {}, {}, {}, import("mongoose").Document<unknown, {}, CommentModel> & CommentModel & {
|
|
49
49
|
_id: import("mongoose").Types.ObjectId;
|
|
50
50
|
}, Schema<CommentModel, import("mongoose").Model<CommentModel, any, any, any, import("mongoose").Document<unknown, any, CommentModel> & CommentModel & {
|
|
51
51
|
_id: import("mongoose").Types.ObjectId;
|
|
52
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, CommentModel, import("mongoose").Document<unknown, {}, CommentModel
|
|
52
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, CommentModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<CommentModel>> & import("mongoose").FlatRecord<CommentModel> & {
|
|
53
53
|
_id: import("mongoose").Types.ObjectId;
|
|
54
54
|
}>>;
|
|
55
55
|
contentModel: () => import("mongoose").Model<ContentModel, {}, {}, {}, import("mongoose").Document<unknown, {}, ContentModel> & ContentModel & {
|
|
56
56
|
_id: import("mongoose").Types.ObjectId;
|
|
57
57
|
}, Schema<ContentModel, import("mongoose").Model<ContentModel, any, any, any, import("mongoose").Document<unknown, any, ContentModel> & ContentModel & {
|
|
58
58
|
_id: import("mongoose").Types.ObjectId;
|
|
59
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, ContentModel, import("mongoose").Document<unknown, {}, ContentModel
|
|
59
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, ContentModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<ContentModel>> & import("mongoose").FlatRecord<ContentModel> & {
|
|
60
60
|
_id: import("mongoose").Types.ObjectId;
|
|
61
61
|
}>>;
|
|
62
62
|
bookModel: () => import("mongoose").Model<BookModel, {}, {}, {}, import("mongoose").Document<unknown, {}, BookModel> & BookModel & {
|
|
63
63
|
_id: import("mongoose").Types.ObjectId;
|
|
64
64
|
}, Schema<BookModel, import("mongoose").Model<BookModel, any, any, any, import("mongoose").Document<unknown, any, BookModel> & BookModel & {
|
|
65
65
|
_id: import("mongoose").Types.ObjectId;
|
|
66
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, BookModel, import("mongoose").Document<unknown, {}, BookModel
|
|
66
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, BookModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<BookModel>> & import("mongoose").FlatRecord<BookModel> & {
|
|
67
67
|
_id: import("mongoose").Types.ObjectId;
|
|
68
68
|
}>>;
|
|
69
69
|
demoModel: () => import("mongoose").Model<DemoModel, {}, {}, {}, import("mongoose").Document<unknown, {}, DemoModel> & DemoModel & {
|
|
70
70
|
_id: import("mongoose").Types.ObjectId;
|
|
71
71
|
}, Schema<DemoModel, import("mongoose").Model<DemoModel, any, any, any, import("mongoose").Document<unknown, any, DemoModel> & DemoModel & {
|
|
72
72
|
_id: import("mongoose").Types.ObjectId;
|
|
73
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DemoModel, import("mongoose").Document<unknown, {}, DemoModel
|
|
73
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DemoModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<DemoModel>> & import("mongoose").FlatRecord<DemoModel> & {
|
|
74
74
|
_id: import("mongoose").Types.ObjectId;
|
|
75
75
|
}>>;
|
|
76
76
|
eventModel: () => import("mongoose").Model<EventModel, {}, {}, {}, import("mongoose").Document<unknown, {}, EventModel> & EventModel & {
|
|
77
77
|
_id: import("mongoose").Types.ObjectId;
|
|
78
78
|
}, Schema<EventModel, import("mongoose").Model<EventModel, any, any, any, import("mongoose").Document<unknown, any, EventModel> & EventModel & {
|
|
79
79
|
_id: import("mongoose").Types.ObjectId;
|
|
80
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, EventModel, import("mongoose").Document<unknown, {}, EventModel
|
|
80
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, EventModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<EventModel>> & import("mongoose").FlatRecord<EventModel> & {
|
|
81
81
|
_id: import("mongoose").Types.ObjectId;
|
|
82
82
|
}>>;
|
|
83
83
|
courseModel: () => import("mongoose").Model<CourseModel, {}, {}, {}, import("mongoose").Document<unknown, {}, CourseModel> & CourseModel & {
|
|
84
84
|
_id: import("mongoose").Types.ObjectId;
|
|
85
85
|
}, Schema<CourseModel, import("mongoose").Model<CourseModel, any, any, any, import("mongoose").Document<unknown, any, CourseModel> & CourseModel & {
|
|
86
86
|
_id: import("mongoose").Types.ObjectId;
|
|
87
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, CourseModel, import("mongoose").Document<unknown, {}, CourseModel
|
|
87
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, CourseModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<CourseModel>> & import("mongoose").FlatRecord<CourseModel> & {
|
|
88
88
|
_id: import("mongoose").Types.ObjectId;
|
|
89
89
|
}>>;
|
|
90
90
|
docModel: () => import("mongoose").Model<DocModel, {}, {}, {}, import("mongoose").Document<unknown, {}, DocModel> & DocModel & {
|
|
91
91
|
_id: import("mongoose").Types.ObjectId;
|
|
92
92
|
}, Schema<DocModel, import("mongoose").Model<DocModel, any, any, any, import("mongoose").Document<unknown, any, DocModel> & DocModel & {
|
|
93
93
|
_id: import("mongoose").Types.ObjectId;
|
|
94
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DocModel, import("mongoose").Document<unknown, {}, DocModel
|
|
94
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DocModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<DocModel>> & import("mongoose").FlatRecord<DocModel> & {
|
|
95
95
|
_id: import("mongoose").Types.ObjectId;
|
|
96
96
|
}>>;
|
|
97
97
|
threadModel: () => import("mongoose").Model<ThreadModel, {}, {}, {}, import("mongoose").Document<unknown, {}, ThreadModel> & ThreadModel & {
|
|
98
98
|
_id: import("mongoose").Types.ObjectId;
|
|
99
99
|
}, Schema<ThreadModel, import("mongoose").Model<ThreadModel, any, any, any, import("mongoose").Document<unknown, any, ThreadModel> & ThreadModel & {
|
|
100
100
|
_id: import("mongoose").Types.ObjectId;
|
|
101
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, ThreadModel, import("mongoose").Document<unknown, {}, ThreadModel
|
|
101
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, ThreadModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<ThreadModel>> & import("mongoose").FlatRecord<ThreadModel> & {
|
|
102
102
|
_id: import("mongoose").Types.ObjectId;
|
|
103
103
|
}>>;
|
|
104
104
|
newsModel: () => import("mongoose").Model<NewsModel, {}, {}, {}, import("mongoose").Document<unknown, {}, NewsModel> & NewsModel & {
|
|
105
105
|
_id: import("mongoose").Types.ObjectId;
|
|
106
106
|
}, Schema<NewsModel, import("mongoose").Model<NewsModel, any, any, any, import("mongoose").Document<unknown, any, NewsModel> & NewsModel & {
|
|
107
107
|
_id: import("mongoose").Types.ObjectId;
|
|
108
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, NewsModel, import("mongoose").Document<unknown, {}, NewsModel
|
|
108
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, NewsModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<NewsModel>> & import("mongoose").FlatRecord<NewsModel> & {
|
|
109
109
|
_id: import("mongoose").Types.ObjectId;
|
|
110
110
|
}>>;
|
|
111
111
|
podcastModel: () => import("mongoose").Model<PodcastModel, {}, {}, {}, import("mongoose").Document<unknown, {}, PodcastModel> & PodcastModel & {
|
|
112
112
|
_id: import("mongoose").Types.ObjectId;
|
|
113
113
|
}, Schema<PodcastModel, import("mongoose").Model<PodcastModel, any, any, any, import("mongoose").Document<unknown, any, PodcastModel> & PodcastModel & {
|
|
114
114
|
_id: import("mongoose").Types.ObjectId;
|
|
115
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, PodcastModel, import("mongoose").Document<unknown, {}, PodcastModel
|
|
115
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, PodcastModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<PodcastModel>> & import("mongoose").FlatRecord<PodcastModel> & {
|
|
116
116
|
_id: import("mongoose").Types.ObjectId;
|
|
117
117
|
}>>;
|
|
118
118
|
memberModel: () => import("mongoose").Model<MemberModel, {}, {}, {}, import("mongoose").Document<unknown, {}, MemberModel> & MemberModel & {
|
|
119
119
|
_id: import("mongoose").Types.ObjectId;
|
|
120
120
|
}, Schema<MemberModel, import("mongoose").Model<MemberModel, any, any, any, import("mongoose").Document<unknown, any, MemberModel> & MemberModel & {
|
|
121
121
|
_id: import("mongoose").Types.ObjectId;
|
|
122
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, MemberModel, import("mongoose").Document<unknown, {}, MemberModel
|
|
122
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, MemberModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<MemberModel>> & import("mongoose").FlatRecord<MemberModel> & {
|
|
123
123
|
_id: import("mongoose").Types.ObjectId;
|
|
124
124
|
}>>;
|
|
125
125
|
blipModel: () => import("mongoose").Model<BlipModel, {}, {}, {}, import("mongoose").Document<unknown, {}, BlipModel> & BlipModel & {
|
|
126
126
|
_id: import("mongoose").Types.ObjectId;
|
|
127
127
|
}, Schema<BlipModel, import("mongoose").Model<BlipModel, any, any, any, import("mongoose").Document<unknown, any, BlipModel> & BlipModel & {
|
|
128
128
|
_id: import("mongoose").Types.ObjectId;
|
|
129
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, BlipModel, import("mongoose").Document<unknown, {}, BlipModel
|
|
129
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, BlipModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<BlipModel>> & import("mongoose").FlatRecord<BlipModel> & {
|
|
130
130
|
_id: import("mongoose").Types.ObjectId;
|
|
131
131
|
}>>;
|
|
132
132
|
radarModel: () => import("mongoose").Model<RadarModel, {}, {}, {}, import("mongoose").Document<unknown, {}, RadarModel> & RadarModel & {
|
|
133
133
|
_id: import("mongoose").Types.ObjectId;
|
|
134
134
|
}, Schema<RadarModel, import("mongoose").Model<RadarModel, any, any, any, import("mongoose").Document<unknown, any, RadarModel> & RadarModel & {
|
|
135
135
|
_id: import("mongoose").Types.ObjectId;
|
|
136
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, RadarModel, import("mongoose").Document<unknown, {}, RadarModel
|
|
136
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, RadarModel, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<RadarModel>> & import("mongoose").FlatRecord<RadarModel> & {
|
|
137
137
|
_id: import("mongoose").Types.ObjectId;
|
|
138
138
|
}>>;
|
|
139
139
|
}
|
|
@@ -16,17 +16,17 @@ exports.ModelService = void 0;
|
|
|
16
16
|
const common_1 = require("@nestjs/common");
|
|
17
17
|
const mongoose_1 = require("@nestjs/mongoose");
|
|
18
18
|
const mongoose_2 = require("mongoose");
|
|
19
|
-
const hub_account_schemas_1 = require("
|
|
20
|
-
const hub_books_schemas_1 = require("
|
|
21
|
-
const hub_comments_schemas_1 = require("
|
|
22
|
-
const hub_content_schemas_1 = require("
|
|
23
|
-
const hub_demo_hive_schemas_1 = require("
|
|
24
|
-
const hub_events_schemas_1 = require("
|
|
25
|
-
const hub_hackschool_schemas_1 = require("
|
|
26
|
-
const hub_newsroom_schemas_1 = require("
|
|
27
|
-
const hub_podcasts_schemas_1 = require("
|
|
28
|
-
const hub_team_schemas_1 = require("
|
|
29
|
-
const hub_tech_radar_schemas_1 = require("
|
|
19
|
+
const hub_account_schemas_1 = require("./schemas/hub-account.schemas");
|
|
20
|
+
const hub_books_schemas_1 = require("./schemas/hub-books.schemas");
|
|
21
|
+
const hub_comments_schemas_1 = require("./schemas/hub-comments.schemas");
|
|
22
|
+
const hub_content_schemas_1 = require("./schemas/hub-content.schemas");
|
|
23
|
+
const hub_demo_hive_schemas_1 = require("./schemas/hub-demo-hive.schemas");
|
|
24
|
+
const hub_events_schemas_1 = require("./schemas/hub-events.schemas");
|
|
25
|
+
const hub_hackschool_schemas_1 = require("./schemas/hub-hackschool.schemas");
|
|
26
|
+
const hub_newsroom_schemas_1 = require("./schemas/hub-newsroom.schemas");
|
|
27
|
+
const hub_podcasts_schemas_1 = require("./schemas/hub-podcasts.schemas");
|
|
28
|
+
const hub_team_schemas_1 = require("./schemas/hub-team.schemas");
|
|
29
|
+
const hub_tech_radar_schemas_1 = require("./schemas/hub-tech-radar.schemas");
|
|
30
30
|
let ModelService = class ModelService {
|
|
31
31
|
constructor(connection) {
|
|
32
32
|
this.connection = connection;
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-account.schemas.d.ts
RENAMED
|
@@ -35,7 +35,7 @@ declare class AccountModel extends Document {
|
|
|
35
35
|
}
|
|
36
36
|
declare const AccountSchema: import("mongoose").Schema<AccountModel, import("mongoose").Model<AccountModel, any, any, any, Document<unknown, any, AccountModel> & AccountModel & {
|
|
37
37
|
_id: import("mongoose").Types.ObjectId;
|
|
38
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, AccountModel, Document<unknown, {}, AccountModel
|
|
38
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, AccountModel, Document<unknown, {}, import("mongoose").FlatRecord<AccountModel>> & import("mongoose").FlatRecord<AccountModel> & {
|
|
39
39
|
_id: import("mongoose").Types.ObjectId;
|
|
40
40
|
}>;
|
|
41
41
|
declare const AccountDB = "hub-account";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-books.schemas.d.ts
RENAMED
|
@@ -29,7 +29,7 @@ declare class BookModel extends Document {
|
|
|
29
29
|
}
|
|
30
30
|
declare const BookSchema: import("mongoose").Schema<BookModel, import("mongoose").Model<BookModel, any, any, any, Document<unknown, any, BookModel> & BookModel & {
|
|
31
31
|
_id: import("mongoose").Types.ObjectId;
|
|
32
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, BookModel, Document<unknown, {}, BookModel
|
|
32
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, BookModel, Document<unknown, {}, import("mongoose").FlatRecord<BookModel>> & import("mongoose").FlatRecord<BookModel> & {
|
|
33
33
|
_id: import("mongoose").Types.ObjectId;
|
|
34
34
|
}>;
|
|
35
35
|
declare const BooksDB = "hub-books";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-comments.schemas.d.ts
RENAMED
|
@@ -36,7 +36,7 @@ declare class CommentModel extends Document {
|
|
|
36
36
|
}
|
|
37
37
|
declare const CommentSchema: import("mongoose").Schema<CommentModel, import("mongoose").Model<CommentModel, any, any, any, Document<unknown, any, CommentModel> & CommentModel & {
|
|
38
38
|
_id: import("mongoose").Types.ObjectId;
|
|
39
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, CommentModel, Document<unknown, {}, CommentModel
|
|
39
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, CommentModel, Document<unknown, {}, import("mongoose").FlatRecord<CommentModel>> & import("mongoose").FlatRecord<CommentModel> & {
|
|
40
40
|
_id: import("mongoose").Types.ObjectId;
|
|
41
41
|
}>;
|
|
42
42
|
declare const CommentDB = "hub-comments";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-content.schemas.d.ts
RENAMED
|
@@ -32,7 +32,7 @@ declare class ContentModel extends Document {
|
|
|
32
32
|
}
|
|
33
33
|
declare const ContentSchema: import("mongoose").Schema<ContentModel, import("mongoose").Model<ContentModel, any, any, any, Document<unknown, any, ContentModel> & ContentModel & {
|
|
34
34
|
_id: import("mongoose").Types.ObjectId;
|
|
35
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, ContentModel, Document<unknown, {}, ContentModel
|
|
35
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, ContentModel, Document<unknown, {}, import("mongoose").FlatRecord<ContentModel>> & import("mongoose").FlatRecord<ContentModel> & {
|
|
36
36
|
_id: import("mongoose").Types.ObjectId;
|
|
37
37
|
}>;
|
|
38
38
|
declare const ContentDB = "hub-content";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-demo-hive.schemas.d.ts
RENAMED
|
@@ -29,7 +29,7 @@ declare class DemoModel extends Document {
|
|
|
29
29
|
}
|
|
30
30
|
declare const DemoSchema: import("mongoose").Schema<DemoModel, import("mongoose").Model<DemoModel, any, any, any, Document<unknown, any, DemoModel> & DemoModel & {
|
|
31
31
|
_id: import("mongoose").Types.ObjectId;
|
|
32
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DemoModel, Document<unknown, {}, DemoModel
|
|
32
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DemoModel, Document<unknown, {}, import("mongoose").FlatRecord<DemoModel>> & import("mongoose").FlatRecord<DemoModel> & {
|
|
33
33
|
_id: import("mongoose").Types.ObjectId;
|
|
34
34
|
}>;
|
|
35
35
|
declare const DemoHiveDB = "hub-demo-hive";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-events.schemas.d.ts
RENAMED
|
@@ -31,7 +31,7 @@ declare class EventModel extends Document {
|
|
|
31
31
|
}
|
|
32
32
|
declare const EventSchema: import("mongoose").Schema<EventModel, import("mongoose").Model<EventModel, any, any, any, Document<unknown, any, EventModel> & EventModel & {
|
|
33
33
|
_id: import("mongoose").Types.ObjectId;
|
|
34
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, EventModel, Document<unknown, {}, EventModel
|
|
34
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, EventModel, Document<unknown, {}, import("mongoose").FlatRecord<EventModel>> & import("mongoose").FlatRecord<EventModel> & {
|
|
35
35
|
_id: import("mongoose").Types.ObjectId;
|
|
36
36
|
}>;
|
|
37
37
|
declare const EventsDB = "hub-events";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-hackschool.schemas.d.ts
RENAMED
|
@@ -29,7 +29,7 @@ declare class CourseModel extends Document {
|
|
|
29
29
|
}
|
|
30
30
|
declare const CourseSchema: import("mongoose").Schema<CourseModel, import("mongoose").Model<CourseModel, any, any, any, Document<unknown, any, CourseModel> & CourseModel & {
|
|
31
31
|
_id: import("mongoose").Types.ObjectId;
|
|
32
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, CourseModel, Document<unknown, {}, CourseModel
|
|
32
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, CourseModel, Document<unknown, {}, import("mongoose").FlatRecord<CourseModel>> & import("mongoose").FlatRecord<CourseModel> & {
|
|
33
33
|
_id: import("mongoose").Types.ObjectId;
|
|
34
34
|
}>;
|
|
35
35
|
declare class DocModel extends Document {
|
|
@@ -38,7 +38,7 @@ declare class DocModel extends Document {
|
|
|
38
38
|
}
|
|
39
39
|
declare const DocSchema: import("mongoose").Schema<DocModel, import("mongoose").Model<DocModel, any, any, any, Document<unknown, any, DocModel> & DocModel & {
|
|
40
40
|
_id: import("mongoose").Types.ObjectId;
|
|
41
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DocModel, Document<unknown, {}, DocModel
|
|
41
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DocModel, Document<unknown, {}, import("mongoose").FlatRecord<DocModel>> & import("mongoose").FlatRecord<DocModel> & {
|
|
42
42
|
_id: import("mongoose").Types.ObjectId;
|
|
43
43
|
}>;
|
|
44
44
|
declare class ThreadModel extends Document {
|
|
@@ -47,7 +47,7 @@ declare class ThreadModel extends Document {
|
|
|
47
47
|
}
|
|
48
48
|
declare const ThreadSchema: import("mongoose").Schema<ThreadModel, import("mongoose").Model<ThreadModel, any, any, any, Document<unknown, any, ThreadModel> & ThreadModel & {
|
|
49
49
|
_id: import("mongoose").Types.ObjectId;
|
|
50
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, ThreadModel, Document<unknown, {}, ThreadModel
|
|
50
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, ThreadModel, Document<unknown, {}, import("mongoose").FlatRecord<ThreadModel>> & import("mongoose").FlatRecord<ThreadModel> & {
|
|
51
51
|
_id: import("mongoose").Types.ObjectId;
|
|
52
52
|
}>;
|
|
53
53
|
declare const HackschoolDB = "hub-hackschool";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-newsroom.schemas.d.ts
RENAMED
|
@@ -31,7 +31,7 @@ declare class NewsModel extends Document {
|
|
|
31
31
|
}
|
|
32
32
|
declare const NewsSchema: import("mongoose").Schema<NewsModel, import("mongoose").Model<NewsModel, any, any, any, Document<unknown, any, NewsModel> & NewsModel & {
|
|
33
33
|
_id: import("mongoose").Types.ObjectId;
|
|
34
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, NewsModel, Document<unknown, {}, NewsModel
|
|
34
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, NewsModel, Document<unknown, {}, import("mongoose").FlatRecord<NewsModel>> & import("mongoose").FlatRecord<NewsModel> & {
|
|
35
35
|
_id: import("mongoose").Types.ObjectId;
|
|
36
36
|
}>;
|
|
37
37
|
declare const NewsroomDB = "hub-newsroom";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-podcasts.schemas.d.ts
RENAMED
|
@@ -29,7 +29,7 @@ declare class PodcastModel extends Document {
|
|
|
29
29
|
}
|
|
30
30
|
declare const PodcastSchema: import("mongoose").Schema<PodcastModel, import("mongoose").Model<PodcastModel, any, any, any, Document<unknown, any, PodcastModel> & PodcastModel & {
|
|
31
31
|
_id: import("mongoose").Types.ObjectId;
|
|
32
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, PodcastModel, Document<unknown, {}, PodcastModel
|
|
32
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, PodcastModel, Document<unknown, {}, import("mongoose").FlatRecord<PodcastModel>> & import("mongoose").FlatRecord<PodcastModel> & {
|
|
33
33
|
_id: import("mongoose").Types.ObjectId;
|
|
34
34
|
}>;
|
|
35
35
|
declare const PodcastsDB = "hub-podcasts";
|
|
@@ -29,7 +29,7 @@ declare class MemberModel extends Document {
|
|
|
29
29
|
}
|
|
30
30
|
declare const MemberSchema: import("mongoose").Schema<MemberModel, import("mongoose").Model<MemberModel, any, any, any, Document<unknown, any, MemberModel> & MemberModel & {
|
|
31
31
|
_id: import("mongoose").Types.ObjectId;
|
|
32
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, MemberModel, Document<unknown, {}, MemberModel
|
|
32
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, MemberModel, Document<unknown, {}, import("mongoose").FlatRecord<MemberModel>> & import("mongoose").FlatRecord<MemberModel> & {
|
|
33
33
|
_id: import("mongoose").Types.ObjectId;
|
|
34
34
|
}>;
|
|
35
35
|
declare const TeamDB = "hub-team";
|
package/dist/{model-schemas → modules/database/model-service/schemas}/hub-tech-radar.schemas.d.ts
RENAMED
|
@@ -29,7 +29,7 @@ declare class BlipModel extends Document {
|
|
|
29
29
|
}
|
|
30
30
|
declare const BlipSchema: import("mongoose").Schema<BlipModel, import("mongoose").Model<BlipModel, any, any, any, Document<unknown, any, BlipModel> & BlipModel & {
|
|
31
31
|
_id: import("mongoose").Types.ObjectId;
|
|
32
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, BlipModel, Document<unknown, {}, BlipModel
|
|
32
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, BlipModel, Document<unknown, {}, import("mongoose").FlatRecord<BlipModel>> & import("mongoose").FlatRecord<BlipModel> & {
|
|
33
33
|
_id: import("mongoose").Types.ObjectId;
|
|
34
34
|
}>;
|
|
35
35
|
declare class RadarModel extends Document {
|
|
@@ -39,7 +39,7 @@ declare class RadarModel extends Document {
|
|
|
39
39
|
}
|
|
40
40
|
declare const RadarSchema: import("mongoose").Schema<RadarModel, import("mongoose").Model<RadarModel, any, any, any, Document<unknown, any, RadarModel> & RadarModel & {
|
|
41
41
|
_id: import("mongoose").Types.ObjectId;
|
|
42
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, RadarModel, Document<unknown, {}, RadarModel
|
|
42
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, RadarModel, Document<unknown, {}, import("mongoose").FlatRecord<RadarModel>> & import("mongoose").FlatRecord<RadarModel> & {
|
|
43
43
|
_id: import("mongoose").Types.ObjectId;
|
|
44
44
|
}>;
|
|
45
45
|
declare const TechRadarDB = "hub-tech-radar";
|
|
@@ -11,7 +11,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.PopulateService = void 0;
|
|
13
13
|
const common_1 = require("@nestjs/common");
|
|
14
|
-
const
|
|
14
|
+
const model_service_1 = require("../model-service/model.service");
|
|
15
15
|
let PopulateService = class PopulateService {
|
|
16
16
|
constructor(modelService) {
|
|
17
17
|
this.modelService = modelService;
|
|
@@ -56,6 +56,6 @@ let PopulateService = class PopulateService {
|
|
|
56
56
|
};
|
|
57
57
|
PopulateService = __decorate([
|
|
58
58
|
(0, common_1.Injectable)(),
|
|
59
|
-
__metadata("design:paramtypes", [
|
|
59
|
+
__metadata("design:paramtypes", [model_service_1.ModelService])
|
|
60
60
|
], PopulateService);
|
|
61
61
|
exports.PopulateService = PopulateService;
|
package/dist/{services → modules/database/service-mapper-service}/service-mapper.service.d.ts
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PopulateOptions } from 'mongoose';
|
|
2
|
-
import { ModelService } from '
|
|
2
|
+
import { ModelService } from '../model-service/model.service';
|
|
3
3
|
export declare class ServiceMapperService {
|
|
4
4
|
private readonly modelService;
|
|
5
5
|
constructor(modelService: ModelService);
|
|
@@ -11,7 +11,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.ServiceMapperService = void 0;
|
|
13
13
|
const common_1 = require("@nestjs/common");
|
|
14
|
-
const model_service_1 = require("
|
|
14
|
+
const model_service_1 = require("../model-service/model.service");
|
|
15
15
|
let ServiceMapperService = class ServiceMapperService {
|
|
16
16
|
constructor(modelService) {
|
|
17
17
|
this.modelService = modelService;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./authentication"), exports);
|
|
18
|
+
__exportStar(require("./database"), exports);
|
|
19
|
+
__exportStar(require("./services"), exports);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import { ConfigService } from '@nestjs/config';
|
|
1
2
|
import { AccountInformation } from 'itlab-functions';
|
|
2
|
-
import { ITLabModuleOptions } from '../itlab.interfaces';
|
|
3
3
|
export declare class AccountService {
|
|
4
|
-
private readonly
|
|
5
|
-
constructor(
|
|
4
|
+
private readonly configService;
|
|
5
|
+
constructor(configService: ConfigService);
|
|
6
6
|
private axios;
|
|
7
7
|
get(accountId: string): Promise<AccountInformation>;
|
|
8
8
|
}
|
|
@@ -8,9 +8,6 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
8
8
|
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
|
-
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
12
|
-
return function (target, key) { decorator(target, key, paramIndex); }
|
|
13
|
-
};
|
|
14
11
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
15
12
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
16
13
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -20,21 +17,18 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
20
17
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
18
|
});
|
|
22
19
|
};
|
|
23
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
24
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
25
|
-
};
|
|
26
20
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27
21
|
exports.AccountService = void 0;
|
|
28
22
|
const common_1 = require("@nestjs/common");
|
|
29
|
-
const
|
|
30
|
-
const
|
|
31
|
-
const
|
|
23
|
+
const config_1 = require("@nestjs/config");
|
|
24
|
+
const env_1 = require("../../../env");
|
|
25
|
+
const services_module_utils_1 = require("../services.module-utils");
|
|
32
26
|
let AccountService = class AccountService {
|
|
33
|
-
constructor(
|
|
34
|
-
this.
|
|
35
|
-
this.axios =
|
|
36
|
-
|
|
37
|
-
|
|
27
|
+
constructor(configService) {
|
|
28
|
+
this.configService = configService;
|
|
29
|
+
this.axios = (0, services_module_utils_1.createAxios)({
|
|
30
|
+
baseUrl: 'https://services.svi-itlab.com/account/internal/',
|
|
31
|
+
k8sToken: this.configService.getOrThrow(env_1.ENV_K8S_TOKEN),
|
|
38
32
|
});
|
|
39
33
|
}
|
|
40
34
|
get(accountId) {
|
|
@@ -49,7 +43,7 @@ let AccountService = class AccountService {
|
|
|
49
43
|
}
|
|
50
44
|
};
|
|
51
45
|
AccountService = __decorate([
|
|
52
|
-
|
|
53
|
-
__metadata("design:paramtypes", [
|
|
46
|
+
(0, common_1.Injectable)(),
|
|
47
|
+
__metadata("design:paramtypes", [config_1.ConfigService])
|
|
54
48
|
], AccountService);
|
|
55
49
|
exports.AccountService = AccountService;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.Comment = void 0;
|
|
13
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
14
|
+
class Comment {
|
|
15
|
+
}
|
|
16
|
+
__decorate([
|
|
17
|
+
(0, swagger_1.ApiProperty)(),
|
|
18
|
+
__metadata("design:type", String)
|
|
19
|
+
], Comment.prototype, "authorId", void 0);
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, swagger_1.ApiProperty)(),
|
|
22
|
+
__metadata("design:type", Number)
|
|
23
|
+
], Comment.prototype, "timestamp", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, swagger_1.ApiProperty)(),
|
|
26
|
+
__metadata("design:type", String)
|
|
27
|
+
], Comment.prototype, "richtext", void 0);
|
|
28
|
+
exports.Comment = Comment;
|
|
@@ -1,16 +1,12 @@
|
|
|
1
|
+
import { ConfigService } from '@nestjs/config';
|
|
1
2
|
import { ContentRichtext } from 'itlab-functions';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
export declare class Comment {
|
|
5
|
-
authorId: string;
|
|
6
|
-
timestamp: number;
|
|
7
|
-
richtext: string;
|
|
8
|
-
}
|
|
3
|
+
import { Targets } from '../../../pipes';
|
|
4
|
+
import { Comment } from './comment-service.definitions';
|
|
9
5
|
export declare class CommentService {
|
|
10
|
-
private readonly
|
|
11
|
-
constructor(options: ITLabModuleOptions);
|
|
12
|
-
private axios;
|
|
6
|
+
private readonly configService;
|
|
13
7
|
private logger;
|
|
8
|
+
constructor(configService: ConfigService);
|
|
9
|
+
private axios;
|
|
14
10
|
post(targetId: string, authorId: string, comment: ContentRichtext, target: Targets): Promise<Comment>;
|
|
15
11
|
delete(targetId: string, target: Targets): Promise<void>;
|
|
16
12
|
}
|
|
@@ -8,9 +8,6 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
8
8
|
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
|
-
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
12
|
-
return function (target, key) { decorator(target, key, paramIndex); }
|
|
13
|
-
};
|
|
14
11
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
15
12
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
16
13
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -20,39 +17,21 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
20
17
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
18
|
});
|
|
22
19
|
};
|
|
23
|
-
var
|
|
24
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
25
|
-
};
|
|
20
|
+
var CommentService_1;
|
|
26
21
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27
|
-
exports.CommentService =
|
|
22
|
+
exports.CommentService = void 0;
|
|
28
23
|
const common_1 = require("@nestjs/common");
|
|
29
|
-
const
|
|
30
|
-
const
|
|
31
|
-
const
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
__decorate([
|
|
40
|
-
(0, swagger_1.ApiProperty)(),
|
|
41
|
-
__metadata("design:type", Number)
|
|
42
|
-
], Comment.prototype, "timestamp", void 0);
|
|
43
|
-
__decorate([
|
|
44
|
-
(0, swagger_1.ApiProperty)(),
|
|
45
|
-
__metadata("design:type", String)
|
|
46
|
-
], Comment.prototype, "richtext", void 0);
|
|
47
|
-
exports.Comment = Comment;
|
|
48
|
-
let CommentService = class CommentService {
|
|
49
|
-
constructor(options) {
|
|
50
|
-
this.options = options;
|
|
51
|
-
this.axios = axios_1.default.create({
|
|
52
|
-
baseURL: 'https://services.svi-itlab.com/comment/internal/',
|
|
53
|
-
headers: { [guards_1.INTERNAL_HEADER_KEY]: this.options.token },
|
|
24
|
+
const config_1 = require("@nestjs/config");
|
|
25
|
+
const env_1 = require("../../../env");
|
|
26
|
+
const services_module_utils_1 = require("../services.module-utils");
|
|
27
|
+
let CommentService = CommentService_1 = class CommentService {
|
|
28
|
+
constructor(configService) {
|
|
29
|
+
this.configService = configService;
|
|
30
|
+
this.logger = new common_1.Logger(CommentService_1.name);
|
|
31
|
+
this.axios = (0, services_module_utils_1.createAxios)({
|
|
32
|
+
baseUrl: 'https://services.svi-itlab.com/comment/internal/',
|
|
33
|
+
k8sToken: this.configService.getOrThrow(env_1.ENV_K8S_TOKEN),
|
|
54
34
|
});
|
|
55
|
-
this.logger = new common_1.Logger(CommentService.name);
|
|
56
35
|
}
|
|
57
36
|
post(targetId, authorId, comment, target) {
|
|
58
37
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -89,8 +68,8 @@ let CommentService = class CommentService {
|
|
|
89
68
|
});
|
|
90
69
|
}
|
|
91
70
|
};
|
|
92
|
-
CommentService = __decorate([
|
|
93
|
-
|
|
94
|
-
__metadata("design:paramtypes", [
|
|
71
|
+
CommentService = CommentService_1 = __decorate([
|
|
72
|
+
(0, common_1.Injectable)(),
|
|
73
|
+
__metadata("design:paramtypes", [config_1.ConfigService])
|
|
95
74
|
], CommentService);
|
|
96
75
|
exports.CommentService = CommentService;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
+
import { ConfigService } from '@nestjs/config';
|
|
1
2
|
import { Content } from 'itlab-functions';
|
|
2
|
-
import {
|
|
3
|
-
import { Targets } from '../pipes/target.pipe';
|
|
3
|
+
import { Targets } from '../../../pipes';
|
|
4
4
|
export declare class ContentService {
|
|
5
|
-
private readonly
|
|
6
|
-
constructor(options: ITLabModuleOptions);
|
|
7
|
-
private axios;
|
|
5
|
+
private readonly configService;
|
|
8
6
|
private logger;
|
|
7
|
+
constructor(configService: ConfigService);
|
|
8
|
+
private axios;
|
|
9
9
|
verify(content: Content): Promise<void>;
|
|
10
10
|
post(targetId: string, content: Content, target: Targets): Promise<string>;
|
|
11
11
|
delete(targetId: string, target: Targets): Promise<void>;
|