@purpleschool/gptbot 0.8.10 → 0.8.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/api/controllers/http/community.ts +22 -0
- package/api/controllers/http/index.ts +1 -0
- package/api/routes.ts +26 -0
- package/build/api/controllers/http/community.js +23 -0
- package/build/api/controllers/http/index.js +1 -0
- package/build/api/routes.js +18 -0
- package/build/commands/community/archive-community-post.command.js +13 -0
- package/build/commands/community/create-community-post.command.js +35 -0
- package/build/commands/community/delete-community-post.command.js +13 -0
- package/build/commands/community/get-all-community-posts-by-criteria.command.js +25 -0
- package/build/commands/community/get-community-post-by-uuid.command.js +14 -0
- package/build/commands/community/get-my-community-posts-by-criteria.command.js +32 -0
- package/build/commands/community/get-my-favorite-community-posts.command.js +19 -0
- package/build/commands/community/get-my-likes-community-posts.command.js +19 -0
- package/build/commands/community/index.js +27 -0
- package/build/commands/community/set-favorite-community-post.command.js +13 -0
- package/build/commands/community/set-like-community-post.command.js +14 -0
- package/build/commands/community/share-my-community-post.command.js +13 -0
- package/build/commands/index.js +1 -0
- package/build/constants/community/default-pagination.constant.js +6 -0
- package/build/constants/community/enums/community-aspect-ratio.enum.js +11 -0
- package/build/constants/community/enums/community-post-visibility.enum.js +8 -0
- package/build/constants/community/enums/community-status.enum.js +9 -0
- package/build/constants/community/enums/community-tool-type.enum.js +10 -0
- package/build/constants/community/enums/community-type.enum.js +11 -0
- package/build/constants/community/enums/index.js +21 -0
- package/build/constants/community/index.js +18 -0
- package/build/constants/errors/errors.js +95 -0
- package/build/constants/index.js +1 -0
- package/build/models/community/community-post-media-data.schema.js +53 -0
- package/build/models/community/community-post.schema.js +43 -0
- package/build/models/community/index.js +18 -0
- package/build/models/index.js +1 -0
- package/build/models/tools/image-editor/image-editor-config.schema.js +1 -0
- package/commands/community/archive-community-post.command.ts +13 -0
- package/commands/community/create-community-post.command.ts +45 -0
- package/commands/community/delete-community-post.command.ts +13 -0
- package/commands/community/get-all-community-posts-by-criteria.command.ts +29 -0
- package/commands/community/get-community-post-by-uuid.command.ts +16 -0
- package/commands/community/get-my-community-posts-by-criteria.command.ts +40 -0
- package/commands/community/get-my-favorite-community-posts.command.ts +19 -0
- package/commands/community/get-my-likes-community-posts.command.ts +19 -0
- package/commands/community/index.ts +11 -0
- package/commands/community/set-favorite-community-post.command.ts +13 -0
- package/commands/community/set-like-community-post.command.ts +14 -0
- package/commands/community/share-my-community-post.command.ts +13 -0
- package/commands/index.ts +1 -0
- package/constants/community/default-pagination.constant.ts +4 -0
- package/constants/community/enums/community-aspect-ratio.enum.ts +7 -0
- package/constants/community/enums/community-post-visibility.enum.ts +4 -0
- package/constants/community/enums/community-status.enum.ts +5 -0
- package/constants/community/enums/community-tool-type.enum.ts +6 -0
- package/constants/community/enums/community-type.enum.ts +7 -0
- package/constants/community/enums/index.ts +5 -0
- package/constants/community/index.ts +2 -0
- package/constants/errors/errors.ts +95 -0
- package/constants/index.ts +1 -0
- package/models/community/community-post-media-data.schema.ts +65 -0
- package/models/community/community-post.schema.ts +47 -0
- package/models/community/index.ts +2 -0
- package/models/index.ts +1 -0
- package/models/tools/image-editor/image-editor-config.schema.ts +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export const COMMUNITY_CONTROLLER_PRIVATE = 'community/posts/private' as const;
|
|
2
|
+
export const COMMUNITY_CONTROLLER_PUBLIC = 'community/posts/public' as const;
|
|
3
|
+
|
|
4
|
+
export const COMMUNITY_ROUTES_PRIVATE = {
|
|
5
|
+
GET_ALL: '',
|
|
6
|
+
GET_MY: 'my',
|
|
7
|
+
GET_MY_LIKE: 'my/likes',
|
|
8
|
+
GET_MY_FAVORITE: 'my/favorites',
|
|
9
|
+
GET_BY_UUID: (uuid: string) => `by/uuid/${uuid}`,
|
|
10
|
+
GET_BY_USER_ID: (uuid: string) => `by/user/${uuid}`,
|
|
11
|
+
CREATE: '',
|
|
12
|
+
UPDATE: (uuid: string) => `${uuid}`,
|
|
13
|
+
DELETE: (uuid: string) => `${uuid}`,
|
|
14
|
+
ARCHIVE: (uuid: string) => `${uuid}/archive`,
|
|
15
|
+
LIKE: (uuid: string) => `${uuid}/like`,
|
|
16
|
+
FAVORITE: (uuid: string) => `${uuid}/favorite`,
|
|
17
|
+
} as const;
|
|
18
|
+
|
|
19
|
+
export const COMMUNITY_ROUTES_PUBLIC = {
|
|
20
|
+
GET_ALL: '',
|
|
21
|
+
GET_BY_UUID: (uuid: string) => `by/uuid/${uuid}`,
|
|
22
|
+
} as const;
|
package/api/routes.ts
CHANGED
|
@@ -796,6 +796,32 @@ export const REST_API = {
|
|
|
796
796
|
CLOUD_PAYMENTS: {
|
|
797
797
|
CALLBACK: `${ROOT}/${CONTROLLERS.CLOUD_PAYMENTS_CONTROLLER}/${CONTROLLERS.CLOUD_PAYMENTS_ROUTES.CALLBACK}`,
|
|
798
798
|
},
|
|
799
|
+
COMMUNITY_PRIVATE: {
|
|
800
|
+
GET_ALL: `${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_ALL}`,
|
|
801
|
+
GET_MY: `${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_MY}`,
|
|
802
|
+
GET_BY_UUID: (uuid: string) =>
|
|
803
|
+
`${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_BY_UUID(uuid)}`,
|
|
804
|
+
GET_BY_USER_ID: (uuid: string) =>
|
|
805
|
+
`${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_BY_USER_ID(uuid)}`,
|
|
806
|
+
CREATE: `${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.CREATE}`,
|
|
807
|
+
UPDATE: (uuid: string) =>
|
|
808
|
+
`${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.UPDATE(uuid)}`,
|
|
809
|
+
DELETE: (uuid: string) =>
|
|
810
|
+
`${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.DELETE(uuid)}`,
|
|
811
|
+
ARCHIVE: (uuid: string) =>
|
|
812
|
+
`${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.ARCHIVE(uuid)}`,
|
|
813
|
+
GET_MY_LIKE: `${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_MY_LIKE}`,
|
|
814
|
+
GET_MY_FAVORITE: `${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_MY_FAVORITE}`,
|
|
815
|
+
LIKE: (uuid: string) =>
|
|
816
|
+
`${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.LIKE(uuid)}`,
|
|
817
|
+
FAVORITE: (uuid: string) =>
|
|
818
|
+
`${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.FAVORITE(uuid)}`,
|
|
819
|
+
},
|
|
820
|
+
COMMUNITY_PUBLIC: {
|
|
821
|
+
GET_ALL: `${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PUBLIC}/${CONTROLLERS.COMMUNITY_ROUTES_PUBLIC.GET_ALL}`,
|
|
822
|
+
GET_BY_UUID: (uuid: string) =>
|
|
823
|
+
`${ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PUBLIC}/${CONTROLLERS.COMMUNITY_ROUTES_PUBLIC.GET_BY_UUID(uuid)}`,
|
|
824
|
+
},
|
|
799
825
|
USER_PROFILE: {
|
|
800
826
|
GET_PROFILE_INFO: `${ROOT}/${CONTROLLERS.USER_PROFILE_CONTROLLER}/${CONTROLLERS.USER_PROFILE_ROUTES.GET_PROFILE_INFO}`,
|
|
801
827
|
UPLOAD_AVATAR: `${ROOT}/${CONTROLLERS.USER_PROFILE_CONTROLLER}/${CONTROLLERS.USER_PROFILE_ROUTES.UPLOAD_AVATAR}`,
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.COMMUNITY_ROUTES_PUBLIC = exports.COMMUNITY_ROUTES_PRIVATE = exports.COMMUNITY_CONTROLLER_PUBLIC = exports.COMMUNITY_CONTROLLER_PRIVATE = void 0;
|
|
4
|
+
exports.COMMUNITY_CONTROLLER_PRIVATE = 'community/posts/private';
|
|
5
|
+
exports.COMMUNITY_CONTROLLER_PUBLIC = 'community/posts/public';
|
|
6
|
+
exports.COMMUNITY_ROUTES_PRIVATE = {
|
|
7
|
+
GET_ALL: '',
|
|
8
|
+
GET_MY: 'my',
|
|
9
|
+
GET_MY_LIKE: 'my/likes',
|
|
10
|
+
GET_MY_FAVORITE: 'my/favorites',
|
|
11
|
+
GET_BY_UUID: (uuid) => `by/uuid/${uuid}`,
|
|
12
|
+
GET_BY_USER_ID: (uuid) => `by/user/${uuid}`,
|
|
13
|
+
CREATE: '',
|
|
14
|
+
UPDATE: (uuid) => `${uuid}`,
|
|
15
|
+
DELETE: (uuid) => `${uuid}`,
|
|
16
|
+
ARCHIVE: (uuid) => `${uuid}/archive`,
|
|
17
|
+
LIKE: (uuid) => `${uuid}/like`,
|
|
18
|
+
FAVORITE: (uuid) => `${uuid}/favorite`,
|
|
19
|
+
};
|
|
20
|
+
exports.COMMUNITY_ROUTES_PUBLIC = {
|
|
21
|
+
GET_ALL: '',
|
|
22
|
+
GET_BY_UUID: (uuid) => `by/uuid/${uuid}`,
|
|
23
|
+
};
|
|
@@ -69,4 +69,5 @@ __exportStar(require("./cabinet"), exports);
|
|
|
69
69
|
__exportStar(require("./webmaster"), exports);
|
|
70
70
|
__exportStar(require("./music"), exports);
|
|
71
71
|
__exportStar(require("./webmaster-click"), exports);
|
|
72
|
+
__exportStar(require("./community"), exports);
|
|
72
73
|
__exportStar(require("./user-profile"), exports);
|
package/build/api/routes.js
CHANGED
|
@@ -625,6 +625,24 @@ exports.REST_API = {
|
|
|
625
625
|
CLOUD_PAYMENTS: {
|
|
626
626
|
CALLBACK: `${exports.ROOT}/${CONTROLLERS.CLOUD_PAYMENTS_CONTROLLER}/${CONTROLLERS.CLOUD_PAYMENTS_ROUTES.CALLBACK}`,
|
|
627
627
|
},
|
|
628
|
+
COMMUNITY_PRIVATE: {
|
|
629
|
+
GET_ALL: `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_ALL}`,
|
|
630
|
+
GET_MY: `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_MY}`,
|
|
631
|
+
GET_BY_UUID: (uuid) => `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_BY_UUID(uuid)}`,
|
|
632
|
+
GET_BY_USER_ID: (uuid) => `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_BY_USER_ID(uuid)}`,
|
|
633
|
+
CREATE: `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.CREATE}`,
|
|
634
|
+
UPDATE: (uuid) => `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.UPDATE(uuid)}`,
|
|
635
|
+
DELETE: (uuid) => `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.DELETE(uuid)}`,
|
|
636
|
+
ARCHIVE: (uuid) => `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.ARCHIVE(uuid)}`,
|
|
637
|
+
GET_MY_LIKE: `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_MY_LIKE}`,
|
|
638
|
+
GET_MY_FAVORITE: `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.GET_MY_FAVORITE}`,
|
|
639
|
+
LIKE: (uuid) => `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.LIKE(uuid)}`,
|
|
640
|
+
FAVORITE: (uuid) => `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PRIVATE}/${CONTROLLERS.COMMUNITY_ROUTES_PRIVATE.FAVORITE(uuid)}`,
|
|
641
|
+
},
|
|
642
|
+
COMMUNITY_PUBLIC: {
|
|
643
|
+
GET_ALL: `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PUBLIC}/${CONTROLLERS.COMMUNITY_ROUTES_PUBLIC.GET_ALL}`,
|
|
644
|
+
GET_BY_UUID: (uuid) => `${exports.ROOT}/${CONTROLLERS.COMMUNITY_CONTROLLER_PUBLIC}/${CONTROLLERS.COMMUNITY_ROUTES_PUBLIC.GET_BY_UUID(uuid)}`,
|
|
645
|
+
},
|
|
628
646
|
USER_PROFILE: {
|
|
629
647
|
GET_PROFILE_INFO: `${exports.ROOT}/${CONTROLLERS.USER_PROFILE_CONTROLLER}/${CONTROLLERS.USER_PROFILE_ROUTES.GET_PROFILE_INFO}`,
|
|
630
648
|
UPLOAD_AVATAR: `${exports.ROOT}/${CONTROLLERS.USER_PROFILE_CONTROLLER}/${CONTROLLERS.USER_PROFILE_ROUTES.UPLOAD_AVATAR}`,
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ArchiveCommunityPostCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
var ArchiveCommunityPostCommand;
|
|
6
|
+
(function (ArchiveCommunityPostCommand) {
|
|
7
|
+
ArchiveCommunityPostCommand.RequestParamsSchema = zod_1.z.object({
|
|
8
|
+
uuid: zod_1.z.string().uuid(),
|
|
9
|
+
});
|
|
10
|
+
ArchiveCommunityPostCommand.ResponseSchema = zod_1.z.object({
|
|
11
|
+
data: zod_1.z.boolean(),
|
|
12
|
+
});
|
|
13
|
+
})(ArchiveCommunityPostCommand || (exports.ArchiveCommunityPostCommand = ArchiveCommunityPostCommand = {}));
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CreateCommunityPostCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const models_1 = require("../../models");
|
|
6
|
+
const constants_1 = require("../../constants");
|
|
7
|
+
var CreateCommunityPostCommand;
|
|
8
|
+
(function (CreateCommunityPostCommand) {
|
|
9
|
+
CreateCommunityPostCommand.RequestBodySchema = zod_1.z
|
|
10
|
+
.object({
|
|
11
|
+
status: zod_1.z.nativeEnum(constants_1.COMMUNITY_POST_STATUS),
|
|
12
|
+
visibility: zod_1.z.nativeEnum(constants_1.COMMUNITY_POST_VISIBILITY),
|
|
13
|
+
caption: zod_1.z.string().max(500).nullable().optional(),
|
|
14
|
+
messageId: zod_1.z.string().uuid().nullable().optional(),
|
|
15
|
+
toolJobId: zod_1.z.string().uuid().nullable().optional(),
|
|
16
|
+
toolType: zod_1.z.nativeEnum(constants_1.COMMUNITY_TOOL_TYPE).nullable().optional(),
|
|
17
|
+
})
|
|
18
|
+
.refine((data) => {
|
|
19
|
+
const hasMessageId = data.messageId != null;
|
|
20
|
+
const hasToolJobId = data.toolJobId != null;
|
|
21
|
+
if (!(hasMessageId !== hasToolJobId)) {
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
if (hasToolJobId && data.toolType == null) {
|
|
25
|
+
return false;
|
|
26
|
+
}
|
|
27
|
+
return true;
|
|
28
|
+
}, {
|
|
29
|
+
message: 'Either messageId or toolJobId must be provided, but not both.',
|
|
30
|
+
path: ['messageId'],
|
|
31
|
+
});
|
|
32
|
+
CreateCommunityPostCommand.ResponseSchema = zod_1.z.object({
|
|
33
|
+
data: models_1.ResponseCommunityPostSchema,
|
|
34
|
+
});
|
|
35
|
+
})(CreateCommunityPostCommand || (exports.CreateCommunityPostCommand = CreateCommunityPostCommand = {}));
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DeleteCommunityPostCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
var DeleteCommunityPostCommand;
|
|
6
|
+
(function (DeleteCommunityPostCommand) {
|
|
7
|
+
DeleteCommunityPostCommand.RequestParamsSchema = zod_1.z.object({
|
|
8
|
+
uuid: zod_1.z.string().uuid(),
|
|
9
|
+
});
|
|
10
|
+
DeleteCommunityPostCommand.ResponseSchema = zod_1.z.object({
|
|
11
|
+
data: zod_1.z.boolean(),
|
|
12
|
+
});
|
|
13
|
+
})(DeleteCommunityPostCommand || (exports.DeleteCommunityPostCommand = DeleteCommunityPostCommand = {}));
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetAllCommunityPostsCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const models_1 = require("../../models");
|
|
6
|
+
const constants_1 = require("../../constants");
|
|
7
|
+
var GetAllCommunityPostsCommand;
|
|
8
|
+
(function (GetAllCommunityPostsCommand) {
|
|
9
|
+
GetAllCommunityPostsCommand.RequestQuerySchema = zod_1.z.object({
|
|
10
|
+
// Pagination
|
|
11
|
+
cursor: zod_1.z.string().uuid().nullable().optional(),
|
|
12
|
+
limit: zod_1.z.coerce.number().int().positive().max(100).default(30).optional(),
|
|
13
|
+
// Sorting
|
|
14
|
+
sortBy: zod_1.z.enum(['publishedAt', 'views', 'likesCount']).optional(),
|
|
15
|
+
sortOrder: zod_1.z.nativeEnum(constants_1.SORT_ORDER).optional(),
|
|
16
|
+
// Criteria
|
|
17
|
+
userId: zod_1.z.string().uuid().optional(),
|
|
18
|
+
type: zod_1.z.nativeEnum(constants_1.COMMUNITY_POST_TYPE).optional(),
|
|
19
|
+
});
|
|
20
|
+
GetAllCommunityPostsCommand.ResponseSchema = zod_1.z.object({
|
|
21
|
+
data: zod_1.z.array(models_1.ResponseCommunityPostSchema),
|
|
22
|
+
cursor: zod_1.z.string().uuid().nullable(),
|
|
23
|
+
hasNext: zod_1.z.boolean(),
|
|
24
|
+
});
|
|
25
|
+
})(GetAllCommunityPostsCommand || (exports.GetAllCommunityPostsCommand = GetAllCommunityPostsCommand = {}));
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetCommunityPostByUuidCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const models_1 = require("../../models");
|
|
6
|
+
var GetCommunityPostByUuidCommand;
|
|
7
|
+
(function (GetCommunityPostByUuidCommand) {
|
|
8
|
+
GetCommunityPostByUuidCommand.RequestSchema = zod_1.z.object({
|
|
9
|
+
uuid: zod_1.z.string().uuid(),
|
|
10
|
+
});
|
|
11
|
+
GetCommunityPostByUuidCommand.ResponseSchema = zod_1.z.object({
|
|
12
|
+
data: models_1.ResponseCommunityPostSchema,
|
|
13
|
+
});
|
|
14
|
+
})(GetCommunityPostByUuidCommand || (exports.GetCommunityPostByUuidCommand = GetCommunityPostByUuidCommand = {}));
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetMyCommunityPostsByCriteriaCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const models_1 = require("../../models");
|
|
6
|
+
const constants_1 = require("../../constants");
|
|
7
|
+
var GetMyCommunityPostsByCriteriaCommand;
|
|
8
|
+
(function (GetMyCommunityPostsByCriteriaCommand) {
|
|
9
|
+
GetMyCommunityPostsByCriteriaCommand.RequestQuerySchema = zod_1.z.object({
|
|
10
|
+
// Pagination
|
|
11
|
+
cursor: zod_1.z.string().uuid().nullable().optional(),
|
|
12
|
+
limit: zod_1.z.coerce
|
|
13
|
+
.number()
|
|
14
|
+
.int()
|
|
15
|
+
.positive()
|
|
16
|
+
.max(100)
|
|
17
|
+
.default(constants_1.DEFAULT_PAGINATION_LIMIT)
|
|
18
|
+
.optional(),
|
|
19
|
+
// Sorting
|
|
20
|
+
sortBy: zod_1.z.enum(['publishedAt', 'views', 'likesCount']).optional(),
|
|
21
|
+
sortOrder: zod_1.z.nativeEnum(constants_1.SORT_ORDER).optional(),
|
|
22
|
+
// Criteria
|
|
23
|
+
visibility: zod_1.z.nativeEnum(constants_1.COMMUNITY_POST_VISIBILITY).optional(),
|
|
24
|
+
type: zod_1.z.nativeEnum(constants_1.COMMUNITY_POST_TYPE).optional(),
|
|
25
|
+
status: zod_1.z.nativeEnum(constants_1.COMMUNITY_POST_STATUS).optional(),
|
|
26
|
+
});
|
|
27
|
+
GetMyCommunityPostsByCriteriaCommand.ResponseSchema = zod_1.z.object({
|
|
28
|
+
data: zod_1.z.array(models_1.ResponseCommunityPostSchema),
|
|
29
|
+
cursor: zod_1.z.string().uuid().nullable(),
|
|
30
|
+
hasNext: zod_1.z.boolean(),
|
|
31
|
+
});
|
|
32
|
+
})(GetMyCommunityPostsByCriteriaCommand || (exports.GetMyCommunityPostsByCriteriaCommand = GetMyCommunityPostsByCriteriaCommand = {}));
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetMyFavoriteCommunityPostsCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const constants_1 = require("../../constants");
|
|
6
|
+
const models_1 = require("../../models");
|
|
7
|
+
var GetMyFavoriteCommunityPostsCommand;
|
|
8
|
+
(function (GetMyFavoriteCommunityPostsCommand) {
|
|
9
|
+
GetMyFavoriteCommunityPostsCommand.RequestQuerySchema = zod_1.z.object({
|
|
10
|
+
offset: zod_1.z.coerce.number().int().min(0).default(0).optional(),
|
|
11
|
+
limit: zod_1.z.coerce.number().int().min(1).max(100).default(constants_1.DEFAULT_PAGINATION_LIMIT).optional(),
|
|
12
|
+
sortOrder: zod_1.z.nativeEnum(constants_1.SORT_ORDER).optional(),
|
|
13
|
+
});
|
|
14
|
+
GetMyFavoriteCommunityPostsCommand.ResponseSchema = zod_1.z.object({
|
|
15
|
+
data: zod_1.z.array(models_1.ResponseCommunityPostSchema),
|
|
16
|
+
page: zod_1.z.number(),
|
|
17
|
+
totalPages: zod_1.z.number(),
|
|
18
|
+
});
|
|
19
|
+
})(GetMyFavoriteCommunityPostsCommand || (exports.GetMyFavoriteCommunityPostsCommand = GetMyFavoriteCommunityPostsCommand = {}));
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetMyLikesCommunityPostsCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const constants_1 = require("../../constants");
|
|
6
|
+
const models_1 = require("../../models");
|
|
7
|
+
var GetMyLikesCommunityPostsCommand;
|
|
8
|
+
(function (GetMyLikesCommunityPostsCommand) {
|
|
9
|
+
GetMyLikesCommunityPostsCommand.RequestQuerySchema = zod_1.z.object({
|
|
10
|
+
offset: zod_1.z.coerce.number().int().min(0).default(0).optional(),
|
|
11
|
+
limit: zod_1.z.coerce.number().int().min(1).max(100).default(constants_1.DEFAULT_PAGINATION_LIMIT).optional(),
|
|
12
|
+
sortOrder: zod_1.z.nativeEnum(constants_1.SORT_ORDER).optional(),
|
|
13
|
+
});
|
|
14
|
+
GetMyLikesCommunityPostsCommand.ResponseSchema = zod_1.z.object({
|
|
15
|
+
data: zod_1.z.array(models_1.ResponseCommunityPostSchema),
|
|
16
|
+
page: zod_1.z.number(),
|
|
17
|
+
totalPages: zod_1.z.number(),
|
|
18
|
+
});
|
|
19
|
+
})(GetMyLikesCommunityPostsCommand || (exports.GetMyLikesCommunityPostsCommand = GetMyLikesCommunityPostsCommand = {}));
|
|
@@ -0,0 +1,27 @@
|
|
|
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("./get-all-community-posts-by-criteria.command"), exports);
|
|
18
|
+
__exportStar(require("./get-community-post-by-uuid.command"), exports);
|
|
19
|
+
__exportStar(require("./create-community-post.command"), exports);
|
|
20
|
+
__exportStar(require("./set-like-community-post.command"), exports);
|
|
21
|
+
__exportStar(require("./set-favorite-community-post.command"), exports);
|
|
22
|
+
__exportStar(require("./delete-community-post.command"), exports);
|
|
23
|
+
__exportStar(require("./archive-community-post.command"), exports);
|
|
24
|
+
__exportStar(require("./get-my-community-posts-by-criteria.command"), exports);
|
|
25
|
+
__exportStar(require("./share-my-community-post.command"), exports);
|
|
26
|
+
__exportStar(require("./get-my-likes-community-posts.command"), exports);
|
|
27
|
+
__exportStar(require("./get-my-favorite-community-posts.command"), exports);
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SetFavoriteCommunityPostCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
var SetFavoriteCommunityPostCommand;
|
|
6
|
+
(function (SetFavoriteCommunityPostCommand) {
|
|
7
|
+
SetFavoriteCommunityPostCommand.RequestParamsSchema = zod_1.z.object({
|
|
8
|
+
uuid: zod_1.z.string().uuid(),
|
|
9
|
+
});
|
|
10
|
+
SetFavoriteCommunityPostCommand.ResponseSchema = zod_1.z.object({
|
|
11
|
+
data: zod_1.z.boolean(),
|
|
12
|
+
});
|
|
13
|
+
})(SetFavoriteCommunityPostCommand || (exports.SetFavoriteCommunityPostCommand = SetFavoriteCommunityPostCommand = {}));
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SetLikeCommunityPostCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const models_1 = require("../../models");
|
|
6
|
+
var SetLikeCommunityPostCommand;
|
|
7
|
+
(function (SetLikeCommunityPostCommand) {
|
|
8
|
+
SetLikeCommunityPostCommand.RequestParamsSchema = zod_1.z.object({
|
|
9
|
+
uuid: zod_1.z.string().uuid(),
|
|
10
|
+
});
|
|
11
|
+
SetLikeCommunityPostCommand.ResponseSchema = zod_1.z.object({
|
|
12
|
+
data: models_1.ResponseCommunityPostSchema,
|
|
13
|
+
});
|
|
14
|
+
})(SetLikeCommunityPostCommand || (exports.SetLikeCommunityPostCommand = SetLikeCommunityPostCommand = {}));
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ShareMyCommunityPostCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
var ShareMyCommunityPostCommand;
|
|
6
|
+
(function (ShareMyCommunityPostCommand) {
|
|
7
|
+
ShareMyCommunityPostCommand.RequestParamsSchema = zod_1.z.object({
|
|
8
|
+
uuid: zod_1.z.string().uuid(),
|
|
9
|
+
});
|
|
10
|
+
ShareMyCommunityPostCommand.ResponseSchema = zod_1.z.object({
|
|
11
|
+
data: zod_1.z.string().url(),
|
|
12
|
+
});
|
|
13
|
+
})(ShareMyCommunityPostCommand || (exports.ShareMyCommunityPostCommand = ShareMyCommunityPostCommand = {}));
|
package/build/commands/index.js
CHANGED
|
@@ -55,4 +55,5 @@ __exportStar(require("./daily-streak"), exports);
|
|
|
55
55
|
__exportStar(require("./cabinet"), exports);
|
|
56
56
|
__exportStar(require("./webmaster"), exports);
|
|
57
57
|
__exportStar(require("./webmaster-click"), exports);
|
|
58
|
+
__exportStar(require("./community"), exports);
|
|
58
59
|
__exportStar(require("./user-profile"), exports);
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DEFAULT_PAGINATION_SORT_BY = exports.DEFAULT_PAGINATION_SORT_ORDER = exports.DEFAULT_PAGINATION_LIMIT = void 0;
|
|
4
|
+
exports.DEFAULT_PAGINATION_LIMIT = 30;
|
|
5
|
+
exports.DEFAULT_PAGINATION_SORT_ORDER = 'desc';
|
|
6
|
+
exports.DEFAULT_PAGINATION_SORT_BY = 'publishedAt';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.COMMUNITY_POST_ASPECT_RATIO = void 0;
|
|
4
|
+
var COMMUNITY_POST_ASPECT_RATIO;
|
|
5
|
+
(function (COMMUNITY_POST_ASPECT_RATIO) {
|
|
6
|
+
COMMUNITY_POST_ASPECT_RATIO["HORIZONTAL_16_9"] = "16:9";
|
|
7
|
+
COMMUNITY_POST_ASPECT_RATIO["VERTICAL_9_16"] = "9:16";
|
|
8
|
+
COMMUNITY_POST_ASPECT_RATIO["SQUARE"] = "1:1";
|
|
9
|
+
COMMUNITY_POST_ASPECT_RATIO["HORIZONTAL_4_3"] = "4:3";
|
|
10
|
+
COMMUNITY_POST_ASPECT_RATIO["VERTICAL_3_4"] = "3:4";
|
|
11
|
+
})(COMMUNITY_POST_ASPECT_RATIO || (exports.COMMUNITY_POST_ASPECT_RATIO = COMMUNITY_POST_ASPECT_RATIO = {}));
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.COMMUNITY_POST_VISIBILITY = void 0;
|
|
4
|
+
var COMMUNITY_POST_VISIBILITY;
|
|
5
|
+
(function (COMMUNITY_POST_VISIBILITY) {
|
|
6
|
+
COMMUNITY_POST_VISIBILITY["PUBLIC"] = "public";
|
|
7
|
+
COMMUNITY_POST_VISIBILITY["UNLISTED"] = "unlisted";
|
|
8
|
+
})(COMMUNITY_POST_VISIBILITY || (exports.COMMUNITY_POST_VISIBILITY = COMMUNITY_POST_VISIBILITY = {}));
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.COMMUNITY_POST_STATUS = void 0;
|
|
4
|
+
var COMMUNITY_POST_STATUS;
|
|
5
|
+
(function (COMMUNITY_POST_STATUS) {
|
|
6
|
+
COMMUNITY_POST_STATUS["PUBLISHED"] = "published";
|
|
7
|
+
COMMUNITY_POST_STATUS["ARCHIVED"] = "archived";
|
|
8
|
+
COMMUNITY_POST_STATUS["DELETED"] = "deleted";
|
|
9
|
+
})(COMMUNITY_POST_STATUS || (exports.COMMUNITY_POST_STATUS = COMMUNITY_POST_STATUS = {}));
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.COMMUNITY_TOOL_TYPE = void 0;
|
|
4
|
+
var COMMUNITY_TOOL_TYPE;
|
|
5
|
+
(function (COMMUNITY_TOOL_TYPE) {
|
|
6
|
+
COMMUNITY_TOOL_TYPE["IMAGE_EDITOR"] = "image_editor";
|
|
7
|
+
COMMUNITY_TOOL_TYPE["VIDEO"] = "video";
|
|
8
|
+
COMMUNITY_TOOL_TYPE["VIDEO_EDITOR"] = "video_editor";
|
|
9
|
+
COMMUNITY_TOOL_TYPE["MUSIC"] = "music";
|
|
10
|
+
})(COMMUNITY_TOOL_TYPE || (exports.COMMUNITY_TOOL_TYPE = COMMUNITY_TOOL_TYPE = {}));
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.COMMUNITY_POST_TYPE = void 0;
|
|
4
|
+
var COMMUNITY_POST_TYPE;
|
|
5
|
+
(function (COMMUNITY_POST_TYPE) {
|
|
6
|
+
COMMUNITY_POST_TYPE["IMAGE"] = "image";
|
|
7
|
+
COMMUNITY_POST_TYPE["IMAGE_EDITOR"] = "image_editor";
|
|
8
|
+
COMMUNITY_POST_TYPE["VIDEO"] = "video";
|
|
9
|
+
COMMUNITY_POST_TYPE["VIDEO_EDITOR"] = "video_editor";
|
|
10
|
+
COMMUNITY_POST_TYPE["MUSIC"] = "music";
|
|
11
|
+
})(COMMUNITY_POST_TYPE || (exports.COMMUNITY_POST_TYPE = COMMUNITY_POST_TYPE = {}));
|
|
@@ -0,0 +1,21 @@
|
|
|
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("./community-status.enum"), exports);
|
|
18
|
+
__exportStar(require("./community-type.enum"), exports);
|
|
19
|
+
__exportStar(require("./community-aspect-ratio.enum"), exports);
|
|
20
|
+
__exportStar(require("./community-tool-type.enum"), exports);
|
|
21
|
+
__exportStar(require("./community-post-visibility.enum"), exports);
|
|
@@ -0,0 +1,18 @@
|
|
|
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("./enums"), exports);
|
|
18
|
+
__exportStar(require("./default-pagination.constant"), exports);
|
|
@@ -2367,4 +2367,99 @@ exports.ERRORS = {
|
|
|
2367
2367
|
message: 'Ошибка при обновлении профиля пользователя',
|
|
2368
2368
|
httpCode: 500,
|
|
2369
2369
|
},
|
|
2370
|
+
COMMUNITY_POST_CREATE_ERROR: {
|
|
2371
|
+
code: 'A484',
|
|
2372
|
+
message: 'Произошла ошибка при создании поста в сообществе',
|
|
2373
|
+
httpCode: 500,
|
|
2374
|
+
},
|
|
2375
|
+
COMMUNITY_POST_UPDATE_ERROR: {
|
|
2376
|
+
code: 'A485',
|
|
2377
|
+
message: 'Произошла ошибка при обновлении поста в сообществе',
|
|
2378
|
+
httpCode: 500,
|
|
2379
|
+
},
|
|
2380
|
+
COMMUNITY_POST_FIND_ERROR: {
|
|
2381
|
+
code: 'A486',
|
|
2382
|
+
message: 'Произошла ошибка при получении поста в сообществе',
|
|
2383
|
+
httpCode: 500,
|
|
2384
|
+
},
|
|
2385
|
+
COMMUNITY_POST_SET_LIKE_ERROR: {
|
|
2386
|
+
code: 'A487',
|
|
2387
|
+
message: 'Произошла ошибка при установке лайка к посту в сообществе',
|
|
2388
|
+
httpCode: 500,
|
|
2389
|
+
},
|
|
2390
|
+
COMMUNITY_POST_SET_FAVORITE_ERROR: {
|
|
2391
|
+
code: 'A488',
|
|
2392
|
+
message: 'Произошла ошибка при переключении избранного поста в сообществе',
|
|
2393
|
+
httpCode: 500,
|
|
2394
|
+
},
|
|
2395
|
+
COMMUNITY_POST_OWNERSHIP_ERROR: {
|
|
2396
|
+
code: 'A489',
|
|
2397
|
+
message: 'Вы не можете переключать избранное для своего поста',
|
|
2398
|
+
httpCode: 403,
|
|
2399
|
+
},
|
|
2400
|
+
COMMUNITY_POST_PERMISSION_ERROR: {
|
|
2401
|
+
code: 'A490',
|
|
2402
|
+
message: 'У вас нет доступа к этому посту в сообществе',
|
|
2403
|
+
httpCode: 403,
|
|
2404
|
+
},
|
|
2405
|
+
COMMUNITY_POST_DELETE_ERROR: {
|
|
2406
|
+
code: 'A491',
|
|
2407
|
+
message: 'Произошла ошибка при удалении поста в сообществе',
|
|
2408
|
+
httpCode: 500,
|
|
2409
|
+
},
|
|
2410
|
+
COMMUNITY_TOOL_TYPE_REQUIRED: {
|
|
2411
|
+
code: 'A492',
|
|
2412
|
+
message: 'Тип инструмента обязателен',
|
|
2413
|
+
httpCode: 400,
|
|
2414
|
+
},
|
|
2415
|
+
COMMUNITY_TOOL_TYPE_NOT_SUPPORTED: {
|
|
2416
|
+
code: 'A493',
|
|
2417
|
+
message: 'Неподдерживаемый тип инструмента',
|
|
2418
|
+
httpCode: 400,
|
|
2419
|
+
},
|
|
2420
|
+
VIDEO_MODEL_FIND_ERROR: {
|
|
2421
|
+
code: 'A494',
|
|
2422
|
+
message: 'Произошла ошибка при получении модели для генерации видео',
|
|
2423
|
+
httpCode: 500,
|
|
2424
|
+
},
|
|
2425
|
+
VIDEO_EDITOR_MODEL_FIND_ERROR: {
|
|
2426
|
+
code: 'A495',
|
|
2427
|
+
message: 'Произошла ошибка при получении модели для редактирования видео',
|
|
2428
|
+
httpCode: 500,
|
|
2429
|
+
},
|
|
2430
|
+
IMAGE_EDITOR_MODEL_FIND_ERROR: {
|
|
2431
|
+
code: 'A496',
|
|
2432
|
+
message: 'Произошла ошибка при получении модели для редактирования изображения',
|
|
2433
|
+
httpCode: 500,
|
|
2434
|
+
},
|
|
2435
|
+
MUSIC_MODEL_FIND_ERROR: {
|
|
2436
|
+
code: 'A497',
|
|
2437
|
+
message: 'Произошла ошибка при получении модели для генерации музыки',
|
|
2438
|
+
httpCode: 500,
|
|
2439
|
+
},
|
|
2440
|
+
COMMUNITY_POST_NOT_AVAILABLE: {
|
|
2441
|
+
code: 'A498',
|
|
2442
|
+
message: 'Пост в сообществе недоступен',
|
|
2443
|
+
httpCode: 400,
|
|
2444
|
+
},
|
|
2445
|
+
COMMUNITY_POST_NOT_FOUND: {
|
|
2446
|
+
code: 'A499',
|
|
2447
|
+
message: 'Пост в сообществе не найден',
|
|
2448
|
+
httpCode: 404,
|
|
2449
|
+
},
|
|
2450
|
+
COMMUNITY_POST_JOB_NOT_READY: {
|
|
2451
|
+
code: 'A500',
|
|
2452
|
+
message: 'Работа не готова к публикации',
|
|
2453
|
+
httpCode: 404,
|
|
2454
|
+
},
|
|
2455
|
+
MESSAGE_STATUS_ERROR: {
|
|
2456
|
+
code: 'A501',
|
|
2457
|
+
message: 'Статус неудовлетворительный',
|
|
2458
|
+
httpCode: 400,
|
|
2459
|
+
},
|
|
2460
|
+
MESSAGE_ROLE_ERROR: {
|
|
2461
|
+
code: 'A502',
|
|
2462
|
+
message: 'Статус не удовлетворительный',
|
|
2463
|
+
httpCode: 400,
|
|
2464
|
+
},
|
|
2370
2465
|
};
|
package/build/constants/index.js
CHANGED
|
@@ -56,4 +56,5 @@ __exportStar(require("./cabinet"), exports);
|
|
|
56
56
|
__exportStar(require("./webmaster"), exports);
|
|
57
57
|
__exportStar(require("./webmaster-balance"), exports);
|
|
58
58
|
__exportStar(require("./tool-music"), exports);
|
|
59
|
+
__exportStar(require("./community"), exports);
|
|
59
60
|
__exportStar(require("./user-profile"), exports);
|