Fix teleporting board cards on drag drop (#1613)

- fix teleporting board cards on drag drop
This commit is contained in:
brendanlaschke 2023-09-16 22:03:46 +03:00 committed by GitHub
parent 00a3c8ca2b
commit a26c8d660d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -72,6 +72,24 @@ export const EntityBoard = ({
id: pipelineProgressId,
pipelineStageId,
},
optimisticResponse: {
__typename: 'Mutation',
updateOnePipelineProgress: {
__typename: 'PipelineProgress',
id: pipelineProgressId,
},
},
update: (cache) => {
cache.modify({
id: cache.identify({
id: pipelineProgressId,
__typename: 'PipelineProgress',
}),
fields: {
pipelineStageId: () => pipelineStageId,
},
});
},
refetchQueries: [getOperationName(GET_PIPELINE_PROGRESS) ?? ''],
});
},