I'm using paperclip/aws-sdk to upload images for specific models.
Upmin doesn't know how to deal with those fields in the way that paperclip needs it to so I'm building out my own form to upload files in the custom model view partial.
_app/view/upmin/partials/models/topic.html.erb
<%= form_for "#{topic.model}", url:(topic_path("#{topic.model}")) do |f| %>
<%= f.label :cover_image %>
<%= f.file_field :cover_image %>
<%= f.submit "new cover image" %>
<% end %>
Question
So to access the Topic object it has to be inside of a string and interpolated, as you can see above, but what's throwing me is how to then direct the action back to the topics_controller in the host app?
Rails throws the error undefined methodtopic_path' for #<#Class:0x007f88d2d280b8:0x007f88d289a820>`
Context
I'm using paperclip/aws-sdk to upload images for specific models.
Upmin doesn't know how to deal with those fields in the way that paperclip needs it to so I'm building out my own form to upload files in the custom model view partial.
_app/view/upmin/partials/models/topic.html.erb
Question
So to access the Topic object it has to be inside of a string and interpolated, as you can see above, but what's throwing me is how to then direct the action back to the topics_controller in the host app?
Rails throws the error
undefined method
topic_path' for #<#Class:0x007f88d2d280b8:0x007f88d289a820>`