Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] navigateHistory command is not available on startup #4241

Open
mbellehumeur opened this issue Jun 19, 2024 · 0 comments
Open

[Bug] navigateHistory command is not available on startup #4241

mbellehumeur opened this issue Jun 19, 2024 · 0 comments
Labels
Awaiting Reproduction Can we reproduce the reported bug?

Comments

@mbellehumeur
Copy link

Describe the Bug

The navigateHistory command of commandsManager is initialized in Mode.tsx therefore it is not available right after the client is started; before a study is opened. Adding the initialization in Worklist.tsx (in addition to Mode.tsx) fixed the problem for me:
// Expose the react router dom navigation
history.navigate = useNavigate();

Steps to Reproduce

Call:
commandsManager.runCommand('navigateHistory',{to:'/viewer?StudyInstanceUIDs='+studyUID}); }
after client startup. The error is 'navigate function does not exist'.

The current behavior

The navigateHistory command fails and the study does not open.

The expected behavior

The navigateHistory command runs and the study opens.

OS

macOS

Node version

18

Browser

Chrome

@mbellehumeur mbellehumeur added the Awaiting Reproduction Can we reproduce the reported bug? label Jun 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Reproduction Can we reproduce the reported bug?
Projects
None yet
Development

No branches or pull requests

1 participant