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

IHostNavigationService .getPageRoute() does not return correct results in all situations #138

Open
TheAtomAnt opened this issue Jun 28, 2024 · 1 comment

Comments

@TheAtomAnt
Copy link

  1. Create a contribution that fulfills the following:
    "type": "ms.vss-work-web.backlog-panel", "targets": ["ms.vss-work-web.requirement-backlog-toolpane"]

  2. in that contribution, add a button that calls an async event handler when clicked

  3. in the event handler method, use getService to obtain an IHostNavigationService service

  4. with that IHostNavigationService instance, call the getPageRoute() method.

  5. Click the button and review the rout information provided

  6. Now, select a different backlog level, in the default basic process, switch from "Epics" to "Issues", or switch to another defined backlog level if you are using a different process template.

  7. Click the button and review the rout information provided

  8. Notice that this second click of the button AFTER you changed to another backlog level does NOT show the correct backlog Level

public render(): JSX.Element {
...
       <Button
              text="Test"
               onClick={() => this.OnTestClick()}
       />
...
}
    async OnTestClick() {
        const navigationService = await SDK.getService<IHostNavigationService>(CommonServiceIds.HostNavigationService);
        const data = await navigationService.getPageRoute();
        const dataString = JSON.stringify(data, null, 4);
        console.clear();
        console.log(dataString);
    }
@TheAtomAnt
Copy link
Author

Further investigation suggests this is not an issue with either the API, or the SDK. It would seem that the rpcMessage result contains invalid information and the rpcMessage results presumably come from the host container.

I am unsure where this issue should actually be directed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant