feat: Add support in BE for setting tax inclusivity on currency (#8037)
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import { updateStoresWorkflow } from "@medusajs/core-flows"
|
||||
import { UpdateStoreDTO } from "@medusajs/types"
|
||||
import {
|
||||
remoteQueryObjectFromString,
|
||||
ContainerRegistrationKeys,
|
||||
@@ -35,7 +34,7 @@ export const POST = async (
|
||||
const { result } = await updateStoresWorkflow(req.scope).run({
|
||||
input: {
|
||||
selector: { id: req.params.id },
|
||||
update: req.validatedBody as UpdateStoreDTO,
|
||||
update: req.validatedBody,
|
||||
},
|
||||
})
|
||||
|
||||
|
||||
@@ -20,12 +20,13 @@ export const AdminGetStoresParams = createFindParams({
|
||||
|
||||
export type AdminUpdateStoreType = z.infer<typeof AdminUpdateStore>
|
||||
export const AdminUpdateStore = z.object({
|
||||
name: z.string().nullish(),
|
||||
name: z.string().optional(),
|
||||
supported_currencies: z
|
||||
.array(
|
||||
z.object({
|
||||
currency_code: z.string(),
|
||||
is_default: z.boolean().optional(),
|
||||
is_tax_inclusive: z.boolean().optional(),
|
||||
})
|
||||
)
|
||||
.optional(),
|
||||
|
||||
Reference in New Issue
Block a user