fix(dashboard): Prevent fulfillment provider modal from re-rendering before form submission is complete (#10547)

Resolves CMRC-782
This commit is contained in:
Kasper Fabricius Kristensen
2024-12-11 14:10:58 +01:00
committed by GitHub
parent 2ac6fd82d9
commit dc5e73af4d
4 changed files with 35 additions and 19 deletions

View File

@@ -185,8 +185,8 @@ export const useUpdateStockLocationFulfillmentProviders = (
>
) => {
return useMutation({
mutationFn: (payload) =>
sdk.admin.stockLocation.updateFulfillmentProviders(id, payload),
mutationFn: async (payload) =>
await sdk.admin.stockLocation.updateFulfillmentProviders(id, payload),
onSuccess: async (data, variables, context) => {
await queryClient.invalidateQueries({
queryKey: stockLocationsQueryKeys.details(),