@floristcloud/api-lib 1.2.23 → 1.2.24
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/build/commands/integration/moysklad/execute-moysklad-import.command.js +1 -0
- package/build/commands/integration/moysklad/scan-moysklad-import.query.js +4 -0
- package/build/constant/error.js +5 -0
- package/commands/integration/moysklad/execute-moysklad-import.command.ts +1 -0
- package/commands/integration/moysklad/scan-moysklad-import.query.ts +4 -0
- package/constant/error.ts +5 -0
- package/package.json +1 -1
|
@@ -21,6 +21,7 @@ const ExecutableItemSchema = zod_1.z.object({
|
|
|
21
21
|
status: zod_1.z.enum(['new', 'known']),
|
|
22
22
|
internalUUID: zod_1.z.string().nullable(),
|
|
23
23
|
resolvedCategoryUUID: zod_1.z.string().nullable(),
|
|
24
|
+
resolvedImageUUID: zod_1.z.string().nullable(),
|
|
24
25
|
});
|
|
25
26
|
const ExecuteMoyskladImportRequestSchema = zod_1.z.object({
|
|
26
27
|
items: zod_1.z.array(ExecutableItemSchema),
|
|
@@ -6,6 +6,8 @@ const enum_1 = require("../../../enum");
|
|
|
6
6
|
const ScannedItemSchema = zod_1.z.object({
|
|
7
7
|
externalSourceId: zod_1.z.string(),
|
|
8
8
|
externalHref: zod_1.z.string(),
|
|
9
|
+
originalName: zod_1.z.string(),
|
|
10
|
+
normalizedName: zod_1.z.string(),
|
|
9
11
|
name: zod_1.z.string(),
|
|
10
12
|
article: zod_1.z.string().nullable(),
|
|
11
13
|
barcode: zod_1.z.string().nullable(),
|
|
@@ -23,6 +25,7 @@ const ScannedItemSchema = zod_1.z.object({
|
|
|
23
25
|
internalUUID: zod_1.z.string().nullable(),
|
|
24
26
|
resolvedCategoryUUID: zod_1.z.string().nullable(),
|
|
25
27
|
resolvedCategoryName: zod_1.z.string().nullable(),
|
|
28
|
+
resolvedImageUUID: zod_1.z.string().nullable(),
|
|
26
29
|
});
|
|
27
30
|
const CategoryMatchSchema = zod_1.z.object({
|
|
28
31
|
fcCategoryUUID: zod_1.z.string(),
|
|
@@ -50,6 +53,7 @@ const ScanMoyskladImportResponseSchema = zod_1.z.object({
|
|
|
50
53
|
withCountry: zod_1.z.number(),
|
|
51
54
|
withGrower: zod_1.z.number(),
|
|
52
55
|
withSize: zod_1.z.number(),
|
|
56
|
+
withImage: zod_1.z.number(),
|
|
53
57
|
}),
|
|
54
58
|
items: zod_1.z.array(ScannedItemSchema),
|
|
55
59
|
}),
|
package/build/constant/error.js
CHANGED
|
@@ -994,4 +994,9 @@ exports.ERRORS = {
|
|
|
994
994
|
message: 'MoySklad clients import is already in progress for this company',
|
|
995
995
|
httpCode: 409,
|
|
996
996
|
},
|
|
997
|
+
MOYSKLAD_CATALOG_TOO_LARGE: {
|
|
998
|
+
code: 'MS010',
|
|
999
|
+
message: 'MoySklad catalog exceeds the import size limit; archive unused items in MoySklad first',
|
|
1000
|
+
httpCode: 413,
|
|
1001
|
+
},
|
|
997
1002
|
};
|
|
@@ -19,6 +19,7 @@ const ExecutableItemSchema = z.object({
|
|
|
19
19
|
status: z.enum(['new', 'known']),
|
|
20
20
|
internalUUID: z.string().nullable(),
|
|
21
21
|
resolvedCategoryUUID: z.string().nullable(),
|
|
22
|
+
resolvedImageUUID: z.string().nullable(),
|
|
22
23
|
});
|
|
23
24
|
|
|
24
25
|
const ExecuteMoyskladImportRequestSchema = z.object({
|
|
@@ -4,6 +4,8 @@ import { SalesUnitEnum } from '../../../enum';
|
|
|
4
4
|
const ScannedItemSchema = z.object({
|
|
5
5
|
externalSourceId: z.string(),
|
|
6
6
|
externalHref: z.string(),
|
|
7
|
+
originalName: z.string(),
|
|
8
|
+
normalizedName: z.string(),
|
|
7
9
|
name: z.string(),
|
|
8
10
|
article: z.string().nullable(),
|
|
9
11
|
barcode: z.string().nullable(),
|
|
@@ -21,6 +23,7 @@ const ScannedItemSchema = z.object({
|
|
|
21
23
|
internalUUID: z.string().nullable(),
|
|
22
24
|
resolvedCategoryUUID: z.string().nullable(),
|
|
23
25
|
resolvedCategoryName: z.string().nullable(),
|
|
26
|
+
resolvedImageUUID: z.string().nullable(),
|
|
24
27
|
});
|
|
25
28
|
|
|
26
29
|
const CategoryMatchSchema = z.object({
|
|
@@ -50,6 +53,7 @@ const ScanMoyskladImportResponseSchema = z.object({
|
|
|
50
53
|
withCountry: z.number(),
|
|
51
54
|
withGrower: z.number(),
|
|
52
55
|
withSize: z.number(),
|
|
56
|
+
withImage: z.number(),
|
|
53
57
|
}),
|
|
54
58
|
items: z.array(ScannedItemSchema),
|
|
55
59
|
}),
|
package/constant/error.ts
CHANGED
|
@@ -1054,4 +1054,9 @@ export const ERRORS = {
|
|
|
1054
1054
|
message: 'MoySklad clients import is already in progress for this company',
|
|
1055
1055
|
httpCode: 409,
|
|
1056
1056
|
},
|
|
1057
|
+
MOYSKLAD_CATALOG_TOO_LARGE: {
|
|
1058
|
+
code: 'MS010',
|
|
1059
|
+
message: 'MoySklad catalog exceeds the import size limit; archive unused items in MoySklad first',
|
|
1060
|
+
httpCode: 413,
|
|
1061
|
+
},
|
|
1057
1062
|
} as const;
|