Update to use stored iteration from URL
This commit is contained in:
parent
44536c55f0
commit
42d45c1d58
|
@ -2,7 +2,7 @@
|
|||
"manifestVersion": 1,
|
||||
"id": "iteration-work-items-hub",
|
||||
"publisher": "JamesSkemp",
|
||||
"version": "1.0.111",
|
||||
"version": "1.0.113",
|
||||
"name": "Iteration Work Items Hub",
|
||||
"description": "Iteration Work Items Hub supports viewing all items within a Team Iteration in Azure DevOps grouped by type and board state.",
|
||||
"categories": [
|
||||
|
|
|
@ -83,7 +83,7 @@ class HubContent extends React.Component<{}, IHubContentState> {
|
|||
|
||||
public render(): JSX.Element {
|
||||
const {
|
||||
selectedTabId, headerDescription, useCompactPivots, useLargeTitle,
|
||||
headerDescription, useLargeTitle,
|
||||
teams, teamIterations, workItems
|
||||
} = this.state;
|
||||
|
||||
|
@ -289,7 +289,14 @@ class HubContent extends React.Component<{}, IHubContentState> {
|
|||
iterationId = this.teamIterations[0].id;
|
||||
iterationName = this.teamIterations[0].name;
|
||||
} else {
|
||||
let currentIteration = this.teamIterations.find(i => i.attributes.timeFrame === 1);
|
||||
let currentIteration: TeamSettingsIteration | undefined;
|
||||
if (this.queryParamsTeamIteration) {
|
||||
currentIteration = this.teamIterations.find(i => i.id === this.queryParamsTeamIteration);
|
||||
}
|
||||
if (!currentIteration) {
|
||||
currentIteration = this.teamIterations.find(i => i.attributes.timeFrame === 1);
|
||||
}
|
||||
|
||||
if (currentIteration) {
|
||||
this.teamIterationSelection.select(this.teamIterations.indexOf(currentIteration));
|
||||
|
||||
|
@ -373,7 +380,7 @@ class HubContent extends React.Component<{}, IHubContentState> {
|
|||
this.setState({ workItemTypes: this.workItemTypes });
|
||||
}
|
||||
|
||||
private handleSelectTeam = (event: React.SyntheticEvent<HTMLElement>, item: IListBoxItem<{}>): void => {
|
||||
private handleSelectTeam = (_event: React.SyntheticEvent<HTMLElement>, item: IListBoxItem<{}>): void => {
|
||||
this.setState({
|
||||
selectedTeam: item.id
|
||||
});
|
||||
|
@ -390,7 +397,7 @@ class HubContent extends React.Component<{}, IHubContentState> {
|
|||
this.updateQueryParams();
|
||||
}
|
||||
|
||||
private handleSelectTeamIteration = (event: React.SyntheticEvent<HTMLElement>, item: IListBoxItem<{}>): void => {
|
||||
private handleSelectTeamIteration = (_event: React.SyntheticEvent<HTMLElement>, item: IListBoxItem<{}>): void => {
|
||||
this.setState({
|
||||
selectedTeamIteration: item.id
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue