debian-mirror-gitlab/app/views/projects/pipeline_schedules/_pipeline_schedule.html.haml

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

49 lines
3.2 KiB
Text
Raw Normal View History

2017-08-17 22:00:37 +05:30
- if pipeline_schedule
%tr.pipeline-schedule-table-row
2023-03-04 22:38:38 +05:30
%td{ role: 'cell', data: { label: _('Description') } }
%div
= pipeline_schedule.description
%td.branch-name-cell.gl-text-truncate{ role: 'cell', data: { label: s_("PipelineSchedules|Target") } }
%div
- if pipeline_schedule.for_tag?
= sprite_icon('tag', size: 12, css_class: 'gl-vertical-align-middle!')
- else
= sprite_icon('fork', size: 12, css_class: 'gl-vertical-align-middle!')
- if pipeline_schedule.ref.present?
= link_to pipeline_schedule.ref_for_display, project_ref_path(@project, pipeline_schedule.ref_for_display), class: "ref-name"
%td{ role: 'cell', data: { label: _("Last Pipeline") } }
%div
- if pipeline_schedule.last_pipeline
.status-icon-container{ class: "ci-status-icon-#{pipeline_schedule.last_pipeline.status}" }
= link_to project_pipeline_path(@project, pipeline_schedule.last_pipeline.id) do
= ci_icon_for_status(pipeline_schedule.last_pipeline.status)
%span.gl-text-blue-500! ##{pipeline_schedule.last_pipeline.id}
- else
= s_("PipelineSchedules|None")
%td.gl-text-gray-500{ role: 'cell', data: { label: s_("PipelineSchedules|Next Run") }, 'data-testid': 'next-run-cell' }
%div
- if pipeline_schedule.active? && pipeline_schedule.next_run_at
= time_ago_with_tooltip(pipeline_schedule.real_next_run)
- else
= s_("PipelineSchedules|Inactive")
%td{ role: 'cell', data: { label: _("Owner") } }
%div
- if pipeline_schedule.owner
= render Pajamas::AvatarComponent.new(pipeline_schedule.owner, size: 24, class: "gl-mr-2")
= link_to user_path(pipeline_schedule.owner) do
= pipeline_schedule.owner&.name
%td{ role: 'cell', data: { label: _('Actions') } }
2018-11-08 19:23:39 +05:30
.float-right.btn-group
2018-03-17 18:26:18 +05:30
- if can?(current_user, :play_pipeline_schedule, pipeline_schedule)
2021-11-11 11:23:49 +05:30
= link_to play_pipeline_schedule_path(pipeline_schedule), method: :post, title: _('Play'), class: 'btn gl-button btn-default btn-icon' do
2020-07-28 23:09:34 +05:30
= sprite_icon('play')
2023-05-27 22:25:52 +05:30
- if can?(current_user, :admin_pipeline_schedule, pipeline_schedule) && pipeline_schedule.owner != current_user
2022-08-27 11:52:29 +05:30
= render Pajamas::ButtonComponent.new(button_options: { class: 'js-take-ownership-button has-tooltip', title: s_('PipelineSchedule|Take ownership to edit'), data: { url: take_ownership_pipeline_schedule_path(pipeline_schedule) } }) do
2017-09-10 17:25:29 +05:30
= s_('PipelineSchedules|Take ownership')
- if can?(current_user, :update_pipeline_schedule, pipeline_schedule)
2021-04-17 20:07:23 +05:30
= link_to edit_pipeline_schedule_path(pipeline_schedule), title: _('Edit'), class: 'btn gl-button btn-default btn-icon' do
2020-10-24 23:57:45 +05:30
= sprite_icon('pencil')
2017-08-17 22:00:37 +05:30
- if can?(current_user, :admin_pipeline_schedule, pipeline_schedule)
2022-04-04 11:22:00 +05:30
= link_to pipeline_schedule_path(pipeline_schedule), title: _('Delete'), method: :delete, class: 'btn gl-button btn-danger btn-icon', aria: { label: _('Delete pipeline schedule') }, data: { confirm: _("Are you sure you want to delete this pipeline schedule?"), confirm_btn_variant: 'danger' } do
2020-10-24 23:57:45 +05:30
= sprite_icon('remove')