diff --git a/src/frontend/src/views/executive-history/step-detail/components/execution-history-select.vue b/src/frontend/src/views/executive-history/step-detail/components/execution-history-select.vue index 6f03a79ece..1006be04c6 100644 --- a/src/frontend/src/views/executive-history/step-detail/components/execution-history-select.vue +++ b/src/frontend/src/views/executive-history/step-detail/components/execution-history-select.vue @@ -127,18 +127,17 @@ stepInstanceId: this.stepInstanceId, batch: this.batch, }).then((data) => { - const max = _.max(data.map(_ => _.retryCount)); - const result = data.map((item) => { + const num = data.length; + const result = data.map((item, index) => { const { retryCount, createTime, } = item; - const realIndex = retryCount + 1; return { retryCount, createTime, - text: retryCount !== max ? ordinalSuffixOf(realIndex) : 'LATEST', + text: index === 0 ? 'LATEST' : ordinalSuffixOf(num - index), }; }); this.executionList = Object.freeze(result);