2023-01-13 00:05:48 +05:30
|
|
|
- if deployment.deployable && can?(current_user, :play_job, deployment.deployable)
|
2018-11-18 11:00:15 +05:30
|
|
|
- tooltip = deployment.last? ? s_('Environments|Re-deploy to environment') : s_('Environments|Rollback environment')
|
2022-11-25 23:54:43 +05:30
|
|
|
- icon = deployment.last? ? 'repeat' : 'redo'
|
|
|
|
= render Pajamas::ButtonComponent.new(icon: icon, button_options: { title: tooltip, class: 'js-confirm-rollback-modal-button has-tooltip', data: { environment_name: @environment.name, commit_short_sha: deployment.short_sha, commit_url: project_commit_path(@project, deployment.sha), is_last_deployment: deployment.last?.to_s, retry_path: retry_project_job_path(@environment.project, deployment.deployable) } })
|