Custom URLs - Admin Panel

Don't delete custom URLs linked from the menu!

<% @custom_urls.each do |url| %> <% end %>
Name Article Actions
<%= url.name %> <%= url.article.title %> <%= link_to_function icon('pencil'), "showEdit(#{url.id})" %> <%= link_to_function icon('times'), "deleteUrl(#{url.id})" %>
<% unless @custom_url.errors.empty? %>

Errors:

    <% @custom_url.errors.full_messages.each do |error| %>
  • <%= error %>
  • <% end %>

<% end %> <%= form_for @custom_url do |f| %>
<%= f.text_field :name %>
<%= f.select :article_id, Article.all.collect {|t| [t.title, t.id]} %> <%= f.submit 'Add', class: 'button' %>
<% end %>