Rails 3 app with paperclip.
Given a Paperclip File Model, how can you move that paperclip File to different paperclip, 开发者_运维百科say image gallery? Which would have different processing rules etc?
Any ideas?
I've just tried the following:
Given two models, with a picture
attachment and their own Paperclip configurations, say: Gallery1 and Gallery2.
Given I had one object in Gallery1 with a picture already attached.
Make:
Gallery2.create(:picture => Gallery1.first.picture)
And it creates the picture properly resized with the constraints of Gallery2.
精彩评论