public
Description: Treat an ActiveRecord model as a file attachment, storing its patch, size, content type, etc.
Homepage: http://weblog.techno-weenie.net
Clone URL: git://github.com/technoweenie/attachment_fu.git
Click here to lend your support to: attachment_fu and make a donation at www.pledgie.com !
Add documentation for new :partition option
eadz (author)
Mon Jun 09 03:10:39 -0700 2008
commit  8a1e64917001305ba401785ce2682ac1b336365e
tree    eed4d244168e8b3c2dacc67902bfedd6e2522ce6
parent  e1c9c83ed7d338651b51c23b0d583ff6c9c5fe0e
0
...
44
45
46
 
47
48
49
...
60
61
62
63
 
64
65
66
...
44
45
46
47
48
49
50
...
61
62
63
 
64
65
66
67
0
@@ -44,6 +44,7 @@ has_attachment(options = {})
0
     :path_prefix # path to store the uploaded files.
0
                       # Uses public/#{table_name} by default for the filesystem, and just #{table_name} for the S3 backend.
0
                       # Setting this sets the :storage to :file_system.
0
+ :partition # Partiton files in directories like /0000/0001/image.jpg. Default is true.
0
     :storage # Specifies the storage system to use..
0
                       # Defaults to :db_file. Options are :file_system, :db_file, and :s3.
0
     :processor # Sets the image processor to use for resizing of the attached image.
0
@@ -60,7 +61,7 @@ has_attachment(options = {})
0
     has_attachment :thumbnails => { :thumb => [50, 50], :geometry => 'x50' }
0
     has_attachment :storage => :file_system, :path_prefix => 'public/files'
0
     has_attachment :storage => :file_system, :path_prefix => 'public/files',
0
- :content_type => :image, :resize_to => [50,50]
0
+ :content_type => :image, :resize_to => [50,50], :partition => false
0
     has_attachment :storage => :file_system, :path_prefix => 'public/files',
0
                    :thumbnails => { :thumb => [50, 50], :geometry => 'x50' }
0
     has_attachment :storage => :s3

Comments

    No one has commented yet.