diff options
Diffstat (limited to 'app/views/projects/settings/integrations')
-rw-r--r-- | app/views/projects/settings/integrations/_form.html.haml | 22 | ||||
-rw-r--r-- | app/views/projects/settings/integrations/edit.html.haml | 9 | ||||
-rw-r--r-- | app/views/projects/settings/integrations/index.html.haml (renamed from app/views/projects/settings/integrations/show.html.haml) | 0 |
3 files changed, 31 insertions, 0 deletions
diff --git a/app/views/projects/settings/integrations/_form.html.haml b/app/views/projects/settings/integrations/_form.html.haml new file mode 100644 index 00000000000..9d74f99bb19 --- /dev/null +++ b/app/views/projects/settings/integrations/_form.html.haml @@ -0,0 +1,22 @@ +- if lookup_context.template_exists?('top', "shared/integrations/#{integration.to_param}", true) + = render "shared/integrations/#{integration.to_param}/top", integration: integration + +- if integration.activate_disabled_reason.present? && integration.activate_disabled_reason[:trackers].any? + -# When using integration.activate_disabled_reason[:trackers], it's potentially insecure to use the raw records + -# when passed directly to the frontend. Only use specific fields that are needed for render. + -# For example, we can get the link to each tracker with scoped_edit_integration_path(tracker, tracker.project) + = render Pajamas::AlertComponent.new(title: s_('ExternalIssueIntegration|Another issue tracker is already in use'), + variant: :warning, + dismissible: false) do |c| + = c.body do + = s_('ExternalIssueIntegration|Only one issue tracker integration can be active at a time. Please disable the active tracker first and try again.') + +%h2.gl-mb-4 + = integration.title + - if integration.operating? + = sprite_icon('check', css_class: 'gl-text-green-500') + += render 'shared/integration_settings', integration: integration +- if lookup_context.template_exists?('show', "shared/integrations/#{integration.to_param}", true) + %hr + = render "shared/integrations/#{integration.to_param}/show", integration: integration diff --git a/app/views/projects/settings/integrations/edit.html.haml b/app/views/projects/settings/integrations/edit.html.haml new file mode 100644 index 00000000000..a250daafdbb --- /dev/null +++ b/app/views/projects/settings/integrations/edit.html.haml @@ -0,0 +1,9 @@ +- breadcrumb_title @integration.title +- add_to_breadcrumbs _('Integration Settings'), project_settings_integrations_path(@project) +- page_title @integration.title, _('Integrations') +- @content_class = 'limit-container-width' unless fluid_layout + += render 'form', integration: @integration + +- if @web_hook_logs + = render partial: 'projects/hook_logs/index', locals: { hook: @integration.service_hook, hook_logs: @web_hook_logs, project: @project } diff --git a/app/views/projects/settings/integrations/show.html.haml b/app/views/projects/settings/integrations/index.html.haml index 84635941436..84635941436 100644 --- a/app/views/projects/settings/integrations/show.html.haml +++ b/app/views/projects/settings/integrations/index.html.haml |