Add actions to scheduled job buttons on job list page

This commit is contained in:
Winnie Hellmann 2018-10-01 12:47:07 +02:00 committed by Alessio Caiazza
parent eb238ec160
commit 6369ff1ce1

View file

@ -107,9 +107,15 @@
title: job.scheduled_at }
= sprite_icon('planning')
= duration_in_numbers(job.execute_in, true)
.btn.btn-default.btn-build.has-tooltip{ title: s_('DelayedJobs|Start now') }
= link_to play_project_job_path(job.project, job, return_to: request.original_url),
method: :post,
title: s_('DelayedJobs|Start now'),
class: 'btn btn-default btn-build has-tooltip' do
= sprite_icon('play')
.btn.btn-default.btn-build.has-tooltip{ title: s_('DelayedJobs|Unschedule') }
= link_to unschedule_project_job_path(job.project, job, return_to: request.original_url),
method: :post,
title: s_('DelayedJobs|Unschedule'),
class: 'btn btn-default btn-build has-tooltip' do
= sprite_icon('time-out')
- elsif allow_retry
- if job.playable? && !admin && can?(current_user, :update_build, job)