-
Notifications
You must be signed in to change notification settings - Fork 49
Description
-
Create a contribution that fulfills the following:
"type": "ms.vss-work-web.backlog-panel", "targets": ["ms.vss-work-web.requirement-backlog-toolpane"] -
in that contribution, add a button that calls an async event handler when clicked
-
in the event handler method, use getService to obtain an IHostNavigationService service
-
with that IHostNavigationService instance, call the getPageRoute() method.
-
Click the button and review the rout information provided
-
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.
-
Click the button and review the rout information provided
-
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);
}