Sha256: 4cf3d183f11505ad961bd36252d9be0ed3e837b4c799a2860b3d63d295d8b3b4

Contents?: true

Size: 530 Bytes

Versions: 8

Compression:

Stored size: 530 Bytes

Contents

<% chosen_class = "chzn-select-#{attribute_id}" %>

<li id="<%= attribute_id %>_li">
  <%= form.label attribute, label_text %>
  <% if values.any? %>
    <%= form.select related_fk, values, options, html_options.merge(:class => chosen_class, :style => "width: 350px;") %>
  <% else %>
    <%= Typus::I18n.t("No %{resources} found.", :resources => related.model_name.human.downcase.pluralize) %>
  <% end %>
</li>

<script type="text/javascript">
  $(document).ready(function () { $(".<%= chosen_class %>").chosen(); });
</script>

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
typus-3.1.10 app/views/admin/templates/_belongs_to.html.erb
typus-3.1.9 app/views/admin/templates/_belongs_to.html.erb
typus-3.1.8 app/views/admin/templates/_belongs_to.html.erb
typus-3.1.7 app/views/admin/templates/_belongs_to.html.erb
typus-3.1.6 app/views/admin/templates/_belongs_to.html.erb
typus-3.1.5 app/views/admin/templates/_belongs_to.html.erb
typus-3.1.4 app/views/admin/templates/_belongs_to.html.erb
typus-3.1.3 app/views/admin/templates/_belongs_to.html.erb