Sha256: 75cb767c122d26f45082cc7dae8c5a26c307af6120d9bedd62ae51e8a74d0425
Contents?: true
Size: 1006 Bytes
Versions: 31
Compression:
Stored size: 1006 Bytes
Contents
<div class="dd"> <ol class="dd-list"> <% if @ancestry_field.present? %> <% else %> <% @model_class.all.order("#{@position_field} ASC").each do |m| %> <li class="dd-item" data-id="<%= m.id %>"> <div class="dd-handle"><%= show_object(m) %></div> </li> <% end %> <% end %> </ol> </div> <br /> <%= form_tag(nil, method: 'post') do %> <%= hidden_field(:nestable, :data) %> <%= button_tag(type: 'submit', class: 'btn btn btn-success', name: 'submit_redirect') do %> <i class="fa fa-save"></i> <i class="icon-action-undo"></i> <%= t('slash_admin.view.save_and_return_html') %> <% end %> <button type="submit" class="btn btn-primary float-right"> <i class="fa fa-save"></i> <%= t('slash_admin.view.save') %> </button> <% end %> <script type="text/javascript"> $('.dd').nestable({ maxDepth: <%= @max_depth %> }).on('change', function() { $('#nestable_data').val(JSON.stringify($('.dd').nestable('serialize'))); }); </script>
Version data entries
31 entries across 31 versions & 1 rubygems