about summary refs log tree commit diff stats
path: root/app/views/admin/links/_form.html.haml
blob: c624a3d07b17d1350e81c9d0b7bdc1db6fbde734 (plain) (blame)
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
%fieldset#content
  .title-field
    = f.label :title
    = f.text_field :title, placeholder: "Title"
  .url-field
    = f.label :url
    = f.text_field :url, placeholder: "URL"
%fieldset#details
  - if f.object.errors.any?
    #errors.details-module
      %h3 Error!
      %ul
        - f.object.errors.full_messages.each do |error|
          %li= error
  .details-module
    .tags-field
      = f.label :tag_list, "Tags"
      = f.text_field :tag_list, type: :tags, value: f.object.tag_list.join(",")
  .details-module
    = f.fields_for :records, Record.new do |builder|
      .should-create-record-field
        = builder.check_box :_destroy, {checked: false}, "0", "1"
        = builder.label :_destroy, "Create record?"
      .record-description-field
        = builder.text_area :description, placeholder: "record text"
  .details-module= f.submit