From 00190980d38681b39de8b09010b81e3ecb6e5e2e Mon Sep 17 00:00:00 2001 From: takonomura Date: Fri, 26 Jan 2018 16:22:53 +0900 Subject: [PATCH] Show SUSPENDED label in job definition list --- app/views/kuroko2/job_definitions/_list.html.slim | 5 ++++- app/views/kuroko2/job_definitions/_search_results.html.slim | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/app/views/kuroko2/job_definitions/_list.html.slim b/app/views/kuroko2/job_definitions/_list.html.slim index 7c27de5e..1969e690 100644 --- a/app/views/kuroko2/job_definitions/_list.html.slim +++ b/app/views/kuroko2/job_definitions/_list.html.slim @@ -12,7 +12,10 @@ - for definition in definitions tr td= definition.id - td.no-decorate= link_to definition.name, definition + td.no-decorate + - if definition.suspended + span.label.label-warning.spacer-right-3 SUSPENDED + = link_to definition.name, definition - if !definition.suspended? && !definition.job_schedules.empty? - next_job_schedule = definition.job_schedules.map(&:next).min - if next_job_schedule diff --git a/app/views/kuroko2/job_definitions/_search_results.html.slim b/app/views/kuroko2/job_definitions/_search_results.html.slim index 97dbbe62..15fcc156 100644 --- a/app/views/kuroko2/job_definitions/_search_results.html.slim +++ b/app/views/kuroko2/job_definitions/_search_results.html.slim @@ -34,7 +34,10 @@ span.star-holder = star_link_for(definition) td= definition.id - td.no-decorate= link_to definition.name, definition + td.no-decorate + - if definition.suspended + span.label.label-warning.spacer-right-3 SUSPENDED + = link_to definition.name, definition td.no-decorate - definition.admins.each do |user| = link_to user.name, user_path(user)