@medusajs/medusa 1.2.1 → 1.2.2-dev.56
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/api/index.d.ts +1 -0
- package/dist/api/index.js +1 -0
- package/dist/api/index.js.map +1 -1
- package/dist/api/middlewares/error-handler.js +6 -0
- package/dist/api/middlewares/error-handler.js.map +1 -1
- package/dist/api/routes/admin/customer-groups/add-customers-batch.d.ts +27 -0
- package/dist/{db-subscribers/region.js → api/routes/admin/customer-groups/add-customers-batch.js} +60 -38
- package/dist/api/routes/admin/customer-groups/add-customers-batch.js.map +1 -0
- package/dist/api/routes/admin/customer-groups/get-customer-group-customers.d.ts +20 -0
- package/dist/{subscribers/region.js → api/routes/admin/customer-groups/get-customer-group-customers.js} +38 -27
- package/dist/api/routes/admin/customer-groups/get-customer-group-customers.js.map +1 -0
- package/dist/api/routes/admin/customer-groups/get-customer-group.d.ts +1 -1
- package/dist/api/routes/admin/customer-groups/get-customer-group.js +1 -1
- package/dist/api/routes/admin/customer-groups/index.d.ts +5 -0
- package/dist/api/routes/admin/customer-groups/index.js +8 -0
- package/dist/api/routes/admin/customer-groups/index.js.map +1 -1
- package/dist/api/routes/admin/customer-groups/list-customer-groups.d.ts +38 -0
- package/dist/api/routes/admin/customer-groups/list-customer-groups.js +200 -0
- package/dist/api/routes/admin/customer-groups/list-customer-groups.js.map +1 -0
- package/dist/api/routes/admin/customers/index.js +1 -1
- package/dist/api/routes/admin/customers/index.js.map +1 -1
- package/dist/api/routes/admin/customers/list-customers.js +12 -46
- package/dist/api/routes/admin/customers/list-customers.js.map +1 -1
- package/dist/api/routes/admin/discounts/update-discount.d.ts +2 -2
- package/dist/api/routes/admin/discounts/update-discount.js +3 -3
- package/dist/api/routes/admin/discounts/update-discount.js.map +1 -1
- package/dist/api/routes/admin/index.js +21 -19
- package/dist/api/routes/admin/index.js.map +1 -1
- package/dist/api/routes/admin/price-lists/add-prices-batch.d.ts +70 -0
- package/dist/api/routes/admin/{orders/receive-swap.js → price-lists/add-prices-batch.js} +77 -78
- package/dist/api/routes/admin/price-lists/add-prices-batch.js.map +1 -0
- package/dist/api/routes/admin/price-lists/create-price-list.d.ts +87 -0
- package/dist/api/routes/admin/price-lists/create-price-list.js +193 -0
- package/dist/api/routes/admin/price-lists/create-price-list.js.map +1 -0
- package/dist/api/routes/admin/price-lists/delete-price-list.d.ts +28 -0
- package/dist/api/routes/admin/price-lists/delete-price-list.js +84 -0
- package/dist/api/routes/admin/price-lists/delete-price-list.js.map +1 -0
- package/dist/api/routes/admin/price-lists/delete-prices-batch.d.ts +43 -0
- package/dist/api/routes/admin/price-lists/delete-prices-batch.js +118 -0
- package/dist/api/routes/admin/price-lists/delete-prices-batch.js.map +1 -0
- package/dist/api/routes/admin/price-lists/get-price-list.d.ts +22 -0
- package/dist/api/routes/admin/price-lists/get-price-list.js +78 -0
- package/dist/api/routes/admin/price-lists/get-price-list.js.map +1 -0
- package/dist/api/routes/admin/price-lists/index.d.ts +21 -0
- package/dist/api/routes/admin/price-lists/index.js +52 -0
- package/dist/api/routes/admin/price-lists/index.js.map +1 -0
- package/dist/api/routes/admin/price-lists/list-price-lists.d.ts +38 -0
- package/dist/api/routes/admin/price-lists/list-price-lists.js +197 -0
- package/dist/api/routes/admin/price-lists/list-price-lists.js.map +1 -0
- package/dist/api/routes/admin/price-lists/update-price-list.d.ts +92 -0
- package/dist/api/routes/admin/price-lists/update-price-list.js +211 -0
- package/dist/api/routes/admin/price-lists/update-price-list.js.map +1 -0
- package/dist/api/routes/admin/products/create-product.d.ts +2 -7
- package/dist/api/routes/admin/products/create-product.js +2 -24
- package/dist/api/routes/admin/products/create-product.js.map +1 -1
- package/dist/api/routes/admin/products/create-variant.d.ts +7 -9
- package/dist/api/routes/admin/products/create-variant.js +7 -26
- package/dist/api/routes/admin/products/create-variant.js.map +1 -1
- package/dist/api/routes/admin/products/index.d.ts +1 -1
- package/dist/api/routes/admin/products/index.js +7 -1
- package/dist/api/routes/admin/products/index.js.map +1 -1
- package/dist/api/routes/admin/products/update-product.d.ts +2 -7
- package/dist/api/routes/admin/products/update-product.js +2 -24
- package/dist/api/routes/admin/products/update-product.js.map +1 -1
- package/dist/api/routes/admin/products/update-variant.d.ts +10 -9
- package/dist/api/routes/admin/products/update-variant.js +10 -26
- package/dist/api/routes/admin/products/update-variant.js.map +1 -1
- package/dist/api/routes/store/auth/exists.js +4 -2
- package/dist/api/routes/store/auth/exists.js.map +1 -1
- package/dist/api/routes/store/collections/list-collections.d.ts +3 -0
- package/dist/api/routes/store/collections/list-collections.js +33 -16
- package/dist/api/routes/store/collections/list-collections.js.map +1 -1
- package/dist/api/routes/store/products/list-products.d.ts +3 -2
- package/dist/api/routes/store/products/list-products.js +39 -10
- package/dist/api/routes/store/products/list-products.js.map +1 -1
- package/dist/api/routes/store/regions/list-regions.d.ts +3 -0
- package/dist/api/routes/store/regions/list-regions.js +22 -7
- package/dist/api/routes/store/regions/list-regions.js.map +1 -1
- package/dist/api/routes/store/variants/list-variants.d.ts +4 -0
- package/dist/api/routes/store/variants/list-variants.js +33 -9
- package/dist/api/routes/store/variants/list-variants.js.map +1 -1
- package/dist/controllers/customers/index.d.ts +4 -0
- package/dist/controllers/customers/index.js +8 -0
- package/dist/controllers/customers/index.js.map +1 -0
- package/dist/controllers/customers/list-customers.d.ts +3 -0
- package/dist/controllers/customers/list-customers.js +96 -0
- package/dist/controllers/customers/list-customers.js.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/migrations/1646915480108-update_money_amount_add_price_list.d.ts +6 -0
- package/dist/migrations/1646915480108-update_money_amount_add_price_list.js +143 -0
- package/dist/migrations/1646915480108-update_money_amount_add_price_list.js.map +1 -0
- package/dist/models/customer-group.d.ts +3 -1
- package/dist/models/customer-group.js +7 -13
- package/dist/models/customer-group.js.map +1 -1
- package/dist/models/customer.js +3 -1
- package/dist/models/customer.js.map +1 -1
- package/dist/models/money-amount.d.ts +10 -3
- package/dist/models/money-amount.js +22 -5
- package/dist/models/money-amount.js.map +1 -1
- package/dist/models/price-list.d.ts +57 -0
- package/dist/models/price-list.js +142 -0
- package/dist/models/price-list.js.map +1 -0
- package/dist/repositories/customer-group.d.ts +1 -0
- package/dist/repositories/customer-group.js +24 -0
- package/dist/repositories/customer-group.js.map +1 -1
- package/dist/repositories/customer.d.ts +1 -0
- package/dist/repositories/customer.js +65 -0
- package/dist/repositories/customer.js.map +1 -1
- package/dist/repositories/money-amount.d.ts +6 -2
- package/dist/repositories/money-amount.js +102 -2
- package/dist/repositories/money-amount.js.map +1 -1
- package/dist/repositories/price-list.d.ts +4 -0
- package/dist/repositories/price-list.js +38 -0
- package/dist/repositories/price-list.js.map +1 -0
- package/dist/repositories/product.d.ts +1 -0
- package/dist/repositories/product.js +6 -2
- package/dist/repositories/product.js.map +1 -1
- package/dist/services/customer-group.d.ts +24 -1
- package/dist/services/customer-group.js +95 -2
- package/dist/services/customer-group.js.map +1 -1
- package/dist/services/customer.d.ts +1 -3
- package/dist/services/customer.js +40 -44
- package/dist/services/customer.js.map +1 -1
- package/dist/services/discount.js +19 -11
- package/dist/services/discount.js.map +1 -1
- package/dist/services/price-list.d.ts +86 -0
- package/dist/services/price-list.js +469 -0
- package/dist/services/price-list.js.map +1 -0
- package/dist/services/product-collection.js +29 -8
- package/dist/services/product-collection.js.map +1 -1
- package/dist/services/product-variant.d.ts +16 -9
- package/dist/services/product-variant.js +37 -33
- package/dist/services/product-variant.js.map +1 -1
- package/dist/services/product.js +38 -26
- package/dist/services/product.js.map +1 -1
- package/dist/types/customer-groups.d.ts +5 -1
- package/dist/types/customer-groups.js +25 -0
- package/dist/types/customer-groups.js.map +1 -1
- package/dist/types/customers.d.ts +1 -0
- package/dist/types/customers.js +5 -0
- package/dist/types/customers.js.map +1 -1
- package/dist/types/price-list.d.ts +70 -0
- package/dist/types/price-list.js +152 -0
- package/dist/types/price-list.js.map +1 -0
- package/dist/types/product-variant.d.ts +20 -3
- package/dist/types/product-variant.js +69 -5
- package/dist/types/product-variant.js.map +1 -1
- package/dist/utils/exception-formatter.d.ts +5 -0
- package/dist/utils/exception-formatter.js +29 -0
- package/dist/utils/exception-formatter.js.map +1 -0
- package/package.json +7 -7
- package/yarn-error.log +79 -5
- package/dist/api/routes/admin/orders/receive-swap.d.ts +0 -46
- package/dist/api/routes/admin/orders/receive-swap.js.map +0 -1
- package/dist/db-subscribers/region.d.ts +0 -6
- package/dist/db-subscribers/region.js.map +0 -1
- package/dist/entity-subscribers/region.d.ts +0 -6
- package/dist/entity-subscribers/region.js +0 -27
- package/dist/entity-subscribers/region.js.map +0 -1
- package/dist/loaders/db-subscribers.d.ts +0 -6
- package/dist/loaders/db-subscribers.js +0 -53
- package/dist/loaders/db-subscribers.js.map +0 -1
- package/dist/subscribers/region.d.ts +0 -14
- package/dist/subscribers/region.js.map +0 -1
|
@@ -75,6 +75,15 @@ var __read = (this && this.__read) || function (o, n) {
|
|
|
75
75
|
}
|
|
76
76
|
return ar;
|
|
77
77
|
};
|
|
78
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
79
|
+
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
80
|
+
if (ar || !(i in from)) {
|
|
81
|
+
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
82
|
+
ar[i] = from[i];
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
return to.concat(ar || Array.prototype.slice.call(from));
|
|
86
|
+
};
|
|
78
87
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
79
88
|
exports.StoreGetProductsParams = exports.StoreGetProductsPaginationParams = void 0;
|
|
80
89
|
var class_transformer_1 = require("class-transformer");
|
|
@@ -83,6 +92,7 @@ var lodash_1 = require("lodash");
|
|
|
83
92
|
var _1 = require(".");
|
|
84
93
|
var common_1 = require("../../../../types/common");
|
|
85
94
|
var validator_1 = require("../../../../utils/validator");
|
|
95
|
+
var is_type_1 = require("../../../../utils/validators/is-type");
|
|
86
96
|
var is_boolean_1 = require("../../../../utils/validators/is-boolean");
|
|
87
97
|
/**
|
|
88
98
|
* @oas [get] /products
|
|
@@ -128,7 +138,7 @@ var is_boolean_1 = require("../../../../utils/validators/is-boolean");
|
|
|
128
138
|
* $ref: "#/components/schemas/product"
|
|
129
139
|
*/
|
|
130
140
|
exports.default = (function (req, res) { return __awaiter(void 0, void 0, void 0, function () {
|
|
131
|
-
var productService, validated, filterableFields, listConfig, _a, products, count;
|
|
141
|
+
var productService, validated, filterableFields, includeFields, set, expandFields, listConfig, _a, products, count;
|
|
132
142
|
return __generator(this, function (_b) {
|
|
133
143
|
switch (_b.label) {
|
|
134
144
|
case 0:
|
|
@@ -137,13 +147,28 @@ exports.default = (function (req, res) { return __awaiter(void 0, void 0, void 0
|
|
|
137
147
|
case 1:
|
|
138
148
|
validated = _b.sent();
|
|
139
149
|
filterableFields = (0, lodash_1.omit)(validated, [
|
|
150
|
+
"fields",
|
|
151
|
+
"expand",
|
|
140
152
|
"limit",
|
|
141
153
|
"offset",
|
|
142
154
|
]);
|
|
143
155
|
// get only published products for store endpoint
|
|
144
156
|
filterableFields["status"] = ["published"];
|
|
157
|
+
includeFields = [];
|
|
158
|
+
if (validated.fields) {
|
|
159
|
+
set = new Set(validated.fields.split(","));
|
|
160
|
+
set.add("id");
|
|
161
|
+
includeFields = __spreadArray([], __read(set), false);
|
|
162
|
+
}
|
|
163
|
+
expandFields = [];
|
|
164
|
+
if (validated.expand) {
|
|
165
|
+
expandFields = validated.expand.split(",");
|
|
166
|
+
}
|
|
145
167
|
listConfig = {
|
|
146
|
-
|
|
168
|
+
select: includeFields.length ? includeFields : undefined,
|
|
169
|
+
relations: expandFields.length
|
|
170
|
+
? expandFields
|
|
171
|
+
: _1.defaultStoreProductsRelations,
|
|
147
172
|
skip: validated.offset,
|
|
148
173
|
take: validated.limit,
|
|
149
174
|
};
|
|
@@ -165,6 +190,16 @@ var StoreGetProductsPaginationParams = /** @class */ (function () {
|
|
|
165
190
|
this.offset = 0;
|
|
166
191
|
this.limit = 100;
|
|
167
192
|
}
|
|
193
|
+
__decorate([
|
|
194
|
+
(0, class_validator_1.IsString)(),
|
|
195
|
+
(0, class_validator_1.IsOptional)(),
|
|
196
|
+
__metadata("design:type", String)
|
|
197
|
+
], StoreGetProductsPaginationParams.prototype, "fields", void 0);
|
|
198
|
+
__decorate([
|
|
199
|
+
(0, class_validator_1.IsString)(),
|
|
200
|
+
(0, class_validator_1.IsOptional)(),
|
|
201
|
+
__metadata("design:type", String)
|
|
202
|
+
], StoreGetProductsPaginationParams.prototype, "expand", void 0);
|
|
168
203
|
__decorate([
|
|
169
204
|
(0, class_validator_1.IsNumber)(),
|
|
170
205
|
(0, class_validator_1.IsOptional)(),
|
|
@@ -186,9 +221,9 @@ var StoreGetProductsParams = /** @class */ (function (_super) {
|
|
|
186
221
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
187
222
|
}
|
|
188
223
|
__decorate([
|
|
189
|
-
(0, class_validator_1.IsString)(),
|
|
190
224
|
(0, class_validator_1.IsOptional)(),
|
|
191
|
-
|
|
225
|
+
(0, is_type_1.IsType)([String, [String]]),
|
|
226
|
+
__metadata("design:type", Object)
|
|
192
227
|
], StoreGetProductsParams.prototype, "id", void 0);
|
|
193
228
|
__decorate([
|
|
194
229
|
(0, class_validator_1.IsString)(),
|
|
@@ -246,12 +281,6 @@ var StoreGetProductsParams = /** @class */ (function (_super) {
|
|
|
246
281
|
(0, class_transformer_1.Type)(function () { return common_1.DateComparisonOperator; }),
|
|
247
282
|
__metadata("design:type", common_1.DateComparisonOperator)
|
|
248
283
|
], StoreGetProductsParams.prototype, "updated_at", void 0);
|
|
249
|
-
__decorate([
|
|
250
|
-
(0, class_validator_1.ValidateNested)(),
|
|
251
|
-
(0, class_validator_1.IsOptional)(),
|
|
252
|
-
(0, class_transformer_1.Type)(function () { return common_1.DateComparisonOperator; }),
|
|
253
|
-
__metadata("design:type", common_1.DateComparisonOperator)
|
|
254
|
-
], StoreGetProductsParams.prototype, "deleted_at", void 0);
|
|
255
284
|
return StoreGetProductsParams;
|
|
256
285
|
}(StoreGetProductsPaginationParams));
|
|
257
286
|
exports.StoreGetProductsParams = StoreGetProductsParams;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-products.js","sourceRoot":"","sources":["../../../../../src/api/routes/store/products/list-products.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"list-products.js","sourceRoot":"","sources":["../../../../../src/api/routes/store/products/list-products.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uDAAmD;AACnD,mDAOwB;AACxB,iCAAqC;AACrC,sBAAiD;AAEjD,mDAAiE;AACjE,yDAAuD;AACvD,gEAA6D;AAC7D,sEAA+E;AAE/E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,mBAAe,UAAO,GAAG,EAAE,GAAG;;;;;gBACtB,cAAc,GAAmB,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,gBAAgB,CAAC,CAAA;gBAExD,qBAAM,IAAA,qBAAS,EAAC,sBAAsB,EAAE,GAAG,CAAC,KAAK,CAAC,EAAA;;gBAA9D,SAAS,GAAG,SAAkD;gBAE9D,gBAAgB,GAA2B,IAAA,aAAI,EAAC,SAAS,EAAE;oBAC/D,QAAQ;oBACR,QAAQ;oBACR,OAAO;oBACP,QAAQ;iBACT,CAAC,CAAA;gBAEF,iDAAiD;gBACjD,gBAAgB,CAAC,QAAQ,CAAC,GAAG,CAAC,WAAW,CAAC,CAAA;gBAEtC,aAAa,GAAa,EAAE,CAAA;gBAChC,IAAI,SAAS,CAAC,MAAM,EAAE;oBACd,GAAG,GAAG,IAAI,GAAG,CAAC,SAAS,CAAC,MAAM,CAAC,KAAK,CAAC,G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,GAAE;QACZ,IAAA,gCAAc,GAAE;QAChB,IAAA,wBAAI,EAAC,cAAM,OAAA,+BAAsB,EAAtB,CAAsB,CAAC;kCACtB,+BAAsB;8DAAA;IACrC,6BAAC;CAAA,AA/CD,CAA4C,gCAAgC,GA+C3E;AA/CY,wDAAsB"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { DateComparisonOperator } from "../../../../types/common";
|
|
1
2
|
declare const _default: (req: any, res: any) => Promise<void>;
|
|
2
3
|
/**
|
|
3
4
|
* @oas [get] /regions
|
|
@@ -31,4 +32,6 @@ export default _default;
|
|
|
31
32
|
export declare class StoreGetRegionsParams {
|
|
32
33
|
limit?: number;
|
|
33
34
|
offset?: number;
|
|
35
|
+
created_at?: DateComparisonOperator;
|
|
36
|
+
updated_at?: DateComparisonOperator;
|
|
34
37
|
}
|
|
@@ -47,8 +47,10 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
47
47
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48
48
|
exports.StoreGetRegionsParams = void 0;
|
|
49
49
|
var class_transformer_1 = require("class-transformer");
|
|
50
|
+
var lodash_1 = require("lodash");
|
|
50
51
|
var class_validator_1 = require("class-validator");
|
|
51
52
|
var validator_1 = require("../../../../utils/validator");
|
|
53
|
+
var common_1 = require("../../../../types/common");
|
|
52
54
|
/**
|
|
53
55
|
* @oas [get] /regions
|
|
54
56
|
* operationId: GetRegions
|
|
@@ -78,22 +80,23 @@ var validator_1 = require("../../../../utils/validator");
|
|
|
78
80
|
* $ref: "#/components/schemas/region"
|
|
79
81
|
*/
|
|
80
82
|
exports.default = (function (req, res) { return __awaiter(void 0, void 0, void 0, function () {
|
|
81
|
-
var
|
|
82
|
-
return __generator(this, function (
|
|
83
|
-
switch (
|
|
83
|
+
var validated, limit, offset, regionService, filterableFields, listConfig, regions;
|
|
84
|
+
return __generator(this, function (_a) {
|
|
85
|
+
switch (_a.label) {
|
|
84
86
|
case 0: return [4 /*yield*/, (0, validator_1.validator)(StoreGetRegionsParams, req.query)];
|
|
85
87
|
case 1:
|
|
86
|
-
|
|
88
|
+
validated = _a.sent();
|
|
89
|
+
limit = validated.limit, offset = validated.offset;
|
|
87
90
|
regionService = req.scope.resolve("regionService");
|
|
88
|
-
|
|
91
|
+
filterableFields = (0, lodash_1.omit)(validated, ["limit", "offset"]);
|
|
89
92
|
listConfig = {
|
|
90
93
|
relations: ["countries", "payment_providers", "fulfillment_providers"],
|
|
91
94
|
skip: offset,
|
|
92
95
|
take: limit,
|
|
93
96
|
};
|
|
94
|
-
return [4 /*yield*/, regionService.list(
|
|
97
|
+
return [4 /*yield*/, regionService.list(filterableFields, listConfig)];
|
|
95
98
|
case 2:
|
|
96
|
-
regions =
|
|
99
|
+
regions = _a.sent();
|
|
97
100
|
res.json({ regions: regions });
|
|
98
101
|
return [2 /*return*/];
|
|
99
102
|
}
|
|
@@ -116,6 +119,18 @@ var StoreGetRegionsParams = /** @class */ (function () {
|
|
|
116
119
|
(0, class_transformer_1.Type)(function () { return Number; }),
|
|
117
120
|
__metadata("design:type", Number)
|
|
118
121
|
], StoreGetRegionsParams.prototype, "offset", void 0);
|
|
122
|
+
__decorate([
|
|
123
|
+
(0, class_validator_1.IsOptional)(),
|
|
124
|
+
(0, class_validator_1.ValidateNested)(),
|
|
125
|
+
(0, class_transformer_1.Type)(function () { return common_1.DateComparisonOperator; }),
|
|
126
|
+
__metadata("design:type", common_1.DateComparisonOperator)
|
|
127
|
+
], StoreGetRegionsParams.prototype, "created_at", void 0);
|
|
128
|
+
__decorate([
|
|
129
|
+
(0, class_validator_1.IsOptional)(),
|
|
130
|
+
(0, class_validator_1.ValidateNested)(),
|
|
131
|
+
(0, class_transformer_1.Type)(function () { return common_1.DateComparisonOperator; }),
|
|
132
|
+
__metadata("design:type", common_1.DateComparisonOperator)
|
|
133
|
+
], StoreGetRegionsParams.prototype, "updated_at", void 0);
|
|
119
134
|
return StoreGetRegionsParams;
|
|
120
135
|
}());
|
|
121
136
|
exports.StoreGetRegionsParams = StoreGetRegionsParams;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-regions.js","sourceRoot":"","sources":["../../../../../src/api/routes/store/regions/list-regions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uDAAwC;AACxC,
|
|
1
|
+
{"version":3,"file":"list-regions.js","sourceRoot":"","sources":["../../../../../src/api/routes/store/regions/list-regions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uDAAwC;AACxC,iCAA6B;AAC7B,mDAAmE;AAEnE,yDAAuD;AACvD,mDAAiE;AAEjE;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,mBAAe,UAAO,GAAG,EAAE,GAAG;;;;oBACV,qBAAM,IAAA,qBAAS,EAAC,qBAAqB,EAAE,GAAG,CAAC,KAAK,CAAC,EAAA;;gBAA7D,SAAS,GAAG,SAAiD;gBAC3D,KAAK,GAAa,SAAS,MAAtB,EAAE,MAAM,GAAK,SAAS,OAAd,CAAc;gBAE7B,aAAa,GAAkB,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,eAAe,CAAC,CAAA;gBAEjE,gBAAgB,GAAG,IAAA,aAAI,EAAC,SAAS,EAAE,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAA;gBAEvD,UAAU,GAAG;oBACjB,SAAS,EAAE,CAAC,WAAW,EAAE,mBAAmB,EAAE,uBAAuB,CAAC;oBACtE,IAAI,EAAE,MAAM;oBACZ,IAAI,EAAE,KAAK;iBACZ,CAAA;gBAEe,qBAAM,aAAa,CAAC,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC,EAAA;;gBAAhE,OAAO,GAAG,SAAsD;gBAEtE,GAAG,CAAC,IAAI,CAAC,EAAE,OAAO,SAAA,EAAE,CAAC,CAAA;;;;KACtB,EAAA;AAED;IAAA;QAIE,UAAK,GAAY,GAAG,CAAA;QAKpB,WAAM,GAAY,CAAC,CAAA;IAWrB,CAAC;IAhBC;QAHC,IAAA,4BAAU,GAAE;QACZ,IAAA,uBAAK,GAAE;QACP,IAAA,wBAAI,EAAC,cAAM,OAAA,MAAM,EAAN,CAAM,CAAC;;wDACC;IAKpB;QAHC,IAAA,4BAAU,GAAE;QACZ,IAAA,uBAAK,GAAE;QACP,IAAA,wBAAI,EAAC,cAAM,OAAA,MAAM,EAAN,CAAM,CAAC;;yDACA;IAKnB;QAHC,IAAA,4BAAU,GAAE;QACZ,IAAA,gCAAc,GAAE;QAChB,IAAA,wBAAI,EAAC,cAAM,OAAA,+BAAsB,EAAtB,CAAsB,CAAC;kCACtB,+BAAsB;6DAAA;IAKnC;QAHC,IAAA,4BAAU,GAAE;QACZ,IAAA,gCAAc,GAAE;QAChB,IAAA,wBAAI,EAAC,cAAM,OAAA,+BAAsB,EAAtB,CAAsB,CAAC;kCACtB,+BAAsB;6DAAA;IACrC,4BAAC;CAAA,AApBD,IAoBC;AApBY,sDAAqB"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { NumericalComparisonOperator } from "../../../../types/common";
|
|
1
2
|
declare const _default: (req: any, res: any) => Promise<void>;
|
|
2
3
|
/**
|
|
3
4
|
* @oas [get] /variants
|
|
@@ -29,4 +30,7 @@ export declare class StoreGetVariantsParams {
|
|
|
29
30
|
offset?: number;
|
|
30
31
|
expand?: string;
|
|
31
32
|
ids?: string;
|
|
33
|
+
id?: string | string[];
|
|
34
|
+
title?: string | string[];
|
|
35
|
+
inventory_quantity?: number | NumericalComparisonOperator;
|
|
32
36
|
}
|
|
@@ -47,9 +47,12 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
47
47
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48
48
|
exports.StoreGetVariantsParams = void 0;
|
|
49
49
|
var class_transformer_1 = require("class-transformer");
|
|
50
|
+
var lodash_1 = require("lodash");
|
|
50
51
|
var class_validator_1 = require("class-validator");
|
|
51
52
|
var _1 = require(".");
|
|
52
53
|
var validator_1 = require("../../../../utils/validator");
|
|
54
|
+
var is_type_1 = require("../../../../utils/validators/is-type");
|
|
55
|
+
var common_1 = require("../../../../types/common");
|
|
53
56
|
/**
|
|
54
57
|
* @oas [get] /variants
|
|
55
58
|
* operationId: GetVariants
|
|
@@ -75,17 +78,17 @@ var validator_1 = require("../../../../utils/validator");
|
|
|
75
78
|
* $ref: "#/components/schemas/product_variant"
|
|
76
79
|
*/
|
|
77
80
|
exports.default = (function (req, res) { return __awaiter(void 0, void 0, void 0, function () {
|
|
78
|
-
var
|
|
79
|
-
return __generator(this, function (
|
|
80
|
-
switch (
|
|
81
|
+
var validated, expand, offset, limit, expandFields, listConfig, filterableFields, variantService, variants;
|
|
82
|
+
return __generator(this, function (_a) {
|
|
83
|
+
switch (_a.label) {
|
|
81
84
|
case 0: return [4 /*yield*/, (0, validator_1.validator)(StoreGetVariantsParams, req.query)];
|
|
82
85
|
case 1:
|
|
83
|
-
|
|
86
|
+
validated = _a.sent();
|
|
87
|
+
expand = validated.expand, offset = validated.offset, limit = validated.limit;
|
|
84
88
|
expandFields = [];
|
|
85
89
|
if (expand) {
|
|
86
90
|
expandFields = expand.split(",");
|
|
87
91
|
}
|
|
88
|
-
selector = {};
|
|
89
92
|
listConfig = {
|
|
90
93
|
relations: expandFields.length
|
|
91
94
|
? expandFields
|
|
@@ -93,13 +96,19 @@ exports.default = (function (req, res) { return __awaiter(void 0, void 0, void 0
|
|
|
93
96
|
skip: offset,
|
|
94
97
|
take: limit,
|
|
95
98
|
};
|
|
96
|
-
|
|
97
|
-
|
|
99
|
+
filterableFields = (0, lodash_1.omit)(validated, [
|
|
100
|
+
"ids",
|
|
101
|
+
"limit",
|
|
102
|
+
"offset",
|
|
103
|
+
"expand",
|
|
104
|
+
]);
|
|
105
|
+
if (validated.ids) {
|
|
106
|
+
filterableFields.id = validated.ids.split(",");
|
|
98
107
|
}
|
|
99
108
|
variantService = req.scope.resolve("productVariantService");
|
|
100
|
-
return [4 /*yield*/, variantService.list(
|
|
109
|
+
return [4 /*yield*/, variantService.list(filterableFields, listConfig)];
|
|
101
110
|
case 2:
|
|
102
|
-
variants =
|
|
111
|
+
variants = _a.sent();
|
|
103
112
|
res.json({ variants: variants });
|
|
104
113
|
return [2 /*return*/];
|
|
105
114
|
}
|
|
@@ -132,6 +141,21 @@ var StoreGetVariantsParams = /** @class */ (function () {
|
|
|
132
141
|
(0, class_validator_1.IsString)(),
|
|
133
142
|
__metadata("design:type", String)
|
|
134
143
|
], StoreGetVariantsParams.prototype, "ids", void 0);
|
|
144
|
+
__decorate([
|
|
145
|
+
(0, class_validator_1.IsOptional)(),
|
|
146
|
+
(0, is_type_1.IsType)([String, [String]]),
|
|
147
|
+
__metadata("design:type", Object)
|
|
148
|
+
], StoreGetVariantsParams.prototype, "id", void 0);
|
|
149
|
+
__decorate([
|
|
150
|
+
(0, class_validator_1.IsOptional)(),
|
|
151
|
+
(0, is_type_1.IsType)([String, [String]]),
|
|
152
|
+
__metadata("design:type", Object)
|
|
153
|
+
], StoreGetVariantsParams.prototype, "title", void 0);
|
|
154
|
+
__decorate([
|
|
155
|
+
(0, class_validator_1.IsOptional)(),
|
|
156
|
+
(0, is_type_1.IsType)([Number, common_1.NumericalComparisonOperator]),
|
|
157
|
+
__metadata("design:type", Object)
|
|
158
|
+
], StoreGetVariantsParams.prototype, "inventory_quantity", void 0);
|
|
135
159
|
return StoreGetVariantsParams;
|
|
136
160
|
}());
|
|
137
161
|
exports.StoreGetVariantsParams = StoreGetVariantsParams;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-variants.js","sourceRoot":"","sources":["../../../../../src/api/routes/store/variants/list-variants.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uDAAwC;AACxC,mDAA6D;AAC7D,sBAAgD;
|
|
1
|
+
{"version":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gBAAlE,QAAQ,GAAG,SAAuD;gBAExE,GAAG,CAAC,IAAI,CAAC,EAAE,QAAQ,UAAA,EAAE,CAAC,CAAA;;;;KACvB,EAAA;AAED;IAAA;QAIE,UAAK,GAAY,GAAG,CAAA;QAKpB,WAAM,GAAY,CAAC,CAAA;IAqBrB,CAAC;IA1BC;QAHC,IAAA,4BAAU,GAAE;QACZ,IAAA,uBAAK,GAAE;QACP,IAAA,wBAAI,EAAC,cAAM,OAAA,MAAM,EAAN,CAAM,CAAC;;yDACC;IAKpB;QAHC,IAAA,4BAAU,GAAE;QACZ,IAAA,uBAAK,GAAE;QACP,IAAA,wBAAI,EAAC,cAAM,OAAA,MAAM,EAAN,CAAM,CAAC;;0DACA;IAInB;QAFC,IAAA,4BAAU,GAAE;QACZ,IAAA,0BAAQ,GAAE;;0DACI;IAIf;QAFC,IAAA,4BAAU,GAAE;QACZ,IAAA,0BAAQ,GAAE;;uDACC;IAIZ;QAFC,IAAA,4BAAU,GAAE;QACZ,IAAA,gBAAM,EAAC,CAAC,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;;sDACL;IAItB;QAFC,IAAA,4BAAU,GAAE;QACZ,IAAA,gBAAM,EAAC,CAAC,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;;yDACF;IAIzB;QAFC,IAAA,4BAAU,GAAE;QACZ,IAAA,gBAAM,EAAC,CAAC,MAAM,EAAE,oCAA2B,CAAC,CAAC;;sEACW;IAC3D,6BAAC;CAAA,AA9BD,IA8BC;AA9BY,wDAAsB"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
var list_customers_1 = __importDefault(require("./list-customers"));
|
|
7
|
+
exports.default = { listAndCount: list_customers_1.default };
|
|
8
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/controllers/customers/index.ts"],"names":[],"mappings":";;;;;AAAA,oEAA2C;AAC3C,kBAAe,EAAE,YAAY,0BAAA,EAAE,CAAA"}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
12
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
13
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
14
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
15
|
+
function step(op) {
|
|
16
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
17
|
+
while (_) try {
|
|
18
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
19
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
20
|
+
switch (op[0]) {
|
|
21
|
+
case 0: case 1: t = op; break;
|
|
22
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
23
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
24
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
25
|
+
default:
|
|
26
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
27
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
28
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
29
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
30
|
+
if (t[2]) _.ops.pop();
|
|
31
|
+
_.trys.pop(); continue;
|
|
32
|
+
}
|
|
33
|
+
op = body.call(thisArg, _);
|
|
34
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
35
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
39
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
40
|
+
if (!m) return o;
|
|
41
|
+
var i = m.call(o), r, ar = [], e;
|
|
42
|
+
try {
|
|
43
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
44
|
+
}
|
|
45
|
+
catch (error) { e = { error: error }; }
|
|
46
|
+
finally {
|
|
47
|
+
try {
|
|
48
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
49
|
+
}
|
|
50
|
+
finally { if (e) throw e.error; }
|
|
51
|
+
}
|
|
52
|
+
return ar;
|
|
53
|
+
};
|
|
54
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
55
|
+
var lodash_1 = require("lodash");
|
|
56
|
+
var list_customers_1 = require("../../api/routes/admin/customers/list-customers");
|
|
57
|
+
var validator_1 = require("../../utils/validator");
|
|
58
|
+
var listAndCount = function (scope, query, body, context) {
|
|
59
|
+
if (context === void 0) { context = {}; }
|
|
60
|
+
return __awaiter(void 0, void 0, void 0, function () {
|
|
61
|
+
var validatedQueryParams, customerService, expandFields, listConfig, filterableFields, _a, customers, count;
|
|
62
|
+
return __generator(this, function (_b) {
|
|
63
|
+
switch (_b.label) {
|
|
64
|
+
case 0: return [4 /*yield*/, (0, validator_1.validator)(list_customers_1.AdminGetCustomersParams, query)];
|
|
65
|
+
case 1:
|
|
66
|
+
validatedQueryParams = _b.sent();
|
|
67
|
+
customerService = scope.resolve("customerService");
|
|
68
|
+
expandFields = [];
|
|
69
|
+
if (validatedQueryParams.expand) {
|
|
70
|
+
expandFields = validatedQueryParams.expand.split(",");
|
|
71
|
+
}
|
|
72
|
+
listConfig = {
|
|
73
|
+
relations: expandFields,
|
|
74
|
+
skip: validatedQueryParams.offset,
|
|
75
|
+
take: validatedQueryParams.limit,
|
|
76
|
+
};
|
|
77
|
+
filterableFields = (0, lodash_1.omit)(validatedQueryParams, [
|
|
78
|
+
"limit",
|
|
79
|
+
"offset",
|
|
80
|
+
"expand",
|
|
81
|
+
]);
|
|
82
|
+
return [4 /*yield*/, customerService.listAndCount((0, lodash_1.pickBy)(filterableFields, function (val) { return typeof val !== "undefined"; }), listConfig)];
|
|
83
|
+
case 2:
|
|
84
|
+
_a = __read.apply(void 0, [_b.sent(), 2]), customers = _a[0], count = _a[1];
|
|
85
|
+
return [2 /*return*/, {
|
|
86
|
+
customers: customers,
|
|
87
|
+
count: count,
|
|
88
|
+
offset: validatedQueryParams.offset,
|
|
89
|
+
limit: validatedQueryParams.limit,
|
|
90
|
+
}];
|
|
91
|
+
}
|
|
92
|
+
});
|
|
93
|
+
});
|
|
94
|
+
};
|
|
95
|
+
exports.default = listAndCount;
|
|
96
|
+
//# sourceMappingURL=list-customers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-customers.js","sourceRoot":"","sources":["../../../src/controllers/customers/list-customers.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d.ts
CHANGED
|
@@ -37,6 +37,7 @@ export * from "./models/order";
|
|
|
37
37
|
export * from "./models/payment";
|
|
38
38
|
export * from "./models/payment-provider";
|
|
39
39
|
export * from "./models/payment-session";
|
|
40
|
+
export * from "./models/price-list";
|
|
40
41
|
export * from "./models/product";
|
|
41
42
|
export * from "./models/product-collection";
|
|
42
43
|
export * from "./models/product-option";
|
package/dist/index.js
CHANGED
|
@@ -52,6 +52,7 @@ __exportStar(require("./models/order"), exports);
|
|
|
52
52
|
__exportStar(require("./models/payment"), exports);
|
|
53
53
|
__exportStar(require("./models/payment-provider"), exports);
|
|
54
54
|
__exportStar(require("./models/payment-session"), exports);
|
|
55
|
+
__exportStar(require("./models/price-list"), exports);
|
|
55
56
|
__exportStar(require("./models/product"), exports);
|
|
56
57
|
__exportStar(require("./models/product-collection"), exports);
|
|
57
58
|
__exportStar(require("./models/product-option"), exports);
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.js"],"names":[],"mappings":";;;;;;;;;;;;AAAA,eAAe;AACf,wCAAqB;AAErB,aAAa;AACb,+CAA4B;AAE5B,SAAS;AACT,6DAA0C;AAC1C,4DAAyC;AACzC,iEAA8C;AAC9C,oDAAiC;AACjC,oEAAiD;AACjD,8DAA2C;AAC3C,mDAAgC;AAChC,gDAA6B;AAC7B,uDAAoC;AACpC,sDAAmC;AACnC,uDAAoC;AACpC,qDAAkC;AAClC,mDAAgC;AAChC,oDAAiC;AACjC,kEAA+C;AAC/C,oDAAiC;AACjC,0DAAuC;AACvC,oDAAiC;AACjC,yDAAsC;AACtC,uDAAoC;AACpC,uDAAoC;AACpC,4DAAyC;AACzC,gEAA6C;AAC7C,qDAAkC;AAClC,iEAA8C;AAC9C,2DAAwC;AACxC,iDAA8B;AAC9B,kDAA+B;AAC/B,qDAAkC;AAClC,wDAAqC;AACrC,gDAA6B;AAC7B,wDAAqC;AACrC,iDAA8B;AAC9B,iDAA8B;AAC9B,mDAAgC;AAChC,4DAAyC;AACzC,2DAAwC;AACxC,mDAAgC;AAChC,8DAA2C;AAC3C,0DAAuC;AACvC,gEAA6C;AAC7C,uDAAoC;AACpC,wDAAqC;AACrC,2DAAwC;AACxC,kDAA+B;AAC/B,kDAA+B;AAC/B,kDAA+B;AAC/B,uDAAoC;AACpC,yDAAsC;AACtC,2DAAwC;AACxC,2DAAwC;AACxC,uEAAoD;AACpD,4DAAyC;AACzC,sDAAmC;AACnC,iDAA8B;AAC9B,gDAA6B;AAC7B,gDAA6B;AAC7B,wDAAqC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.js"],"names":[],"mappings":";;;;;;;;;;;;AAAA,eAAe;AACf,wCAAqB;AAErB,aAAa;AACb,+CAA4B;AAE5B,SAAS;AACT,6DAA0C;AAC1C,4DAAyC;AACzC,iEAA8C;AAC9C,oDAAiC;AACjC,oEAAiD;AACjD,8DAA2C;AAC3C,mDAAgC;AAChC,gDAA6B;AAC7B,uDAAoC;AACpC,sDAAmC;AACnC,uDAAoC;AACpC,qDAAkC;AAClC,mDAAgC;AAChC,oDAAiC;AACjC,kEAA+C;AAC/C,oDAAiC;AACjC,0DAAuC;AACvC,oDAAiC;AACjC,yDAAsC;AACtC,uDAAoC;AACpC,uDAAoC;AACpC,4DAAyC;AACzC,gEAA6C;AAC7C,qDAAkC;AAClC,iEAA8C;AAC9C,2DAAwC;AACxC,iDAA8B;AAC9B,kDAA+B;AAC/B,qDAAkC;AAClC,wDAAqC;AACrC,gDAA6B;AAC7B,wDAAqC;AACrC,iDAA8B;AAC9B,iDAA8B;AAC9B,mDAAgC;AAChC,4DAAyC;AACzC,2DAAwC;AACxC,sDAAmC;AACnC,mDAAgC;AAChC,8DAA2C;AAC3C,0DAAuC;AACvC,gEAA6C;AAC7C,uDAAoC;AACpC,wDAAqC;AACrC,2DAAwC;AACxC,kDAA+B;AAC/B,kDAA+B;AAC/B,kDAA+B;AAC/B,uDAAoC;AACpC,yDAAsC;AACtC,2DAAwC;AACxC,2DAAwC;AACxC,uEAAoD;AACpD,4DAAyC;AACzC,sDAAmC;AACnC,iDAA8B;AAC9B,gDAA6B;AAC7B,gDAA6B;AAC7B,wDAAqC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { MigrationInterface, QueryRunner } from "typeorm";
|
|
2
|
+
export declare class updateMoneyAmountAddPriceList1646915480108 implements MigrationInterface {
|
|
3
|
+
name: string;
|
|
4
|
+
up(queryRunner: QueryRunner): Promise<void>;
|
|
5
|
+
down(queryRunner: QueryRunner): Promise<void>;
|
|
6
|
+
}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
12
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
13
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
14
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
15
|
+
function step(op) {
|
|
16
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
17
|
+
while (_) try {
|
|
18
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
19
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
20
|
+
switch (op[0]) {
|
|
21
|
+
case 0: case 1: t = op; break;
|
|
22
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
23
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
24
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
25
|
+
default:
|
|
26
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
27
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
28
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
29
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
30
|
+
if (t[2]) _.ops.pop();
|
|
31
|
+
_.trys.pop(); continue;
|
|
32
|
+
}
|
|
33
|
+
op = body.call(thisArg, _);
|
|
34
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
35
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
+
exports.updateMoneyAmountAddPriceList1646915480108 = void 0;
|
|
40
|
+
var updateMoneyAmountAddPriceList1646915480108 = /** @class */ (function () {
|
|
41
|
+
function updateMoneyAmountAddPriceList1646915480108() {
|
|
42
|
+
this.name = 'updateMoneyAmountAddPriceList1646915480108';
|
|
43
|
+
}
|
|
44
|
+
updateMoneyAmountAddPriceList1646915480108.prototype.up = function (queryRunner) {
|
|
45
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
46
|
+
return __generator(this, function (_a) {
|
|
47
|
+
switch (_a.label) {
|
|
48
|
+
case 0: return [4 /*yield*/, queryRunner.query("CREATE TYPE \"price_list_type_enum\" AS ENUM('sale', 'override')")];
|
|
49
|
+
case 1:
|
|
50
|
+
_a.sent();
|
|
51
|
+
return [4 /*yield*/, queryRunner.query("CREATE TYPE \"price_list_status_enum\" AS ENUM('active', 'draft')")];
|
|
52
|
+
case 2:
|
|
53
|
+
_a.sent();
|
|
54
|
+
return [4 /*yield*/, queryRunner.query("CREATE TABLE \"price_list\" (\"id\" character varying NOT NULL, \"name\" character varying NOT NULL, \"description\" character varying NOT NULL, \"type\" \"price_list_type_enum\" NOT NULL DEFAULT 'sale', \"status\" \"price_list_status_enum\" NOT NULL DEFAULT 'draft', \"starts_at\" TIMESTAMP WITH TIME ZONE, \"ends_at\" TIMESTAMP WITH TIME ZONE, \"created_at\" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT now(), \"updated_at\" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT now(), \"deleted_at\" TIMESTAMP WITH TIME ZONE, CONSTRAINT \"PK_52ea7826468b1c889cb2c28df03\" PRIMARY KEY (\"id\"))")];
|
|
55
|
+
case 3:
|
|
56
|
+
_a.sent();
|
|
57
|
+
return [4 /*yield*/, queryRunner.query("CREATE TABLE \"price_list_customer_groups\" (\"price_list_id\" character varying NOT NULL, \"customer_group_id\" character varying NOT NULL, CONSTRAINT \"PK_1afcbe15cc8782dc80c05707df9\" PRIMARY KEY (\"price_list_id\", \"customer_group_id\"))")];
|
|
58
|
+
case 4:
|
|
59
|
+
_a.sent();
|
|
60
|
+
return [4 /*yield*/, queryRunner.query("CREATE INDEX \"IDX_52875734e9dd69064f0041f4d9\" ON \"price_list_customer_groups\" (\"price_list_id\") ")];
|
|
61
|
+
case 5:
|
|
62
|
+
_a.sent();
|
|
63
|
+
return [4 /*yield*/, queryRunner.query("CREATE INDEX \"IDX_c5516f550433c9b1c2630d787a\" ON \"price_list_customer_groups\" (\"customer_group_id\") ")];
|
|
64
|
+
case 6:
|
|
65
|
+
_a.sent();
|
|
66
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" DROP COLUMN \"sale_amount\"")];
|
|
67
|
+
case 7:
|
|
68
|
+
_a.sent();
|
|
69
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" ADD \"min_quantity\" integer")];
|
|
70
|
+
case 8:
|
|
71
|
+
_a.sent();
|
|
72
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" ADD \"max_quantity\" integer")];
|
|
73
|
+
case 9:
|
|
74
|
+
_a.sent();
|
|
75
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" ADD \"price_list_id\" character varying")];
|
|
76
|
+
case 10:
|
|
77
|
+
_a.sent();
|
|
78
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" ADD CONSTRAINT \"FK_f249976b079375499662eb80c40\" FOREIGN KEY (\"price_list_id\") REFERENCES \"price_list\"(\"id\") ON DELETE CASCADE ON UPDATE NO ACTION")];
|
|
79
|
+
case 11:
|
|
80
|
+
_a.sent();
|
|
81
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"price_list_customer_groups\" ADD CONSTRAINT \"FK_52875734e9dd69064f0041f4d92\" FOREIGN KEY (\"price_list_id\") REFERENCES \"price_list\"(\"id\") ON DELETE CASCADE ON UPDATE CASCADE")];
|
|
82
|
+
case 12:
|
|
83
|
+
_a.sent();
|
|
84
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"price_list_customer_groups\" ADD CONSTRAINT \"FK_c5516f550433c9b1c2630d787a7\" FOREIGN KEY (\"customer_group_id\") REFERENCES \"customer_group\"(\"id\") ON DELETE CASCADE ON UPDATE NO ACTION")];
|
|
85
|
+
case 13:
|
|
86
|
+
_a.sent();
|
|
87
|
+
return [2 /*return*/];
|
|
88
|
+
}
|
|
89
|
+
});
|
|
90
|
+
});
|
|
91
|
+
};
|
|
92
|
+
updateMoneyAmountAddPriceList1646915480108.prototype.down = function (queryRunner) {
|
|
93
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
94
|
+
return __generator(this, function (_a) {
|
|
95
|
+
switch (_a.label) {
|
|
96
|
+
case 0: return [4 /*yield*/, queryRunner.query("ALTER TABLE \"price_list_customer_groups\" DROP CONSTRAINT \"FK_c5516f550433c9b1c2630d787a7\"")];
|
|
97
|
+
case 1:
|
|
98
|
+
_a.sent();
|
|
99
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"price_list_customer_groups\" DROP CONSTRAINT \"FK_52875734e9dd69064f0041f4d92\"")];
|
|
100
|
+
case 2:
|
|
101
|
+
_a.sent();
|
|
102
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" DROP CONSTRAINT \"FK_f249976b079375499662eb80c40\"")];
|
|
103
|
+
case 3:
|
|
104
|
+
_a.sent();
|
|
105
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" DROP COLUMN \"price_list_id\"")];
|
|
106
|
+
case 4:
|
|
107
|
+
_a.sent();
|
|
108
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" DROP COLUMN \"max_quantity\"")];
|
|
109
|
+
case 5:
|
|
110
|
+
_a.sent();
|
|
111
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" DROP COLUMN \"min_quantity\"")];
|
|
112
|
+
case 6:
|
|
113
|
+
_a.sent();
|
|
114
|
+
return [4 /*yield*/, queryRunner.query("ALTER TABLE \"money_amount\" ADD \"sale_amount\" integer")];
|
|
115
|
+
case 7:
|
|
116
|
+
_a.sent();
|
|
117
|
+
return [4 /*yield*/, queryRunner.query("DROP INDEX \"IDX_c5516f550433c9b1c2630d787a\"")];
|
|
118
|
+
case 8:
|
|
119
|
+
_a.sent();
|
|
120
|
+
return [4 /*yield*/, queryRunner.query("DROP INDEX \"IDX_52875734e9dd69064f0041f4d9\"")];
|
|
121
|
+
case 9:
|
|
122
|
+
_a.sent();
|
|
123
|
+
return [4 /*yield*/, queryRunner.query("DROP TABLE \"price_list_customer_groups\"")];
|
|
124
|
+
case 10:
|
|
125
|
+
_a.sent();
|
|
126
|
+
return [4 /*yield*/, queryRunner.query("DROP TABLE \"price_list\"")];
|
|
127
|
+
case 11:
|
|
128
|
+
_a.sent();
|
|
129
|
+
return [4 /*yield*/, queryRunner.query("DROP TYPE \"price_list_status_enum\"")];
|
|
130
|
+
case 12:
|
|
131
|
+
_a.sent();
|
|
132
|
+
return [4 /*yield*/, queryRunner.query("DROP TYPE \"price_list_type_enum\"")];
|
|
133
|
+
case 13:
|
|
134
|
+
_a.sent();
|
|
135
|
+
return [2 /*return*/];
|
|
136
|
+
}
|
|
137
|
+
});
|
|
138
|
+
});
|
|
139
|
+
};
|
|
140
|
+
return updateMoneyAmountAddPriceList1646915480108;
|
|
141
|
+
}());
|
|
142
|
+
exports.updateMoneyAmountAddPriceList1646915480108 = updateMoneyAmountAddPriceList1646915480108;
|
|
143
|
+
//# sourceMappingURL=1646915480108-update_money_amount_add_price_list.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"1646915480108-update_money_amount_add_price_list.js","sourceRoot":"","sources":["../../src/migrations/1646915480108-update_money_amount_add_price_list.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA;IAAA;QACI,SAAI,GAAG,4CAA4C,CAAA;IAkCvD,CAAC;IAhCgB,uDAAE,GAAf,UAAgB,WAAwB;;;;4BACpC,qBAAM,WAAW,CAAC,KAAK,CAAC,kEAAgE,CAAC,EAAA;;wBAAzF,SAAyF,CAAC;wBAC1F,qBAAM,WAAW,CAAC,KAAK,CAAC,mEAAiE,CAAC,EAAA;;wBAA1F,SAA0F,CAAC;wBAC3F,qBAAM,WAAW,CAAC,KAAK,CAAC,wkBAA0iB,CAAC,EAAA;;wBAAnkB,SAAmkB,CAAC;wBACpkB,qBAAM,WAAW,CAAC,KAAK,CAAC,oPAA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