@openbox/shared-types 0.5.25 → 0.5.27

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.
Files changed (37) hide show
  1. package/lib/inventories/Batches/CreateSingle/Request.d.ts +2 -0
  2. package/lib/inventories/Batches/CreateSingle/Request.js +3 -0
  3. package/lib/inventories/Batches/CreateSingle/Request.js.map +1 -0
  4. package/lib/inventories/Batches/CreateSingle/Response.d.ts +2 -0
  5. package/lib/inventories/Batches/CreateSingle/Response.js +3 -0
  6. package/lib/inventories/Batches/CreateSingle/Response.js.map +1 -0
  7. package/lib/inventories/Batches/GetSingle/Response.d.ts +2 -0
  8. package/lib/inventories/Batches/GetSingle/Response.js +3 -0
  9. package/lib/inventories/Batches/GetSingle/Response.js.map +1 -0
  10. package/lib/inventories/Batches/UpdateSingle/Request.d.ts +2 -0
  11. package/lib/inventories/Batches/UpdateSingle/Request.js +3 -0
  12. package/lib/inventories/Batches/UpdateSingle/Request.js.map +1 -0
  13. package/lib/inventories/Batches/UpdateSingle/Response.d.ts +2 -0
  14. package/lib/inventories/Batches/UpdateSingle/Response.js +3 -0
  15. package/lib/inventories/Batches/UpdateSingle/Response.js.map +1 -0
  16. package/lib/inventories/Batches/index.d.ts +6 -0
  17. package/lib/inventories/Batches/index.js +23 -0
  18. package/lib/inventories/Batches/index.js.map +1 -0
  19. package/lib/inventories/Batches/inventories.batches.types.d.ts +7 -0
  20. package/lib/inventories/Batches/inventories.batches.types.js +3 -0
  21. package/lib/inventories/Batches/inventories.batches.types.js.map +1 -0
  22. package/lib/inventories/Products/inventories.products.types.d.ts +7 -2
  23. package/lib/inventories/index.d.ts +1 -0
  24. package/lib/inventories/index.js +1 -0
  25. package/lib/inventories/index.js.map +1 -1
  26. package/lib/partners/V1/invoices/CreateSingle/Request.d.ts +5 -0
  27. package/package.json +1 -1
  28. package/src/inventories/Batches/CreateSingle/Request.ts +3 -0
  29. package/src/inventories/Batches/CreateSingle/Response.ts +3 -0
  30. package/src/inventories/Batches/GetSingle/Response.ts +3 -0
  31. package/src/inventories/Batches/UpdateSingle/Request.ts +3 -0
  32. package/src/inventories/Batches/UpdateSingle/Response.ts +3 -0
  33. package/src/inventories/Batches/index.ts +6 -0
  34. package/src/inventories/Batches/inventories.batches.types.ts +9 -0
  35. package/src/inventories/Products/inventories.products.types.ts +7 -2
  36. package/src/inventories/index.ts +1 -0
  37. package/src/partners/V1/invoices/CreateSingle/Request.ts +6 -0
@@ -0,0 +1,2 @@
1
+ import { InventoriesBatchesRequest } from '../inventories.batches.types';
2
+ export type InventoriesBatchesCreateSingleRequest = InventoriesBatchesRequest;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=Request.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Request.js","sourceRoot":"","sources":["../../../../src/inventories/Batches/CreateSingle/Request.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ import { SingleResponse } from '../../../interfaces';
2
+ export type InventoriesBatchesCreateSingleResponse = SingleResponse;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=Response.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Response.js","sourceRoot":"","sources":["../../../../src/inventories/Batches/CreateSingle/Response.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ import { InventoriesBatchesResponse } from '../inventories.batches.types';
2
+ export type InventoriesBatchesGetSingleResponse = InventoriesBatchesResponse;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=Response.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Response.js","sourceRoot":"","sources":["../../../../src/inventories/Batches/GetSingle/Response.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ import { InventoriesBatchesRequest } from '../inventories.batches.types';
2
+ export type InventoriesBatchesUpdateSingleRequest = Partial<InventoriesBatchesRequest>;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=Request.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Request.js","sourceRoot":"","sources":["../../../../src/inventories/Batches/UpdateSingle/Request.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ import { SingleResponse } from '../../../interfaces';
2
+ export type InventoriesBatchesUpdateSingleResponse = SingleResponse;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=Response.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Response.js","sourceRoot":"","sources":["../../../../src/inventories/Batches/UpdateSingle/Response.ts"],"names":[],"mappings":""}
@@ -0,0 +1,6 @@
1
+ export * from './CreateSingle/Request';
2
+ export * from './CreateSingle/Response';
3
+ export * from './GetSingle/Response';
4
+ export * from './inventories.batches.types';
5
+ export * from './UpdateSingle/Request';
6
+ export * from './UpdateSingle/Response';
@@ -0,0 +1,23 @@
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("./CreateSingle/Request"), exports);
18
+ __exportStar(require("./CreateSingle/Response"), exports);
19
+ __exportStar(require("./GetSingle/Response"), exports);
20
+ __exportStar(require("./inventories.batches.types"), exports);
21
+ __exportStar(require("./UpdateSingle/Request"), exports);
22
+ __exportStar(require("./UpdateSingle/Response"), exports);
23
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/inventories/Batches/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yDAAsC;AACtC,0DAAuC;AACvC,uDAAoC;AACpC,8DAA2C;AAC3C,yDAAsC;AACtC,0DAAuC"}
@@ -0,0 +1,7 @@
1
+ export type InventoriesBatches = {
2
+ id: string;
3
+ batchNumber: string;
4
+ expirationDate: Date;
5
+ };
6
+ export type InventoriesBatchesRequest = Omit<InventoriesBatches, 'id'>;
7
+ export type InventoriesBatchesResponse = InventoriesBatches;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=inventories.batches.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"inventories.batches.types.js","sourceRoot":"","sources":["../../../src/inventories/Batches/inventories.batches.types.ts"],"names":[],"mappings":""}
@@ -1,19 +1,24 @@
1
1
  import { ServicesSellingTypes } from '../../services/SellingTypes/services.selling-types.types';
2
+ import { InventoriesBatches } from '../Batches';
2
3
  import { InventoriesUnits } from '../Units';
3
4
  export type InventoriesProducts = {
4
5
  id: string;
5
6
  name: string;
6
7
  description?: string;
7
8
  barcode?: string;
9
+ code?: string;
8
10
  price?: number;
9
11
  threshold?: number;
10
12
  trackInventory?: boolean;
13
+ incIva?: boolean;
14
+ requiresBatch?: boolean;
11
15
  unit: InventoriesUnits;
12
- incIva: boolean;
13
16
  sellingType: ServicesSellingTypes;
17
+ batches?: InventoriesBatches[];
14
18
  };
15
- export type InventoriesProductsRequest = Omit<InventoriesProducts, 'id' | 'unit' | 'sellingType'> & {
19
+ export type InventoriesProductsRequest = Omit<InventoriesProducts, 'id' | 'unit' | 'sellingType' | 'batches'> & {
16
20
  unit: string;
17
21
  sellingType: number;
22
+ batch?: Omit<InventoriesBatches, 'id'>;
18
23
  };
19
24
  export type InventoriesProductsResponse = InventoriesProducts;
@@ -1,3 +1,4 @@
1
+ export * from './Batches';
1
2
  export * from './Categories';
2
3
  export * from './Products';
3
4
  export * from './Units';
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./Batches"), exports);
17
18
  __exportStar(require("./Categories"), exports);
18
19
  __exportStar(require("./Products"), exports);
19
20
  __exportStar(require("./Units"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/inventories/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,+CAA4B;AAC5B,6CAA0B;AAC1B,0CAAuB"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/inventories/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4CAAyB;AACzB,+CAA4B;AAC5B,6CAA0B;AAC1B,0CAAuB"}
@@ -104,10 +104,15 @@ export type PartnersV1InvoicesCreateSingleRequestDataDetailsService = {
104
104
  id: string;
105
105
  name: string;
106
106
  };
107
+ export type PartnersV1InvoicesCreateSingleRequestDataDetailsProductBatch = {
108
+ batchNumber: string;
109
+ expirationDate: Date;
110
+ };
107
111
  export type PartnersV1InvoicesCreateSingleRequestDataDetailsProduct = {
108
112
  id: string;
109
113
  name: string;
110
114
  unit: InventoriesUnitsSVCode;
115
+ batch?: PartnersV1InvoicesCreateSingleRequestDataDetailsProductBatch;
111
116
  };
112
117
  export type PartnersV1InvoicesCreateSingleRequestDataDetails = {
113
118
  service: PartnersV1InvoicesCreateSingleRequestDataDetailsService | null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openbox/shared-types",
3
- "version": "0.5.25",
3
+ "version": "0.5.27",
4
4
  "description": "Shared Types for Openbox Cloud. ",
5
5
  "types": "lib/index.d.js",
6
6
  "main": "lib/index.js",
@@ -0,0 +1,3 @@
1
+ import { InventoriesBatchesRequest } from '../inventories.batches.types'
2
+
3
+ export type InventoriesBatchesCreateSingleRequest = InventoriesBatchesRequest
@@ -0,0 +1,3 @@
1
+ import { SingleResponse } from '../../../interfaces'
2
+
3
+ export type InventoriesBatchesCreateSingleResponse = SingleResponse
@@ -0,0 +1,3 @@
1
+ import { InventoriesBatchesResponse } from '../inventories.batches.types'
2
+
3
+ export type InventoriesBatchesGetSingleResponse = InventoriesBatchesResponse
@@ -0,0 +1,3 @@
1
+ import { InventoriesBatchesRequest } from '../inventories.batches.types'
2
+
3
+ export type InventoriesBatchesUpdateSingleRequest = Partial<InventoriesBatchesRequest>
@@ -0,0 +1,3 @@
1
+ import { SingleResponse } from '../../../interfaces'
2
+
3
+ export type InventoriesBatchesUpdateSingleResponse = SingleResponse
@@ -0,0 +1,6 @@
1
+ export * from './CreateSingle/Request'
2
+ export * from './CreateSingle/Response'
3
+ export * from './GetSingle/Response'
4
+ export * from './inventories.batches.types'
5
+ export * from './UpdateSingle/Request'
6
+ export * from './UpdateSingle/Response'
@@ -0,0 +1,9 @@
1
+ export type InventoriesBatches = {
2
+ id: string
3
+ batchNumber: string
4
+ expirationDate: Date
5
+ }
6
+
7
+ export type InventoriesBatchesRequest = Omit<InventoriesBatches, 'id'>
8
+
9
+ export type InventoriesBatchesResponse = InventoriesBatches
@@ -1,4 +1,5 @@
1
1
  import { ServicesSellingTypes } from '../../services/SellingTypes/services.selling-types.types'
2
+ import { InventoriesBatches } from '../Batches'
2
3
  import { InventoriesUnits } from '../Units'
3
4
 
4
5
  export type InventoriesProducts = {
@@ -6,19 +7,23 @@ export type InventoriesProducts = {
6
7
  name: string
7
8
  description?: string
8
9
  barcode?: string
10
+ code?: string
9
11
  price?: number
10
12
  threshold?: number
11
13
  trackInventory?: boolean
14
+ incIva?: boolean
15
+ requiresBatch?: boolean
12
16
  unit: InventoriesUnits
13
- incIva: boolean
14
17
  sellingType: ServicesSellingTypes
18
+ batches?: InventoriesBatches[]
15
19
  }
16
20
 
17
21
  export type InventoriesProductsRequest = Omit<
18
22
  InventoriesProducts,
19
- 'id' | 'unit' | 'sellingType'
23
+ 'id' | 'unit' | 'sellingType' | 'batches'
20
24
  > & {
21
25
  unit: string
22
26
  sellingType: number
27
+ batch?: Omit<InventoriesBatches, 'id'>
23
28
  }
24
29
  export type InventoriesProductsResponse = InventoriesProducts
@@ -1,3 +1,4 @@
1
+ export * from './Batches'
1
2
  export * from './Categories'
2
3
  export * from './Products'
3
4
  export * from './Units'
@@ -126,10 +126,16 @@ export type PartnersV1InvoicesCreateSingleRequestDataDetailsService = {
126
126
  name: string
127
127
  }
128
128
 
129
+ export type PartnersV1InvoicesCreateSingleRequestDataDetailsProductBatch = {
130
+ batchNumber: string
131
+ expirationDate: Date
132
+ }
133
+
129
134
  export type PartnersV1InvoicesCreateSingleRequestDataDetailsProduct = {
130
135
  id: string
131
136
  name: string
132
137
  unit: InventoriesUnitsSVCode
138
+ batch?: PartnersV1InvoicesCreateSingleRequestDataDetailsProductBatch
133
139
  }
134
140
 
135
141
  export type PartnersV1InvoicesCreateSingleRequestDataDetails = {