Paperclippolymorph lets you “attach” multiple files (images, files, pdfs, etc), otherwise known as “assets” to various items you have models for.
For example suppose I had a tattoo shop website. I would like to display artists profiles and pictures of tattoos done by the artists. I would create a model for “Artists” and a model for “Tattoos” and use a relationship of “has_many” to relate the two models.
Artists has_many :tattoos
But I want each tattoo resource to have many images so artists can take multiple shots of any one tattoo and be able to display them all.
Also each artist should have a “profile” where multiple images of himself, his work space, or other inspirations could be displayed. In other words I want to “attach” many “assets” to both “artists” and “tattoos” and display them.
Note the terminology used here: An “asset” is an image, pdf, or other “attaching” that you add via a form upload and can be “attached” to a resource (something you have a model for). To “detach” an asset is to remove it from the resource while “attach” is to add it to a resource.