@medusajs/types 2.1.4-preview-20241223150146 → 2.1.4-preview-20241223180209
Sign up to get free protection for your applications and to get access to all the features.
@@ -1,31 +1,37 @@
|
|
1
|
+
import { FindParams } from "../../common";
|
1
2
|
import { BaseProductListParams, BaseProductOptionParams, BaseProductVariantParams } from "../common";
|
2
3
|
export interface StoreProductOptionParams extends BaseProductOptionParams {
|
3
4
|
}
|
4
5
|
export interface StoreProductVariantParams extends BaseProductVariantParams {
|
5
6
|
}
|
6
|
-
export interface
|
7
|
+
export interface StoreProductPricingContext {
|
7
8
|
/**
|
8
|
-
*
|
9
|
+
* The ID of the customer's region. This parameter must be included if you want to apply taxes on the product variant's price.
|
9
10
|
*/
|
10
|
-
|
11
|
+
region_id?: string;
|
11
12
|
/**
|
12
|
-
* The
|
13
|
-
*
|
14
|
-
* @privateRemarks
|
15
|
-
* The region ID and currency_code are not params, but are used for the pricing context. Maybe move to separate type definition.
|
13
|
+
* The customer's country code. This parameter must be included if you want to apply taxes on the product variant's price.
|
16
14
|
*/
|
17
|
-
|
15
|
+
country_code?: string;
|
18
16
|
/**
|
19
|
-
* The
|
17
|
+
* The province, which can be taken from a customer's address. This parameter helps further narrowing down the taxes applied on a the product variant's prices.
|
20
18
|
*/
|
21
|
-
|
19
|
+
province?: string;
|
22
20
|
/**
|
23
|
-
*
|
21
|
+
* The ID of the customer's cart, if available. If set, the cart's region and shipping address's country code and province are used instead of the `region_id`, `country_code`, and `province` parameters.
|
24
22
|
*/
|
25
|
-
|
23
|
+
cart_id?: string;
|
24
|
+
}
|
25
|
+
export interface StoreProductParams extends FindParams, StoreProductPricingContext {
|
26
|
+
}
|
27
|
+
export interface StoreProductListParams extends Omit<BaseProductListParams, "tags" | "status" | "categories" | "deleted_at">, StoreProductPricingContext {
|
26
28
|
/**
|
27
|
-
*
|
29
|
+
* Filter by the product's tag(s).
|
28
30
|
*/
|
29
|
-
|
31
|
+
tag_id?: string | string[];
|
32
|
+
/**
|
33
|
+
* Filter by the product's variants.
|
34
|
+
*/
|
35
|
+
variants?: Pick<StoreProductVariantParams, "options">;
|
30
36
|
}
|
31
37
|
//# sourceMappingURL=queries.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"queries.d.ts","sourceRoot":"","sources":["../../../../src/http/product/store/queries.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,qBAAqB,EACrB,uBAAuB,EACvB,wBAAwB,EACzB,MAAM,WAAW,CAAA;AAElB,MAAM,WAAW,wBAAyB,SAAQ,uBAAuB;CAAG;AAC5E,MAAM,WAAW,yBAA0B,SAAQ,wBAAwB;CAAG;AAC9E,MAAM,WAAW,
|
1
|
+
{"version":3,"file":"queries.d.ts","sourceRoot":"","sources":["../../../../src/http/product/store/queries.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AACzC,OAAO,EACL,qBAAqB,EACrB,uBAAuB,EACvB,wBAAwB,EACzB,MAAM,WAAW,CAAA;AAElB,MAAM,WAAW,wBAAyB,SAAQ,uBAAuB;CAAG;AAC5E,MAAM,WAAW,yBAA0B,SAAQ,wBAAwB;CAAG;AAC9E,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;CACjB;AACD,MAAM,WAAW,kBAAmB,SAAQ,UAAU,EAAE,0BAA0B;CAAG;AAErF,MAAM,WAAW,sBACf,SAAQ,IAAI,CAAC,qBAAqB,EAAE,MAAM,GAAG,QAAQ,GAAG,YAAY,GAAG,YAAY,CAAC,EAAE,0BAA0B;IAChH;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IAC1B;;OAEG;IACH,QAAQ,CAAC,EAAE,IAAI,CAAC,yBAAyB,EAAE,SAAS,CAAC,CAAA;CACtD"}
|