I want to upload a csv file using active admin, and I would like to know if this is possible, create a from_tag inside of a f.input:
<%= f.inputs do%>
<%= f.input :contact, :as => :select, :collection => Contact.all %>
<%= f.input :route_import, :as => :select, :collection => RouteImporter.all %>
<% form_tag({:action => :upload}, :multipart => true) do %>
<%= file_field_tag 'upload_data'%>
<% end %>
<%end%>
When I run it I get this error:
Routing Error No route matches {:action=>"upload", :controller=>"admin/routes"}
I'm trying to call the method upload which is in RouteQuickcom class, what I'm doing wrong?Thanks!