jeudi 3 septembre 2015

Rails uploading a specific file

I have an Attachment model, and it keeps a file. I m using paperclip, that's why I keep it like

t.attachment :file

I want to upload a file in a specific path like

:rails_root/non-public/sample.txt

How can I upload this file without using a form. Is there any way to do?

Aucun commentaire:

Enregistrer un commentaire