2018-11-08 19:23:39 +05:30
|
|
|
= form_for [:admin, @label], html: { class: 'label-form js-requires-input' } do |f|
|
2016-06-02 11:05:42 +05:30
|
|
|
= form_errors(@label)
|
2015-09-25 12:07:36 +05:30
|
|
|
|
2018-11-08 19:23:39 +05:30
|
|
|
.form-group.row
|
|
|
|
= f.label :title, class: 'col-form-label col-sm-2'
|
2015-09-25 12:07:36 +05:30
|
|
|
.col-sm-10
|
|
|
|
= f.text_field :title, class: "form-control", required: true
|
2018-11-08 19:23:39 +05:30
|
|
|
.form-group.row
|
|
|
|
= f.label :description, class: 'col-form-label col-sm-2'
|
2016-04-02 18:10:28 +05:30
|
|
|
.col-sm-10
|
|
|
|
= f.text_field :description, class: "form-control js-quick-submit"
|
2018-11-08 19:23:39 +05:30
|
|
|
.form-group.row
|
|
|
|
= f.label :color, _("Background color"), class: 'col-form-label col-sm-2'
|
2015-09-25 12:07:36 +05:30
|
|
|
.col-sm-10
|
|
|
|
.input-group
|
2018-11-08 19:23:39 +05:30
|
|
|
.input-group-prepend
|
|
|
|
.input-group-text.label-color-preview
|
2016-11-03 12:29:30 +05:30
|
|
|
= f.text_field :color, class: "form-control"
|
2018-11-08 19:23:39 +05:30
|
|
|
.form-text.text-muted
|
|
|
|
= _('Choose any color.')
|
2015-09-25 12:07:36 +05:30
|
|
|
%br
|
2018-11-08 19:23:39 +05:30
|
|
|
= _("Or you can choose one of the suggested colors below")
|
2015-09-25 12:07:36 +05:30
|
|
|
|
|
|
|
.suggest-colors
|
|
|
|
- suggested_colors.each do |color|
|
|
|
|
= link_to '#', style: "background-color: #{color}", data: { color: color } do
|
|
|
|
|
|
|
|
|
|
|
|
.form-actions
|
2018-12-05 23:21:45 +05:30
|
|
|
= f.submit _('Save'), class: 'btn btn-success js-save-button'
|
2018-11-08 19:23:39 +05:30
|
|
|
= link_to _("Cancel"), admin_labels_path, class: 'btn btn-cancel'
|