mirror of
https://github.com/kemko/nomad.git
synced 2026-01-06 18:35:44 +03:00
Make running-deployment always show the latest deployment
This commit is contained in:
@@ -3,4 +3,6 @@ import Component from '@ember/component';
|
||||
export default Component.extend({
|
||||
job: null,
|
||||
tagName: '',
|
||||
|
||||
isShowingDeploymentDetails: false,
|
||||
});
|
||||
|
||||
@@ -1,22 +1,24 @@
|
||||
{{#if job.runningDeployment}}
|
||||
<div class="boxed-section is-info" data-test-active-deployment>
|
||||
{{#if job.latestDeployment}}
|
||||
<div class="boxed-section {{if job.latestDeployment.isRunning "is-info"}}" data-test-active-deployment>
|
||||
<div class="boxed-section-head">
|
||||
<div class="boxed-section-row">
|
||||
Active Deployment
|
||||
<span class="badge is-white is-subtle bumper-left" data-test-active-deployment-stat="id">{{job.runningDeployment.shortId}}</span>
|
||||
{{#if job.runningDeployment.version.submitTime}}
|
||||
<span class="pull-right submit-time" data-test-active-deployment-stat="submit-time">{{moment-from-now job.runningDeployment.version.submitTime}}</span>
|
||||
{{if job.latestDeployment.isRunning "Active" "Latest"}} Deployment
|
||||
<span class="badge is-white {{if job.latestDeployment.isRunning "is-subtle"}} bumper-left" data-test-active-deployment-stat="id">{{job.latestDeployment.shortId}}</span>
|
||||
{{#if job.latestDeployment.version.submitTime}}
|
||||
<span class="pull-right submit-time" data-test-active-deployment-stat="submit-time">{{moment-from-now job.latestDeployment.version.submitTime}}</span>
|
||||
{{/if}}
|
||||
</div>
|
||||
<div class="boxed-section-row">
|
||||
<span class="tag is-info is-outlined">Running</span>
|
||||
{{#if job.runningDeployment.requiresPromotion}}
|
||||
<span class="tag is-outlined {{job.latestDeployment.statusClass}}" data-test-deployment-status="{{job.latestDeployment.statusClass}}">
|
||||
{{job.latestDeployment.status}}
|
||||
</span>
|
||||
{{#if job.latestDeployment.requiresPromotion}}
|
||||
<span class="tag bumper-left is-warning no-text-transform">Deployment is running but requires promotion</span>
|
||||
{{/if}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="boxed-section-body with-foot">
|
||||
{{#job-deployment-details deployment=job.runningDeployment as |d|}}
|
||||
{{#job-deployment-details deployment=job.latestDeployment as |d|}}
|
||||
{{d.metrics}}
|
||||
{{#if isShowingDeploymentDetails}}
|
||||
{{d.taskGroups}}
|
||||
|
||||
Reference in New Issue
Block a user