@sgftech/medusa-plugin-marketplace-v2 0.2.32 → 0.2.33

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.js CHANGED
@@ -1,60 +1,14 @@
1
1
  "use strict";
2
- var __extends = (this && this.__extends) || (function () {
3
- var extendStatics = function (d, b) {
4
- extendStatics = Object.setPrototypeOf ||
5
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
- return extendStatics(d, b);
8
- };
9
- return function (d, b) {
10
- if (typeof b !== "function" && b !== null)
11
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
- extendStatics(d, b);
13
- function __() { this.constructor = d; }
14
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
- };
16
- })();
17
- var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
18
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
19
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
20
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
21
- return c > 3 && r && Object.defineProperty(target, key, r), r;
22
- };
23
- var __metadata = (this && this.__metadata) || function (k, v) {
24
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
25
- };
26
- Object.defineProperty(exports, "__esModule", { value: true });
27
2
  /* eslint-disable new-cap */
28
- var create_product_1 = require("@medusajs/medusa/dist/api/routes/admin/products/create-product");
29
- var update_product_1 = require("@medusajs/medusa/dist/api/routes/admin/products/update-product");
30
- var class_validator_1 = require("class-validator");
3
+ Object.defineProperty(exports, "__esModule", { value: true });
31
4
  var medusa_1 = require("@medusajs/medusa");
32
- var AdminPostProductsReq = /** @class */ (function (_super) {
33
- __extends(AdminPostProductsReq, _super);
34
- function AdminPostProductsReq() {
35
- return _super !== null && _super.apply(this, arguments) || this;
36
- }
37
- __decorate([
38
- (0, class_validator_1.IsString)({ each: true }),
39
- (0, class_validator_1.ArrayMaxSize)(10),
40
- (0, class_validator_1.IsOptional)(),
41
- __metadata("design:type", Array)
42
- ], AdminPostProductsReq.prototype, "shipping_options", void 0);
43
- return AdminPostProductsReq;
44
- }(create_product_1.AdminPostProductsReq));
45
- var AdminPostProductsProductReq = /** @class */ (function (_super) {
46
- __extends(AdminPostProductsProductReq, _super);
47
- function AdminPostProductsProductReq() {
48
- return _super !== null && _super.apply(this, arguments) || this;
49
- }
50
- __decorate([
51
- (0, class_validator_1.IsString)({ each: true }),
52
- (0, class_validator_1.ArrayMaxSize)(10),
53
- (0, class_validator_1.IsOptional)(),
54
- __metadata("design:type", Array)
55
- ], AdminPostProductsProductReq.prototype, "shipping_options", void 0);
56
- return AdminPostProductsProductReq;
57
- }(update_product_1.AdminPostProductsProductReq));
58
- (0, medusa_1.registerOverriddenValidators)(AdminPostProductsReq);
59
- (0, medusa_1.registerOverriddenValidators)(AdminPostProductsProductReq);
5
+ var post_products_req_1 = require("./validators/admin/post-products-req");
6
+ var get_products_req_1 = require("./validators/store/get-products-req");
7
+ var get_categories_req_1 = require("./validators/store/get-categories-req");
8
+ (0, medusa_1.registerOverriddenValidators)(post_products_req_1.AdminPostProductsReq);
9
+ (0, medusa_1.registerOverriddenValidators)(post_products_req_1.AdminPostProductsProductReq);
10
+ (0, medusa_1.registerOverriddenValidators)(get_products_req_1.StoreGetProductsParams);
11
+ (0, medusa_1.registerOverriddenValidators)(get_products_req_1.StoreGetProductsProductParams);
12
+ (0, medusa_1.registerOverriddenValidators)(get_categories_req_1.StoreGetProductCategoriesCategoryParams);
13
+ (0, medusa_1.registerOverriddenValidators)(get_categories_req_1.StoreGetProductCategoriesParams);
60
14
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/api/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4BAA4B;AAC5B,iGAAoI;AACpI,iGAAkJ;AAClJ,mDAAqE;AACrE,2CAAgE;AAEhE;IAAmC,wCAA0B;IAA7D;;IAKA,CAAC;IAJG;QAAC,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;QACxB,IAAA,8BAAY,EAAC,EAAE,CAAC;QAChB,IAAA,4BAAU,GAAE;;kEACe;IAChC,2BAAC;CAAA,AALD,CAAmC,qCAA0B,GAK5D;AAED;IAA0C,+CAAiC;IAA3E;;IAKA,CAAC;IAJG;QAAC,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;QACxB,IAAA,8BAAY,EAAC,EAAE,CAAC;QAChB,IAAA,4BAAU,GAAE;;yEACe;IAChC,kCAAC;CAAA,AALD,CAA0C,4CAAiC,GAK1E;AAED,IAAA,qCAA4B,EAAC,oBAAoB,CAAC,CAAC;AACnD,IAAA,qCAA4B,EAAC,2BAA2B,CAAC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/api/index.ts"],"names":[],"mappings":";AAAA,4BAA4B;;AAE5B,2CAAgE;AAChE,0EAG8C;AAC9C,wEAG6C;AAC7C,4EAG+C;AAC/C,IAAA,qCAA4B,EAAC,wCAAoB,CAAC,CAAC;AACnD,IAAA,qCAA4B,EAAC,+CAA2B,CAAC,CAAC;AAC1D,IAAA,qCAA4B,EAAC,yCAAsB,CAAC,CAAC;AACrD,IAAA,qCAA4B,EAAC,gDAA6B,CAAC,CAAC;AAC5D,IAAA,qCAA4B,EAAC,4DAAuC,CAAC,CAAC;AACtE,IAAA,qCAA4B,EAAC,oDAA+B,CAAC,CAAC"}
@@ -78,7 +78,7 @@ exports.config = {
78
78
  // registerLoggedInUser,
79
79
  // registerSuperAdmin,
80
80
  // registerActiveStore,
81
- // detachServiceAccountAdmin
81
+ // detachServiceAccountAdmin
82
82
  // ]
83
83
  // }
84
84
  ], false)
@@ -1 +1 @@
1
- {"version":3,"file":"middlewares.js","sourceRoot":"","sources":["../../src/api/middlewares.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAM0B;AAE1B,mFAAgF;AAChF,2GAI4D;AAC5D,+EAA4E;AAC/D,QAAA,0CAA0C,GAAG,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;AAEhF,IAAM,2BAA2B,GAAG,UAChC,GAAkB,EAClB,GAAmB,EACnB,IAAkB;;;QAEZ,MAAM,GAAG,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAW,CAAC;QACrD,MAAM,CAAC,IAAI,CAAC,qCAAqC,CAAC,CAAC;QACnD,IAAI,EAAE,CAAC;;;KACV,CAAC;AAEW,QAAA,MAAM,GAAsB;IACrC,MAAM,8DAEC,8DAAuB,SACvB,8EAAuC,SACvC,iDAAsB,CAAC,MAAM;QAChC;YACI,OAAO,EAAE,IAAI;YACb,WAAW,EAAE,CAAC,2BAA2B,CAAC;SAC7C;QACD;YACI,OAAO,EAAE,UAAU;YACnB,WAAW,EAAE,CAAC,IAAA,6BAAoB,GAAE,EAAE,6CAAoB,CAAC;SAC9D;QACD,6EAA6E;QAC7E,4CAA4C;QAC5C,8CAA8C;QAC9C,qBAAqB;QACrB,0BAA0B;QAC1B,gCAAgC;QAChC,8BAA8B;QAC9B,+BAA+B;QAC/B,qCAAqC;QACrC,QAAQ;QACR,IAAI;aACP;CACJ,CAAC;AACF,kBAAe,cAAM,CAAC"}
1
+ {"version":3,"file":"middlewares.js","sourceRoot":"","sources":["../../src/api/middlewares.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,2CAM0B;AAE1B,mFAAgF;AAChF,2GAI4D;AAC5D,+EAA4E;AAC/D,QAAA,0CAA0C,GAAG,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;AAEhF,IAAM,2BAA2B,GAAG,UAChC,GAAkB,EAClB,GAAmB,EACnB,IAAkB;;;QAEZ,MAAM,GAAG,GAAG,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAW,CAAC;QACrD,MAAM,CAAC,IAAI,CAAC,qCAAqC,CAAC,CAAC;QACnD,IAAI,EAAE,CAAC;;;KACV,CAAC;AAEW,QAAA,MAAM,GAAsB;IACrC,MAAM,8DAEC,8DAAuB,SACvB,8EAAuC,SACvC,iDAAsB,CAAC,MAAM;QAChC;YACI,OAAO,EAAE,IAAI;YACb,WAAW,EAAE,CAAC,2BAA2B,CAAC;SAC7C;QACD;YACI,OAAO,EAAE,UAAU;YACnB,WAAW,EAAE,CAAC,IAAA,6BAAoB,GAAE,EAAE,6CAAoB,CAAC;SAC9D;QACD,6EAA6E;QAC7E,4CAA4C;QAC5C,8CAA8C;QAC9C,qBAAqB;QACrB,0BAA0B;QAC1B,gCAAgC;QAChC,8BAA8B;QAC9B,+BAA+B;QAC/B,oCAAoC;QACpC,QAAQ;QACR,IAAI;aACP;CACJ,CAAC;AACF,kBAAe,cAAM,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { AdminPostProductsReq as MedusaAdminPostProductsReq } from "@medusajs/medusa/dist/api/routes/admin/products/create-product";
2
+ import { AdminPostProductsProductReq as MedusaAdminPostProductsProductReq } from "@medusajs/medusa/dist/api/routes/admin/products/update-product";
3
+ export declare class AdminPostProductsReq extends MedusaAdminPostProductsReq {
4
+ shipping_options?: string[];
5
+ }
6
+ export declare class AdminPostProductsProductReq extends MedusaAdminPostProductsProductReq {
7
+ shipping_options?: string[];
8
+ }
@@ -0,0 +1,60 @@
1
+ "use strict";
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
17
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
18
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
19
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
20
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
21
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
22
+ };
23
+ var __metadata = (this && this.__metadata) || function (k, v) {
24
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
25
+ };
26
+ Object.defineProperty(exports, "__esModule", { value: true });
27
+ exports.AdminPostProductsProductReq = exports.AdminPostProductsReq = void 0;
28
+ /* eslint-disable new-cap */
29
+ var create_product_1 = require("@medusajs/medusa/dist/api/routes/admin/products/create-product");
30
+ var update_product_1 = require("@medusajs/medusa/dist/api/routes/admin/products/update-product");
31
+ var class_validator_1 = require("class-validator");
32
+ var AdminPostProductsReq = /** @class */ (function (_super) {
33
+ __extends(AdminPostProductsReq, _super);
34
+ function AdminPostProductsReq() {
35
+ return _super !== null && _super.apply(this, arguments) || this;
36
+ }
37
+ __decorate([
38
+ (0, class_validator_1.IsString)({ each: true }),
39
+ (0, class_validator_1.ArrayMaxSize)(10),
40
+ (0, class_validator_1.IsOptional)(),
41
+ __metadata("design:type", Array)
42
+ ], AdminPostProductsReq.prototype, "shipping_options", void 0);
43
+ return AdminPostProductsReq;
44
+ }(create_product_1.AdminPostProductsReq));
45
+ exports.AdminPostProductsReq = AdminPostProductsReq;
46
+ var AdminPostProductsProductReq = /** @class */ (function (_super) {
47
+ __extends(AdminPostProductsProductReq, _super);
48
+ function AdminPostProductsProductReq() {
49
+ return _super !== null && _super.apply(this, arguments) || this;
50
+ }
51
+ __decorate([
52
+ (0, class_validator_1.IsString)({ each: true }),
53
+ (0, class_validator_1.ArrayMaxSize)(10),
54
+ (0, class_validator_1.IsOptional)(),
55
+ __metadata("design:type", Array)
56
+ ], AdminPostProductsProductReq.prototype, "shipping_options", void 0);
57
+ return AdminPostProductsProductReq;
58
+ }(update_product_1.AdminPostProductsProductReq));
59
+ exports.AdminPostProductsProductReq = AdminPostProductsProductReq;
60
+ //# sourceMappingURL=post-products-req.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"post-products-req.js","sourceRoot":"","sources":["../../../../src/api/validators/admin/post-products-req.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4BAA4B;AAC5B,iGAAoI;AACpI,iGAAkJ;AAClJ,mDAAqE;AAErE;IAA0C,wCAA0B;IAApE;;IAKA,CAAC;IAJG;QAAC,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;QACxB,IAAA,8BAAY,EAAC,EAAE,CAAC;QAChB,IAAA,4BAAU,GAAE;;kEACe;IAChC,2BAAC;CAAA,AALD,CAA0C,qCAA0B,GAKnE;AALY,oDAAoB;AAOjC;IAAiD,+CAAiC;IAAlF;;IAKA,CAAC;IAJG;QAAC,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;QACxB,IAAA,8BAAY,EAAC,EAAE,CAAC;QAChB,IAAA,4BAAU,GAAE;;yEACe;IAChC,kCAAC;CAAA,AALD,CAAiD,4CAAiC,GAKjF;AALY,kEAA2B"}
@@ -0,0 +1,10 @@
1
+ import { StoreGetProductCategoriesParams as MedusaStoreGetProductCategoriesParams } from "@medusajs/medusa/dist/api/routes/store/product-categories/list-product-categories";
2
+ import { StoreGetProductCategoriesCategoryParams as MedusaStoreGetProductCategoriesCategoryParams } from "@medusajs/medusa/dist/api/routes/store/product-categories/get-product-category";
3
+ export declare class StoreGetProductCategoriesParams extends MedusaStoreGetProductCategoriesParams {
4
+ shipping_options?: string[];
5
+ language?: string;
6
+ }
7
+ export declare class StoreGetProductCategoriesCategoryParams extends MedusaStoreGetProductCategoriesCategoryParams {
8
+ shipping_options?: string[];
9
+ language?: string;
10
+ }
@@ -0,0 +1,74 @@
1
+ "use strict";
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
17
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
18
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
19
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
20
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
21
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
22
+ };
23
+ var __metadata = (this && this.__metadata) || function (k, v) {
24
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
25
+ };
26
+ Object.defineProperty(exports, "__esModule", { value: true });
27
+ exports.StoreGetProductCategoriesCategoryParams = exports.StoreGetProductCategoriesParams = void 0;
28
+ /* eslint-disable new-cap */
29
+ var list_product_categories_1 = require("@medusajs/medusa/dist/api/routes/store/product-categories/list-product-categories");
30
+ var get_product_category_1 = require("@medusajs/medusa/dist/api/routes/store/product-categories/get-product-category");
31
+ var class_validator_1 = require("class-validator");
32
+ var StoreGetProductCategoriesParams = /** @class */ (function (_super) {
33
+ __extends(StoreGetProductCategoriesParams, _super);
34
+ function StoreGetProductCategoriesParams() {
35
+ return _super !== null && _super.apply(this, arguments) || this;
36
+ }
37
+ var _a, _b;
38
+ __decorate([
39
+ (0, class_validator_1.IsString)({ each: true }),
40
+ (0, class_validator_1.ArrayMaxSize)(10),
41
+ (0, class_validator_1.IsOptional)(),
42
+ __metadata("design:type", Array)
43
+ ], StoreGetProductCategoriesParams.prototype, "shipping_options", void 0);
44
+ __decorate([
45
+ (0, class_validator_1.IsString)(),
46
+ (0, class_validator_1.IsIn)((_b = (_a = process.env.AVAILABLE_LANGUAGES) === null || _a === void 0 ? void 0 : _a.split(",")) !== null && _b !== void 0 ? _b : []),
47
+ (0, class_validator_1.IsOptional)(),
48
+ __metadata("design:type", String)
49
+ ], StoreGetProductCategoriesParams.prototype, "language", void 0);
50
+ return StoreGetProductCategoriesParams;
51
+ }(list_product_categories_1.StoreGetProductCategoriesParams));
52
+ exports.StoreGetProductCategoriesParams = StoreGetProductCategoriesParams;
53
+ var StoreGetProductCategoriesCategoryParams = /** @class */ (function (_super) {
54
+ __extends(StoreGetProductCategoriesCategoryParams, _super);
55
+ function StoreGetProductCategoriesCategoryParams() {
56
+ return _super !== null && _super.apply(this, arguments) || this;
57
+ }
58
+ var _c, _d;
59
+ __decorate([
60
+ (0, class_validator_1.IsString)({ each: true }),
61
+ (0, class_validator_1.ArrayMaxSize)(10),
62
+ (0, class_validator_1.IsOptional)(),
63
+ __metadata("design:type", Array)
64
+ ], StoreGetProductCategoriesCategoryParams.prototype, "shipping_options", void 0);
65
+ __decorate([
66
+ (0, class_validator_1.IsString)(),
67
+ (0, class_validator_1.IsIn)((_d = (_c = process.env.AVAILABLE_LANGUAGES) === null || _c === void 0 ? void 0 : _c.split(",")) !== null && _d !== void 0 ? _d : []),
68
+ (0, class_validator_1.IsOptional)(),
69
+ __metadata("design:type", String)
70
+ ], StoreGetProductCategoriesCategoryParams.prototype, "language", void 0);
71
+ return StoreGetProductCategoriesCategoryParams;
72
+ }(get_product_category_1.StoreGetProductCategoriesCategoryParams));
73
+ exports.StoreGetProductCategoriesCategoryParams = StoreGetProductCategoriesCategoryParams;
74
+ //# sourceMappingURL=get-categories-req.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-categories-req.js","sourceRoot":"","sources":["../../../../src/api/validators/store/get-categories-req.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4BAA4B;AAC5B,6HAA6K;AAC7K,uHAA0L;AAC1L,mDAA2E;AAE3E;IAAqD,mDAAqC;IAA1F;;IASA,CAAC;;IARG;QAAC,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;QACxB,IAAA,8BAAY,EAAC,EAAE,CAAC;QAChB,IAAA,4BAAU,GAAE;;6EACe;IAC5B;QAAC,IAAA,0BAAQ,GAAE;QACV,IAAA,sBAAI,EAAC,MAAA,MAAA,OAAO,CAAC,GAAG,CAAC,mBAAmB,0CAAE,KAAK,CAAC,GAAG,CAAC,mCAAI,EAAE,CAAC;QACvD,IAAA,4BAAU,GAAE;;qEACK;IACtB,sCAAC;CAAA,AATD,CAAqD,yDAAqC,GASzF;AATY,0EAA+B;AAW5C;IAA6D,2DAA6C;IAA1G;;IASA,CAAC;;IARG;QAAC,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;QACxB,IAAA,8BAAY,EAAC,EAAE,CAAC;QAChB,IAAA,4BAAU,GAAE;;qFACe;IAC5B;QAAC,IAAA,0BAAQ,GAAE;QACV,IAAA,sBAAI,EAAC,MAAA,MAAA,OAAO,CAAC,GAAG,CAAC,mBAAmB,0CAAE,KAAK,CAAC,GAAG,CAAC,mCAAI,EAAE,CAAC;QACvD,IAAA,4BAAU,GAAE;;6EACK;IACtB,8CAAC;CAAA,AATD,CAA6D,8DAA6C,GASzG;AATY,0FAAuC"}
@@ -0,0 +1,10 @@
1
+ import { StoreGetProductsParams as MedusaStoreGetProductsParams } from "@medusajs/medusa/dist/api/routes/store/products/list-products";
2
+ import { StoreGetProductsProductParams as MedusaStoreGetProductsProductParams } from "@medusajs/medusa/dist/api/routes/store/products/get-product";
3
+ export declare class StoreGetProductsParams extends MedusaStoreGetProductsParams {
4
+ shipping_options?: string[];
5
+ language?: string;
6
+ }
7
+ export declare class StoreGetProductsProductParams extends MedusaStoreGetProductsProductParams {
8
+ shipping_options?: string[];
9
+ language?: string;
10
+ }
@@ -0,0 +1,74 @@
1
+ "use strict";
2
+ var __extends = (this && this.__extends) || (function () {
3
+ var extendStatics = function (d, b) {
4
+ extendStatics = Object.setPrototypeOf ||
5
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
6
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
7
+ return extendStatics(d, b);
8
+ };
9
+ return function (d, b) {
10
+ if (typeof b !== "function" && b !== null)
11
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
12
+ extendStatics(d, b);
13
+ function __() { this.constructor = d; }
14
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
15
+ };
16
+ })();
17
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
18
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
19
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
20
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
21
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
22
+ };
23
+ var __metadata = (this && this.__metadata) || function (k, v) {
24
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
25
+ };
26
+ Object.defineProperty(exports, "__esModule", { value: true });
27
+ exports.StoreGetProductsProductParams = exports.StoreGetProductsParams = void 0;
28
+ /* eslint-disable new-cap */
29
+ var list_products_1 = require("@medusajs/medusa/dist/api/routes/store/products/list-products");
30
+ var get_product_1 = require("@medusajs/medusa/dist/api/routes/store/products/get-product");
31
+ var class_validator_1 = require("class-validator");
32
+ var StoreGetProductsParams = /** @class */ (function (_super) {
33
+ __extends(StoreGetProductsParams, _super);
34
+ function StoreGetProductsParams() {
35
+ return _super !== null && _super.apply(this, arguments) || this;
36
+ }
37
+ var _a, _b;
38
+ __decorate([
39
+ (0, class_validator_1.IsString)({ each: true }),
40
+ (0, class_validator_1.ArrayMaxSize)(10),
41
+ (0, class_validator_1.IsOptional)(),
42
+ __metadata("design:type", Array)
43
+ ], StoreGetProductsParams.prototype, "shipping_options", void 0);
44
+ __decorate([
45
+ (0, class_validator_1.IsString)(),
46
+ (0, class_validator_1.IsIn)((_b = (_a = process.env.AVAILABLE_LANGUAGES) === null || _a === void 0 ? void 0 : _a.split(",")) !== null && _b !== void 0 ? _b : []),
47
+ (0, class_validator_1.IsOptional)(),
48
+ __metadata("design:type", String)
49
+ ], StoreGetProductsParams.prototype, "language", void 0);
50
+ return StoreGetProductsParams;
51
+ }(list_products_1.StoreGetProductsParams));
52
+ exports.StoreGetProductsParams = StoreGetProductsParams;
53
+ var StoreGetProductsProductParams = /** @class */ (function (_super) {
54
+ __extends(StoreGetProductsProductParams, _super);
55
+ function StoreGetProductsProductParams() {
56
+ return _super !== null && _super.apply(this, arguments) || this;
57
+ }
58
+ var _c, _d;
59
+ __decorate([
60
+ (0, class_validator_1.IsString)({ each: true }),
61
+ (0, class_validator_1.ArrayMaxSize)(10),
62
+ (0, class_validator_1.IsOptional)(),
63
+ __metadata("design:type", Array)
64
+ ], StoreGetProductsProductParams.prototype, "shipping_options", void 0);
65
+ __decorate([
66
+ (0, class_validator_1.IsString)(),
67
+ (0, class_validator_1.IsIn)((_d = (_c = process.env.AVAILABLE_LANGUAGES) === null || _c === void 0 ? void 0 : _c.split(",")) !== null && _d !== void 0 ? _d : []),
68
+ (0, class_validator_1.IsOptional)(),
69
+ __metadata("design:type", String)
70
+ ], StoreGetProductsProductParams.prototype, "language", void 0);
71
+ return StoreGetProductsProductParams;
72
+ }(get_product_1.StoreGetProductsProductParams));
73
+ exports.StoreGetProductsProductParams = StoreGetProductsProductParams;
74
+ //# sourceMappingURL=get-products-req.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-products-req.js","sourceRoot":"","sources":["../../../../src/api/validators/store/get-products-req.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4BAA4B;AAC5B,+FAAuI;AACvI,2FAAmJ;AACnJ,mDAA2E;AAE3E;IAA4C,0CAA4B;IAAxE;;IASA,CAAC;;IARG;QAAC,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;QACxB,IAAA,8BAAY,EAAC,EAAE,CAAC;QAChB,IAAA,4BAAU,GAAE;;oEACe;IAC5B;QAAC,IAAA,0BAAQ,GAAE;QACV,IAAA,sBAAI,EAAC,MAAA,MAAA,OAAO,CAAC,GAAG,CAAC,mBAAmB,0CAAE,KAAK,CAAC,GAAG,CAAC,mCAAI,EAAE,CAAC;QACvD,IAAA,4BAAU,GAAE;;4DACK;IACtB,6BAAC;CAAA,AATD,CAA4C,sCAA4B,GASvE;AATY,wDAAsB;AAWnC;IAAmD,iDAAmC;IAAtF;;IASA,CAAC;;IARG;QAAC,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;QACxB,IAAA,8BAAY,EAAC,EAAE,CAAC;QAChB,IAAA,4BAAU,GAAE;;2EACe;IAC5B;QAAC,IAAA,0BAAQ,GAAE;QACV,IAAA,sBAAI,EAAC,MAAA,MAAA,OAAO,CAAC,GAAG,CAAC,mBAAmB,0CAAE,KAAK,CAAC,GAAG,CAAC,mCAAI,EAAE,CAAC;QACvD,IAAA,4BAAU,GAAE;;mEACK;IACtB,oCAAC;CAAA,AATD,CAAmD,2CAAmC,GASrF;AATY,sEAA6B"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sgftech/medusa-plugin-marketplace-v2",
3
- "version": "0.2.32",
3
+ "version": "0.2.33",
4
4
  "description": "A plugin to initiate marketplace",
5
5
  "author": "Govind Diwakar",
6
6
  "license": "MIT",