/lib/smartlib/views/admin/panels.erb

https://bitbucket.org/thrabal/smartlib · Ruby HTML · 21 lines · 17 code · 4 blank · 0 comment · 0 complexity · a1b8b4dc6ed122ebfd668649fd42f8f7 MD5 · raw file

  1. <% content_for :title do %>Sk?ín?<% end %>
  2. <h2>Sk?ín?</h2>
  3. <% @panels.each do |panel| %>
  4. <a href="<%= to("/panels/#{panel[:_id]}") %>"><%= panel[:name] %></a>
  5. <% end %>
  6. <hr>
  7. <h3>Nová sk?í?</h3>
  8. <form method="post" action="<%= to("/panels") %>">
  9. <input type="hidden" name="_method" value="PUT">
  10. <input type="text" name="name">
  11. <select name="footprint_id">
  12. <% @footprints.each do |footprint| %>
  13. <option value="<%= footprint[:_id] %>"><%= footprint[:name] %></option>
  14. <% end %>
  15. </select>
  16. <input type="submit" value="Vytvo?it">
  17. </form>