Hotfix Отображение верхнего блока

This commit is contained in:
Александр Сироткин 2022-11-22 07:24:23 +05:00
parent 51ac260c74
commit a2d641abdd

View File

@ -64,6 +64,11 @@ const Well = memo(() => {
{ actionName: 'Изменение данных скважины', well }
), [well])
const setBlock = useCallback((value) => {
setTopRightBlock(() => value)
return () => setTopRightBlock(undefined)
}, [])
useEffect(() => {
invokeWebApiWrapperAsync(
async () => {
@ -85,7 +90,7 @@ const Well = memo(() => {
<RootPathContext.Provider value={rootPath}>
<WellContext.Provider value={[well, updateWell]}>
<FastRunMenu />
<TopRightBlockContext.Provider value={setTopRightBlock}>
<TopRightBlockContext.Provider value={setBlock}>
<Routes>
<Route index element={<Navigate to={'telemetry'} replace />} />
<Route path={'*'} element={<NoAccessComponent />} />