File: _project_group_form.html.haml

package info (click to toggle)
gitlab 17.6.5-19
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 629,368 kB
  • sloc: ruby: 1,915,304; javascript: 557,307; sql: 60,639; xml: 6,509; sh: 4,567; makefile: 1,239; python: 406
file content (30 lines) | stat: -rw-r--r-- 1,592 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
= gitlab_ui_form_for [@project.namespace, @project, @deploy_keys.new_key], url: namespace_project_deploy_keys_path do |f|
  = form_errors(@deploy_keys.new_key)

  .form-group
    %h4.gl-my-0= s_('DeployKeys|Add new deploy key')

  .form-group
    = f.label :title, class: "label-bold"
    = f.text_field :title, class: 'form-control gl-form-input gl-form-input-xl', required: true, data: { testid: 'deploy-key-title-field' }
  .form-group
    = f.label :key, class: "label-bold"
    = f.text_area :key, class: 'form-control gl-form-input gl-form-input-xl !gl-h-auto', rows: 5, required: true, data: { testid: 'deploy-key-field' }
    .form-text.gl-text-subtle
      = _('Paste a public key here.')
      = link_to _('How do I generate it?'), help_page_path("user/ssh.md")

  = f.fields_for :deploy_keys_projects do |deploy_keys_project_form|
    .form-group
      = deploy_keys_project_form.gitlab_ui_checkbox_component :can_push, _('Grant write permissions to this key'),
        help_text: _('Allow this key to push to this repository')
  .form-group
    = f.label :expires_at, _('Expiration date (optional)'), class: 'label-bold'
    .gl-form-input-xl
      = f.gitlab_ui_datepicker :expires_at, data: { testid: 'deploy-key-expires-at-field' }, value: f.object.expires_at
      .form-text.gl-text-subtle= ssh_key_expires_field_description

  .form-group.gl-mb-0
    = f.submit _("Add key"), data: { testid: "add-deploy-key-button"}, pajamas_button: true
    = render Pajamas::ButtonComponent.new(button_options: { type: 'reset', class: 'gl-ml-3 js-toggle-button' }) do
      = _('Cancel')