@sales-planner/shared 0.12.0 → 0.13.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/README.md +5 -3
- package/dist/dto/base.d.ts +22 -0
- package/dist/dto/base.d.ts.map +1 -0
- package/dist/dto/base.js +5 -0
- package/dist/dto/brands.d.ts +6 -19
- package/dist/dto/brands.d.ts.map +1 -1
- package/dist/dto/categories.d.ts +6 -19
- package/dist/dto/categories.d.ts.map +1 -1
- package/dist/dto/groups.d.ts +6 -19
- package/dist/dto/groups.d.ts.map +1 -1
- package/dist/dto/index.d.ts +1 -0
- package/dist/dto/index.d.ts.map +1 -1
- package/dist/dto/index.js +1 -0
- package/dist/dto/marketplaces.d.ts +6 -18
- package/dist/dto/marketplaces.d.ts.map +1 -1
- package/dist/dto/skus.d.ts +9 -24
- package/dist/dto/skus.d.ts.map +1 -1
- package/dist/dto/statuses.d.ts +6 -19
- package/dist/dto/statuses.d.ts.map +1 -1
- package/dist/dto/suppliers.d.ts +6 -19
- package/dist/dto/suppliers.d.ts.map +1 -1
- package/dist/entities/base.d.ts +10 -4
- package/dist/entities/base.d.ts.map +1 -1
- package/dist/entities/brands.d.ts +2 -2
- package/dist/entities/brands.d.ts.map +1 -1
- package/dist/entities/categories.d.ts +2 -2
- package/dist/entities/categories.d.ts.map +1 -1
- package/dist/entities/groups.d.ts +2 -2
- package/dist/entities/groups.d.ts.map +1 -1
- package/dist/entities/marketplaces.d.ts +2 -8
- package/dist/entities/marketplaces.d.ts.map +1 -1
- package/dist/entities/skus.d.ts +2 -2
- package/dist/entities/skus.d.ts.map +1 -1
- package/dist/entities/statuses.d.ts +2 -2
- package/dist/entities/statuses.d.ts.map +1 -1
- package/dist/entities/suppliers.d.ts +2 -2
- package/dist/entities/suppliers.d.ts.map +1 -1
- package/dist/query.d.ts +2 -0
- package/dist/query.d.ts.map +1 -1
- package/dist/responses/export.d.ts +7 -24
- package/dist/responses/export.d.ts.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -83,9 +83,10 @@ import type {
|
|
|
83
83
|
ImportSupplierItem, ImportSalesHistoryItem, ImportMarketplaceItem,
|
|
84
84
|
|
|
85
85
|
// Query types
|
|
86
|
-
ShopContextParams, PeriodQuery,
|
|
86
|
+
ShopContextParams, PaginationQuery, PeriodQuery, SalesHistoryQuery,
|
|
87
87
|
|
|
88
88
|
// Response types
|
|
89
|
+
PaginatedResponse,
|
|
89
90
|
UserWithRolesAndTenants, TenantWithShopAndApiKey,
|
|
90
91
|
ImportResult, DeleteDataResult,
|
|
91
92
|
SkuExportItem, BrandExportItem, CategoryExportItem, GroupExportItem, StatusExportItem,
|
|
@@ -126,13 +127,14 @@ The API uses **numeric IDs** internally for referential integrity:
|
|
|
126
127
|
| Type | Description |
|
|
127
128
|
|------|-------------|
|
|
128
129
|
| `ShopContextParams` | `{ shop_id: number; tenant_id: number }` |
|
|
130
|
+
| `PaginationQuery` | `{ limit?: number; offset?: number }` |
|
|
129
131
|
| `PeriodQuery` | `{ period_from?: string; period_to?: string }` |
|
|
132
|
+
| `SalesHistoryQuery` | `PaginationQuery & PeriodQuery` |
|
|
130
133
|
|
|
131
134
|
### Response Types
|
|
132
135
|
|
|
133
136
|
| Type | Description |
|
|
134
|
-
|
|
135
|
-
| `UserWithRolesAndTenants` | User with their roles and tenants |
|
|
137
|
+
|------|-------------|| `PaginatedResponse<T>` | `{ items: T[]; total: number; limit: number; offset: number }` || `UserWithRolesAndTenants` | User with their roles and tenants |
|
|
136
138
|
| `TenantWithShopAndApiKey` | Created tenant with shop and API key |
|
|
137
139
|
| `ImportResult` | `{ created: number; updated: number; errors: string[] }` |
|
|
138
140
|
| `DeleteDataResult` | `{ skusDeleted: number; salesHistoryDeleted: number; marketplacesDeleted: number }` |
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Base interfaces for API DTOs
|
|
3
|
+
*/
|
|
4
|
+
/** Base create DTO with code, title, and shop/tenant context */
|
|
5
|
+
export interface CodedTitledShopScopedCreateDto {
|
|
6
|
+
code: string;
|
|
7
|
+
title: string;
|
|
8
|
+
shop_id: number;
|
|
9
|
+
tenant_id: number;
|
|
10
|
+
}
|
|
11
|
+
/** Base update DTO with optional code and title */
|
|
12
|
+
export interface CodedTitledUpdateDto {
|
|
13
|
+
code?: string;
|
|
14
|
+
title?: string;
|
|
15
|
+
}
|
|
16
|
+
/** Base item with code and title */
|
|
17
|
+
export interface CodedTitledItem {
|
|
18
|
+
code: string;
|
|
19
|
+
title: string;
|
|
20
|
+
[key: string]: unknown;
|
|
21
|
+
}
|
|
22
|
+
//# sourceMappingURL=base.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../src/dto/base.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,gEAAgE;AAChE,MAAM,WAAW,8BAA8B;IAC7C,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,mDAAmD;AACnD,MAAM,WAAW,oBAAoB;IACnC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,oCAAoC;AACpC,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB"}
|
package/dist/dto/base.js
ADDED
package/dist/dto/brands.d.ts
CHANGED
|
@@ -1,20 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
title: string;
|
|
8
|
-
shop_id: number;
|
|
9
|
-
tenant_id: number;
|
|
10
|
-
}
|
|
11
|
-
export interface UpdateBrandDto {
|
|
12
|
-
code?: string;
|
|
13
|
-
title?: string;
|
|
14
|
-
}
|
|
15
|
-
export type UpdateBrandRequest = UpdateBrandDto;
|
|
16
|
-
export interface ImportBrandItem {
|
|
17
|
-
code: string;
|
|
18
|
-
title: string;
|
|
19
|
-
}
|
|
1
|
+
import type { CodedTitledItem, CodedTitledShopScopedCreateDto, CodedTitledUpdateDto } from './base';
|
|
2
|
+
export type CreateBrandRequest = CodedTitledItem;
|
|
3
|
+
export type CreateBrandDto = CodedTitledShopScopedCreateDto;
|
|
4
|
+
export type UpdateBrandDto = CodedTitledUpdateDto;
|
|
5
|
+
export type UpdateBrandRequest = CodedTitledUpdateDto;
|
|
6
|
+
export type ImportBrandItem = CodedTitledItem;
|
|
20
7
|
//# sourceMappingURL=brands.d.ts.map
|
package/dist/dto/brands.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"brands.d.ts","sourceRoot":"","sources":["../../src/dto/brands.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"brands.d.ts","sourceRoot":"","sources":["../../src/dto/brands.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,8BAA8B,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAGpG,MAAM,MAAM,kBAAkB,GAAG,eAAe,CAAC;AACjD,MAAM,MAAM,cAAc,GAAG,8BAA8B,CAAC;AAC5D,MAAM,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAClD,MAAM,MAAM,kBAAkB,GAAG,oBAAoB,CAAC;AACtD,MAAM,MAAM,eAAe,GAAG,eAAe,CAAC"}
|
package/dist/dto/categories.d.ts
CHANGED
|
@@ -1,20 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
title: string;
|
|
8
|
-
shop_id: number;
|
|
9
|
-
tenant_id: number;
|
|
10
|
-
}
|
|
11
|
-
export interface UpdateCategoryDto {
|
|
12
|
-
code?: string;
|
|
13
|
-
title?: string;
|
|
14
|
-
}
|
|
15
|
-
export type UpdateCategoryRequest = UpdateCategoryDto;
|
|
16
|
-
export interface ImportCategoryItem {
|
|
17
|
-
code: string;
|
|
18
|
-
title: string;
|
|
19
|
-
}
|
|
1
|
+
import type { CodedTitledItem, CodedTitledShopScopedCreateDto, CodedTitledUpdateDto } from './base';
|
|
2
|
+
export type CreateCategoryRequest = CodedTitledItem;
|
|
3
|
+
export type CreateCategoryDto = CodedTitledShopScopedCreateDto;
|
|
4
|
+
export type UpdateCategoryDto = CodedTitledUpdateDto;
|
|
5
|
+
export type UpdateCategoryRequest = CodedTitledUpdateDto;
|
|
6
|
+
export type ImportCategoryItem = CodedTitledItem;
|
|
20
7
|
//# sourceMappingURL=categories.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"categories.d.ts","sourceRoot":"","sources":["../../src/dto/categories.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"categories.d.ts","sourceRoot":"","sources":["../../src/dto/categories.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,8BAA8B,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAGpG,MAAM,MAAM,qBAAqB,GAAG,eAAe,CAAC;AACpD,MAAM,MAAM,iBAAiB,GAAG,8BAA8B,CAAC;AAC/D,MAAM,MAAM,iBAAiB,GAAG,oBAAoB,CAAC;AACrD,MAAM,MAAM,qBAAqB,GAAG,oBAAoB,CAAC;AACzD,MAAM,MAAM,kBAAkB,GAAG,eAAe,CAAC"}
|
package/dist/dto/groups.d.ts
CHANGED
|
@@ -1,20 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
title: string;
|
|
8
|
-
shop_id: number;
|
|
9
|
-
tenant_id: number;
|
|
10
|
-
}
|
|
11
|
-
export interface UpdateGroupDto {
|
|
12
|
-
code?: string;
|
|
13
|
-
title?: string;
|
|
14
|
-
}
|
|
15
|
-
export type UpdateGroupRequest = UpdateGroupDto;
|
|
16
|
-
export interface ImportGroupItem {
|
|
17
|
-
code: string;
|
|
18
|
-
title: string;
|
|
19
|
-
}
|
|
1
|
+
import type { CodedTitledItem, CodedTitledShopScopedCreateDto, CodedTitledUpdateDto } from './base';
|
|
2
|
+
export type CreateGroupRequest = CodedTitledItem;
|
|
3
|
+
export type CreateGroupDto = CodedTitledShopScopedCreateDto;
|
|
4
|
+
export type UpdateGroupDto = CodedTitledUpdateDto;
|
|
5
|
+
export type UpdateGroupRequest = CodedTitledUpdateDto;
|
|
6
|
+
export type ImportGroupItem = CodedTitledItem;
|
|
20
7
|
//# sourceMappingURL=groups.d.ts.map
|
package/dist/dto/groups.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"groups.d.ts","sourceRoot":"","sources":["../../src/dto/groups.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"groups.d.ts","sourceRoot":"","sources":["../../src/dto/groups.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,8BAA8B,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAGpG,MAAM,MAAM,kBAAkB,GAAG,eAAe,CAAC;AACjD,MAAM,MAAM,cAAc,GAAG,8BAA8B,CAAC;AAC5D,MAAM,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAClD,MAAM,MAAM,kBAAkB,GAAG,oBAAoB,CAAC;AACtD,MAAM,MAAM,eAAe,GAAG,eAAe,CAAC"}
|
package/dist/dto/index.d.ts
CHANGED
package/dist/dto/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dto/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dto/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC"}
|
package/dist/dto/index.js
CHANGED
|
@@ -23,6 +23,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
23
23
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
__exportStar(require("./base"), exports);
|
|
26
27
|
__exportStar(require("./users"), exports);
|
|
27
28
|
__exportStar(require("./tenants"), exports);
|
|
28
29
|
__exportStar(require("./shops"), exports);
|
|
@@ -1,19 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
title: string;
|
|
8
|
-
shop_id: number;
|
|
9
|
-
tenant_id: number;
|
|
10
|
-
}
|
|
11
|
-
export interface UpdateMarketplaceDto {
|
|
12
|
-
title?: string;
|
|
13
|
-
}
|
|
14
|
-
export type UpdateMarketplaceRequest = UpdateMarketplaceDto;
|
|
15
|
-
export interface ImportMarketplaceItem {
|
|
16
|
-
code: string;
|
|
17
|
-
title: string;
|
|
18
|
-
}
|
|
1
|
+
import type { CodedTitledItem, CodedTitledShopScopedCreateDto, CodedTitledUpdateDto } from './base';
|
|
2
|
+
export type CreateMarketplaceRequest = CodedTitledItem;
|
|
3
|
+
export type CreateMarketplaceDto = CodedTitledShopScopedCreateDto;
|
|
4
|
+
export type UpdateMarketplaceDto = CodedTitledUpdateDto;
|
|
5
|
+
export type UpdateMarketplaceRequest = CodedTitledUpdateDto;
|
|
6
|
+
export type ImportMarketplaceItem = CodedTitledItem;
|
|
19
7
|
//# sourceMappingURL=marketplaces.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"marketplaces.d.ts","sourceRoot":"","sources":["../../src/dto/marketplaces.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"marketplaces.d.ts","sourceRoot":"","sources":["../../src/dto/marketplaces.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,8BAA8B,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAEpG,MAAM,MAAM,wBAAwB,GAAG,eAAe,CAAC;AACvD,MAAM,MAAM,oBAAoB,GAAG,8BAA8B,CAAC;AAClE,MAAM,MAAM,oBAAoB,GAAG,oBAAoB,CAAC;AACxD,MAAM,MAAM,wBAAwB,GAAG,oBAAoB,CAAC;AAC5D,MAAM,MAAM,qBAAqB,GAAG,eAAe,CAAC"}
|
package/dist/dto/skus.d.ts
CHANGED
|
@@ -1,40 +1,25 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import type { CodedTitledItem, CodedTitledShopScopedCreateDto, CodedTitledUpdateDto } from './base';
|
|
2
|
+
/** SKU optional fields */
|
|
3
|
+
interface SkuOptionalFields {
|
|
4
4
|
title2?: string;
|
|
5
5
|
category_id?: number;
|
|
6
6
|
group_id?: number;
|
|
7
7
|
status_id?: number;
|
|
8
8
|
supplier_id?: number;
|
|
9
9
|
}
|
|
10
|
-
export interface
|
|
11
|
-
code: string;
|
|
12
|
-
title: string;
|
|
13
|
-
title2?: string | null;
|
|
14
|
-
shop_id: number;
|
|
15
|
-
tenant_id: number;
|
|
16
|
-
category_id?: number | null;
|
|
17
|
-
group_id?: number | null;
|
|
18
|
-
status_id?: number | null;
|
|
19
|
-
supplier_id?: number | null;
|
|
10
|
+
export interface CreateSkuRequest extends CodedTitledItem, SkuOptionalFields {
|
|
20
11
|
}
|
|
21
|
-
export interface
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
title2?: string | null;
|
|
25
|
-
category_id?: number | null;
|
|
26
|
-
group_id?: number | null;
|
|
27
|
-
status_id?: number | null;
|
|
28
|
-
supplier_id?: number | null;
|
|
12
|
+
export interface CreateSkuDto extends CodedTitledShopScopedCreateDto, SkuOptionalFields {
|
|
13
|
+
}
|
|
14
|
+
export interface UpdateSkuDto extends CodedTitledUpdateDto, SkuOptionalFields {
|
|
29
15
|
}
|
|
30
16
|
export type UpdateSkuRequest = UpdateSkuDto;
|
|
31
|
-
export interface ImportSkuItem {
|
|
32
|
-
code: string;
|
|
33
|
-
title: string;
|
|
17
|
+
export interface ImportSkuItem extends CodedTitledItem {
|
|
34
18
|
title2?: string;
|
|
35
19
|
category?: string;
|
|
36
20
|
group?: string;
|
|
37
21
|
status?: string;
|
|
38
22
|
supplier?: string;
|
|
39
23
|
}
|
|
24
|
+
export {};
|
|
40
25
|
//# sourceMappingURL=skus.d.ts.map
|
package/dist/dto/skus.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skus.d.ts","sourceRoot":"","sources":["../../src/dto/skus.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"skus.d.ts","sourceRoot":"","sources":["../../src/dto/skus.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,8BAA8B,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAEpG,0BAA0B;AAC1B,UAAU,iBAAiB;IACzB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,gBAAiB,SAAQ,eAAe,EAAE,iBAAiB;CAAG;AAE/E,MAAM,WAAW,YAAa,SAAQ,8BAA8B,EAAE,iBAAiB;CAAG;AAE1F,MAAM,WAAW,YAAa,SAAQ,oBAAoB,EAAE,iBAAiB;CAAG;AAChF,MAAM,MAAM,gBAAgB,GAAG,YAAY,CAAC;AAE5C,MAAM,WAAW,aAAc,SAAQ,eAAe;IACpD,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
|
package/dist/dto/statuses.d.ts
CHANGED
|
@@ -1,20 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
title: string;
|
|
8
|
-
shop_id: number;
|
|
9
|
-
tenant_id: number;
|
|
10
|
-
}
|
|
11
|
-
export interface UpdateStatusDto {
|
|
12
|
-
code?: string;
|
|
13
|
-
title?: string;
|
|
14
|
-
}
|
|
15
|
-
export type UpdateStatusRequest = UpdateStatusDto;
|
|
16
|
-
export interface ImportStatusItem {
|
|
17
|
-
code: string;
|
|
18
|
-
title: string;
|
|
19
|
-
}
|
|
1
|
+
import type { CodedTitledItem, CodedTitledShopScopedCreateDto, CodedTitledUpdateDto } from './base';
|
|
2
|
+
export type CreateStatusRequest = CodedTitledItem;
|
|
3
|
+
export type CreateStatusDto = CodedTitledShopScopedCreateDto;
|
|
4
|
+
export type UpdateStatusDto = CodedTitledUpdateDto;
|
|
5
|
+
export type UpdateStatusRequest = CodedTitledUpdateDto;
|
|
6
|
+
export type ImportStatusItem = CodedTitledItem;
|
|
20
7
|
//# sourceMappingURL=statuses.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"statuses.d.ts","sourceRoot":"","sources":["../../src/dto/statuses.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"statuses.d.ts","sourceRoot":"","sources":["../../src/dto/statuses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,8BAA8B,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAGpG,MAAM,MAAM,mBAAmB,GAAG,eAAe,CAAC;AAClD,MAAM,MAAM,eAAe,GAAG,8BAA8B,CAAC;AAC7D,MAAM,MAAM,eAAe,GAAG,oBAAoB,CAAC;AACnD,MAAM,MAAM,mBAAmB,GAAG,oBAAoB,CAAC;AACvD,MAAM,MAAM,gBAAgB,GAAG,eAAe,CAAC"}
|
package/dist/dto/suppliers.d.ts
CHANGED
|
@@ -1,20 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
title: string;
|
|
8
|
-
shop_id: number;
|
|
9
|
-
tenant_id: number;
|
|
10
|
-
}
|
|
11
|
-
export interface UpdateSupplierDto {
|
|
12
|
-
code?: string;
|
|
13
|
-
title?: string;
|
|
14
|
-
}
|
|
15
|
-
export type UpdateSupplierRequest = UpdateSupplierDto;
|
|
16
|
-
export interface ImportSupplierItem {
|
|
17
|
-
code: string;
|
|
18
|
-
title: string;
|
|
19
|
-
}
|
|
1
|
+
import type { CodedTitledItem, CodedTitledShopScopedCreateDto, CodedTitledUpdateDto } from './base';
|
|
2
|
+
export type CreateSupplierRequest = CodedTitledItem;
|
|
3
|
+
export type CreateSupplierDto = CodedTitledShopScopedCreateDto;
|
|
4
|
+
export type UpdateSupplierDto = CodedTitledUpdateDto;
|
|
5
|
+
export type UpdateSupplierRequest = CodedTitledUpdateDto;
|
|
6
|
+
export type ImportSupplierItem = CodedTitledItem;
|
|
20
7
|
//# sourceMappingURL=suppliers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"suppliers.d.ts","sourceRoot":"","sources":["../../src/dto/suppliers.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"suppliers.d.ts","sourceRoot":"","sources":["../../src/dto/suppliers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,8BAA8B,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAGpG,MAAM,MAAM,qBAAqB,GAAG,eAAe,CAAC;AACpD,MAAM,MAAM,iBAAiB,GAAG,8BAA8B,CAAC;AAC/D,MAAM,MAAM,iBAAiB,GAAG,oBAAoB,CAAC;AACrD,MAAM,MAAM,qBAAqB,GAAG,oBAAoB,CAAC;AACzD,MAAM,MAAM,kBAAkB,GAAG,eAAe,CAAC"}
|
package/dist/entities/base.d.ts
CHANGED
|
@@ -1,14 +1,20 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Base interface for entities scoped to both shop and tenant
|
|
3
|
-
* (e.g.,
|
|
3
|
+
* without code/title (e.g., SalesHistory)
|
|
4
4
|
*/
|
|
5
|
-
export interface
|
|
5
|
+
export interface ShopScopedBaseEntity {
|
|
6
6
|
id: number;
|
|
7
|
-
code: string;
|
|
8
|
-
title: string;
|
|
9
7
|
shop_id: number;
|
|
10
8
|
tenant_id: number;
|
|
11
9
|
created_at: Date;
|
|
12
10
|
updated_at: Date;
|
|
13
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* Interface for shop-scoped entities with code and title
|
|
14
|
+
* (e.g., SKUs, Brands, Categories, Marketplaces)
|
|
15
|
+
*/
|
|
16
|
+
export interface CodedShopScopedEntity extends ShopScopedBaseEntity {
|
|
17
|
+
code: string;
|
|
18
|
+
title: string;
|
|
19
|
+
}
|
|
14
20
|
//# sourceMappingURL=base.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../src/entities/base.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,WAAW,
|
|
1
|
+
{"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../src/entities/base.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,WAAW,oBAAoB;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,IAAI,CAAC;IACjB,UAAU,EAAE,IAAI,CAAC;CAClB;AAED;;;GAGG;AACH,MAAM,WAAW,qBAAsB,SAAQ,oBAAoB;IACjE,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"brands.d.ts","sourceRoot":"","sources":["../../src/entities/brands.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"brands.d.ts","sourceRoot":"","sources":["../../src/entities/brands.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAEpD,MAAM,WAAW,KAAM,SAAQ,qBAAqB;CAAG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"categories.d.ts","sourceRoot":"","sources":["../../src/entities/categories.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"categories.d.ts","sourceRoot":"","sources":["../../src/entities/categories.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAEpD,MAAM,WAAW,QAAS,SAAQ,qBAAqB;CAAG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"groups.d.ts","sourceRoot":"","sources":["../../src/entities/groups.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"groups.d.ts","sourceRoot":"","sources":["../../src/entities/groups.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAEpD,MAAM,WAAW,KAAM,SAAQ,qBAAqB;CAAG"}
|
|
@@ -1,10 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
code: string;
|
|
4
|
-
title: string;
|
|
5
|
-
shop_id: number;
|
|
6
|
-
tenant_id: number;
|
|
7
|
-
created_at: Date;
|
|
8
|
-
updated_at: Date;
|
|
1
|
+
import type { CodedShopScopedEntity } from './base';
|
|
2
|
+
export interface Marketplace extends CodedShopScopedEntity {
|
|
9
3
|
}
|
|
10
4
|
//# sourceMappingURL=marketplaces.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"marketplaces.d.ts","sourceRoot":"","sources":["../../src/entities/marketplaces.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"marketplaces.d.ts","sourceRoot":"","sources":["../../src/entities/marketplaces.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAEpD,MAAM,WAAW,WAAY,SAAQ,qBAAqB;CAAG"}
|
package/dist/entities/skus.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
export interface Sku extends
|
|
1
|
+
import type { CodedShopScopedEntity } from './base';
|
|
2
|
+
export interface Sku extends CodedShopScopedEntity {
|
|
3
3
|
title2?: string | null;
|
|
4
4
|
category_id?: number | null;
|
|
5
5
|
group_id?: number | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skus.d.ts","sourceRoot":"","sources":["../../src/entities/skus.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"skus.d.ts","sourceRoot":"","sources":["../../src/entities/skus.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAEpD,MAAM,WAAW,GAAI,SAAQ,qBAAqB;IAChD,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"statuses.d.ts","sourceRoot":"","sources":["../../src/entities/statuses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"statuses.d.ts","sourceRoot":"","sources":["../../src/entities/statuses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAEpD,MAAM,WAAW,MAAO,SAAQ,qBAAqB;CAAG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"suppliers.d.ts","sourceRoot":"","sources":["../../src/entities/suppliers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"suppliers.d.ts","sourceRoot":"","sources":["../../src/entities/suppliers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,WAAW,CAAC;AAEvD,MAAM,WAAW,QAAS,SAAQ,qBAAqB;CAAG"}
|
package/dist/query.d.ts
CHANGED
package/dist/query.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"query.d.ts","sourceRoot":"","sources":["../src/query.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;CAC5C;AAED,MAAM,WAAW,eAAe;IAC9B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,WAAW;IAC1B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,iBAAiB;IAChC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB,CAAC,CAAC;IAClC,KAAK,EAAE,CAAC,EAAE,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB"}
|
|
1
|
+
{"version":3,"file":"query.d.ts","sourceRoot":"","sources":["../src/query.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;CAC5C;AAED,MAAM,WAAW,eAAe;IAC9B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,WAAW;IAC1B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,iBAAkB,SAAQ,WAAW,EAAE,eAAe;CAAG;AAE1E,MAAM,WAAW,iBAAiB;IAChC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB,CAAC,CAAC;IAClC,KAAK,EAAE,CAAC,EAAE,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { CodedTitledItem } from '../dto/base';
|
|
1
2
|
export interface SkuExportItem {
|
|
2
3
|
code: string;
|
|
3
4
|
title: string;
|
|
@@ -7,30 +8,12 @@ export interface SkuExportItem {
|
|
|
7
8
|
status?: string;
|
|
8
9
|
supplier?: string;
|
|
9
10
|
}
|
|
10
|
-
export
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
export
|
|
15
|
-
|
|
16
|
-
title: string;
|
|
17
|
-
}
|
|
18
|
-
export interface GroupExportItem {
|
|
19
|
-
code: string;
|
|
20
|
-
title: string;
|
|
21
|
-
}
|
|
22
|
-
export interface StatusExportItem {
|
|
23
|
-
code: string;
|
|
24
|
-
title: string;
|
|
25
|
-
}
|
|
26
|
-
export interface SupplierExportItem {
|
|
27
|
-
code: string;
|
|
28
|
-
title: string;
|
|
29
|
-
}
|
|
30
|
-
export interface MarketplaceExportItem {
|
|
31
|
-
code: string;
|
|
32
|
-
title: string;
|
|
33
|
-
}
|
|
11
|
+
export type BrandExportItem = CodedTitledItem;
|
|
12
|
+
export type CategoryExportItem = CodedTitledItem;
|
|
13
|
+
export type GroupExportItem = CodedTitledItem;
|
|
14
|
+
export type StatusExportItem = CodedTitledItem;
|
|
15
|
+
export type SupplierExportItem = CodedTitledItem;
|
|
16
|
+
export type MarketplaceExportItem = CodedTitledItem;
|
|
34
17
|
export interface SalesHistoryExportItem {
|
|
35
18
|
marketplace: string;
|
|
36
19
|
period: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"export.d.ts","sourceRoot":"","sources":["../../src/responses/export.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,
|
|
1
|
+
{"version":3,"file":"export.d.ts","sourceRoot":"","sources":["../../src/responses/export.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAEnD,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,MAAM,eAAe,GAAG,eAAe,CAAC;AAE9C,MAAM,MAAM,kBAAkB,GAAG,eAAe,CAAC;AAEjD,MAAM,MAAM,eAAe,GAAG,eAAe,CAAC;AAE9C,MAAM,MAAM,gBAAgB,GAAG,eAAe,CAAC;AAE/C,MAAM,MAAM,kBAAkB,GAAG,eAAe,CAAC;AAEjD,MAAM,MAAM,qBAAqB,GAAG,eAAe,CAAC;AAEpD,MAAM,WAAW,sBAAsB;IACrC,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;CAClB"}
|