[JENKINS-36618] actually fix the bug by using the self.href as the unique key

This commit is contained in:
Cliff Meyers 2016-07-12 13:50:29 -04:00
parent c1d7e4ca2e
commit cfd82f0613
2 changed files with 10 additions and 6 deletions

View File

@ -62,12 +62,15 @@ export default class Pipelines extends Component {
headers={headers}
>
{ pipelineRecords
.map(pipeline => (
<PipelineRowItem
key={pipeline.name} pipeline={pipeline}
showOrganization={!organization}
/>
))
.map(pipeline => {
const key = pipeline._links.self.href;
return (
<PipelineRowItem
key={key} pipeline={pipeline}
showOrganization={!organization}
/>
);
})
}
</Table>
</article>

View File

@ -5,6 +5,7 @@ since we would return a function, */
const { Record } = Immutable;
export class PipelineRecord extends Record({
_class: null,
_links: null,
branchNames: null,
displayName: '',
estimatedDurationInMillis: 0,