feat(medusa-js,medusa-react,medusa): Add missing Currency endpoints (#2185)
This commit is contained in:
@@ -19,6 +19,7 @@ export default (container, config) => {
|
||||
export * from "./routes/admin/auth"
|
||||
export * from "./routes/admin/batch"
|
||||
export * from "./routes/admin/collections"
|
||||
export * from "./routes/admin/currencies"
|
||||
export * from "./routes/admin/customer-groups"
|
||||
export * from "./routes/admin/customers"
|
||||
export * from "./routes/admin/discounts"
|
||||
|
||||
@@ -1,12 +1,14 @@
|
||||
import { Router } from "express"
|
||||
import { Currency } from "../../../.."
|
||||
import TaxInclusivePricingFeatureFlag from "../../../../loaders/feature-flags/tax-inclusive-pricing"
|
||||
import { PaginatedResponse } from "../../../../types/common"
|
||||
import middlewares, {
|
||||
transformBody,
|
||||
transformQuery,
|
||||
} from "../../../middlewares"
|
||||
import { isFeatureFlagEnabled } from "../../../middlewares/feature-flag-enabled"
|
||||
import { AdminGetCurrenciesParams } from "./list-currencies"
|
||||
import { AdminPostCurrenciesCurrencyReq } from "./update-currency"
|
||||
import { isFeatureFlagEnabled } from "../../../middlewares/feature-flag-enabled"
|
||||
import TaxInclusivePricingFeatureFlag from "../../../../loaders/feature-flags/tax-inclusive-pricing"
|
||||
|
||||
export default (app) => {
|
||||
const route = Router()
|
||||
@@ -33,5 +35,13 @@ export default (app) => {
|
||||
return app
|
||||
}
|
||||
|
||||
export type AdminCurrenciesListRes = PaginatedResponse & {
|
||||
currencies: Currency[]
|
||||
}
|
||||
|
||||
export type AdminCurrenciesRes = {
|
||||
currency: Currency
|
||||
}
|
||||
|
||||
export * from "./list-currencies"
|
||||
export * from "./update-currency"
|
||||
|
||||
Reference in New Issue
Block a user