Skip to content

Commit 3e311ed

Browse files
committed
Show proper interval for a onetime pipeline
Signed-off-by: Keshav Priyadarshi <[email protected]>
1 parent 528b6c8 commit 3e311ed

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

vulnerabilities/templates/pipeline_dashboard.html

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,11 @@ <h1>Pipeline Dashboard</h1>
8080
<div class="column is-one-quarter">{{ schedule.pipeline_id }}</div>
8181
<div class="column is-one-eighth has-text-grey">{{ schedule.is_active|yesno:"Yes,No" }}</div>
8282
<div class="column is-one-eighth has-text-grey">
83-
{{ schedule.run_interval }} hour{{ schedule.run_interval|pluralize }}
83+
{% if schedule.is_run_once %}
84+
Once
85+
{% else %}
86+
{{ schedule.run_interval }} hour{{ schedule.run_interval|pluralize }}
87+
{% endif %}
8488
</div>
8589
<div class="column is-one-eighth">
8690
<span class="is-flex is-align-items-center">
@@ -95,7 +99,11 @@ <h1>Pipeline Dashboard</h1>
9599
{% endif %}
96100
</div>
97101
<div class="column is-one-fifth has-text-grey">
98-
{{ schedule.next_run_date|date:"Y-m-d" }}
102+
{% if schedule.next_run_date %}
103+
{{ schedule.next_run_date|date:"Y-m-d" }}
104+
{% else %}
105+
N/A
106+
{% endif %}
99107
</div>
100108
</div>
101109
</a>

0 commit comments

Comments
 (0)