2017-08-23 00:59:35 +02:00
|
|
|
.fields-group
|
2018-09-18 16:45:58 +02:00
|
|
|
= f.input :name, wrapper: :with_label, label: t('activerecord.attributes.doorkeeper/application.name')
|
|
|
|
|
|
|
|
.fields-group
|
|
|
|
= f.input :website, wrapper: :with_label, label: t('activerecord.attributes.doorkeeper/application.website')
|
2017-08-23 00:59:35 +02:00
|
|
|
|
|
|
|
.fields-group
|
|
|
|
= f.input :redirect_uri, wrapper: :with_block_label, label: t('activerecord.attributes.doorkeeper/application.redirect_uri'), hint: t('doorkeeper.applications.help.redirect_uri')
|
|
|
|
|
2019-12-09 04:30:58 +01:00
|
|
|
%p.hint= t('doorkeeper.applications.help.native_redirect_uri', native_redirect_uri: content_tag(:code, Doorkeeper.configuration.native_redirect_uri)).html_safe
|
2017-08-23 00:59:35 +02:00
|
|
|
|
2017-08-23 15:16:20 +02:00
|
|
|
.field-group
|
2018-07-05 18:31:35 +02:00
|
|
|
.input.with_block_label
|
|
|
|
%label= t('activerecord.attributes.doorkeeper/application.scopes')
|
|
|
|
%span.hint= t('simple_form.hints.defaults.scopes')
|
|
|
|
|
2023-07-20 17:03:39 +02:00
|
|
|
- Doorkeeper.configuration.scopes.group_by { |s| s.split(':').first }.each do |_key, value|
|
|
|
|
= f.input :scopes, label: false, hint: false, collection: value.sort, wrapper: :with_block_label, include_blank: false, label_method: ->(scope) { safe_join([content_tag(:samp, scope, class: class_for_scope(scope)), content_tag(:span, t("doorkeeper.scopes.#{scope}"), class: 'hint')]) }, selected: f.object.scopes.all, required: false, as: :check_boxes, collection_wrapper_tag: 'ul', item_wrapper_tag: 'li'
|