forked from medusajs/medusa
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(types): add price types for shipping option endpoints (medusajs…
…#10509) what: - adds missing price types for shipping options
- Loading branch information
Showing
5 changed files
with
73 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
export * from "./admin" | ||
export * from "./store" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
import { PricingRuleOperatorValues } from "../../../pricing" | ||
import { BaseCalculatedPriceSet } from "../common" | ||
|
||
export interface StorePrice { | ||
/** | ||
* The price's ID. | ||
*/ | ||
id: string | ||
/** | ||
* The price's currency code. | ||
* | ||
* @example | ||
* usd | ||
*/ | ||
currency_code: string | ||
/** | ||
* The price's amount. | ||
*/ | ||
amount: number | ||
/** | ||
* The minimum quantity that must be available in the cart for the price to be applied. | ||
*/ | ||
min_quantity: number | null | ||
/** | ||
* The maximum quantity allowed to be available in the cart for the price to be applied. | ||
*/ | ||
max_quantity: number | null | ||
|
||
/** | ||
* The rules enabled to enable the current price | ||
*/ | ||
price_rules?: StorePriceRule[] | ||
} | ||
|
||
export interface StorePriceRule { | ||
/** | ||
* The ID of the price rule. | ||
*/ | ||
id: string | ||
/** | ||
* The attribute of the price rule | ||
*/ | ||
attribute: string | ||
|
||
/** | ||
* The operator of the price rule | ||
*/ | ||
operator: PricingRuleOperatorValues | ||
|
||
/** | ||
* The value of the price rule. | ||
*/ | ||
value: string | ||
} | ||
|
||
export interface StoreCalculatedPrice extends BaseCalculatedPriceSet {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from "./entities" |