Sha256: a685464b875a552fb35935b1ed0ae2086eec67ad70c61119dc6310bbf64b44dd

Contents?: true

Size: 746 Bytes

Versions: 5

Compression:

Stored size: 746 Bytes

Contents

= reflection_node f, field do
  - ref_object = f.object.send(field.reflection.name)
  %p.empty{:class => ('hide' if ref_object)}= t 'bhf.helpers.entry.empty', :count => 1
  %ul.relation{:class => field.macro}
    %li
      - if ref_object
        = link_to_if field.link, ref_object.to_bhf_s, edit_bhf_entry_embed_path(field.link || 0, f.object, ref_object), :class => :quick_edit
        - if field.link
          = link_to '×'.html_safe, bhf_entry_embed_path(field.link, f.object, ref_object), :method => :delete, :class => :delete, :remote => true, :confirm => t('bhf.helpers.promts.confirm')

  - if field.link
    = link_to '+', new_bhf_entry_embed_path(field.link, f.object), :class => "add_field quick_edit #{('hide' if ref_object)}"

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
bhf-0.4.2.2 app/views/bhf/entries/form/embeds_one/_static.haml
bhf-0.4.2.1 app/views/bhf/entries/form/embeds_one/_static.haml
bhf-0.4.2 app/views/bhf/entries/form/embeds_one/_static.haml
bhf-0.4.1 app/views/bhf/entries/form/embeds_one/_static.haml
bhf-0.4.0 app/views/bhf/entries/form/embeds_one/_static.haml