Module: Locomotive::SimpleForm::HeaderLink
- Included in:
- ArrayInput, EditableSelectInput
- Defined in:
- lib/locomotive/simple_form.rb
Instance Method Summary collapse
Instance Method Details
#_header_link(name, type) ⇒ Object
22 23 24 25 26 27 28 29 30 |
# File 'lib/locomotive/simple_form.rb', line 22 def _header_link(name, type) if = [name] label = [:label] || I18n.t(:edit, scope: ['locomotive.shared.form', type]) url = [:url] template.link_to(label, url, class: 'action') else '' end end |