Scenario
The rails application is running mongoid. For every instance in the below model, there's a portfolio field which needs to be a .swf flash file.
class Person
include Mongoid::Document
field :name, type: String
field :skill, type: String
field :portfolio, type: String # portfolio will be a flash .swf and needs to have a static live url on the server
end
How do I arrange the the model to save the file locally on the server so every file will have a unique URL. ( not using carrierwave or paperclip )
Should I use asset pipeline or not? Because I'll be saving these files locally.
The end result I'm looking for is something like this:
http://www.persons.com/persons/portfolios/some_unique_id
A person can have only one portfolio, thus, not using reference.