Перейти к основному содержимому

useUpdateProductionObject

@mineflow/client-react


@mineflow/client-react / Справочники / useUpdateProductionObject

Function: useUpdateProductionObject()

function useUpdateProductionObject(): UseMutationResult<{
active: boolean;
code: string;
createdAt: string;
id: string;
name: string;
region: string | null;
updatedAt: string;
}, Error, {
body: {
[key: string]: unknown;
};
id: string;
}>;

Defined in: client-react/src/domain-hooks/refs.ts:351

Правка производственного объекта (PATCH). На успехе инвалидирует оба кэша участков (active+all) через стабильный префикс.

Returns​

UseMutationResult<{ active: boolean; code: string; createdAt: string; id: string; name: string; region: string | null; updatedAt: string; }, Error, { body: { [key: string]: unknown; }; id: string; }>

UseMutationResult — mutate({ id, body }).