2018-05-09 12:01:36 +05:30
|
|
|
- verification_enabled = Gitlab::CurrentSettings.pages_domain_verification_enabled?
|
|
|
|
|
2017-08-17 22:00:37 +05:30
|
|
|
- if can?(current_user, :update_pages, @project) && @domains.any?
|
2018-11-08 19:23:39 +05:30
|
|
|
.card
|
|
|
|
.card-header
|
2017-08-17 22:00:37 +05:30
|
|
|
Domains (#{@domains.count})
|
2019-02-13 22:33:31 +05:30
|
|
|
%ul.list-group.list-group-flush.pages-domain-list{ class: ("has-verification-status" if verification_enabled) }
|
2017-08-17 22:00:37 +05:30
|
|
|
- @domains.each do |domain|
|
2019-02-13 22:33:31 +05:30
|
|
|
%li.pages-domain-list-item.list-group-item.d-flex.justify-content-between
|
2018-05-09 12:01:36 +05:30
|
|
|
- if verification_enabled
|
|
|
|
- tooltip, status = domain.unverified? ? [_('Unverified'), 'failed'] : [_('Verified'), 'success']
|
|
|
|
.domain-status.ci-status-icon.has-tooltip{ class: "ci-status-icon-#{status}", title: tooltip }
|
|
|
|
= sprite_icon("status_#{status}", size: 16 )
|
|
|
|
.domain-name
|
|
|
|
= link_to domain.url do
|
|
|
|
= domain.url
|
|
|
|
= icon('external-link')
|
|
|
|
- if domain.subject
|
2019-02-13 22:33:31 +05:30
|
|
|
%div
|
2018-11-08 19:23:39 +05:30
|
|
|
%span.badge.badge-gray Certificate: #{domain.subject}
|
2018-05-09 12:01:36 +05:30
|
|
|
- if domain.expired?
|
2018-11-08 19:23:39 +05:30
|
|
|
%span.badge.badge-danger Expired
|
2018-05-09 12:01:36 +05:30
|
|
|
%div
|
2017-09-10 17:25:29 +05:30
|
|
|
= link_to 'Details', project_pages_domain_path(@project, domain), class: "btn btn-sm btn-grouped"
|
|
|
|
= link_to 'Remove', project_pages_domain_path(@project, domain), data: { confirm: 'Are you sure?'}, method: :delete, class: "btn btn-remove btn-sm btn-grouped"
|
2018-03-17 18:26:18 +05:30
|
|
|
- if verification_enabled && domain.unverified?
|
2019-02-13 22:33:31 +05:30
|
|
|
%li.list-group-item.bs-callout-warning
|
2018-03-17 18:26:18 +05:30
|
|
|
#{domain.domain} is not verified. To learn how to verify ownership, visit your
|
2018-05-09 12:01:36 +05:30
|
|
|
#{link_to 'domain details', project_pages_domain_path(@project, domain)}.
|