similar to: attachment_fu has_attachment model logic reasoning?

Displaying 20 results from an estimated 2000 matches similar to: "attachment_fu has_attachment model logic reasoning?"

2010 Apr 24
2
problem using attachment_fu with S3
Hi, My S3 bucket is located in the US I have attachment_fu working when using file system storage I have sw-swf upload plugin working with my S3 account but I can not get attachment_fu to work with S3 storage. the error I get is : AWS::S3::RequestTimeout in Upload filesController#create Your socket connection to the server was not read from or written to within the timeout period. Idle
2008 Sep 02
4
Attachment_fu, Paperclip, & S3
For various reasons, I made a git branch and installed Paperclip in place of attachment_fu. Paperclip works great except that images seem to have lost some quality; edges have gone a little too jaggy to be able to drop attachment_fu just yet. After a post on the Paperclip Google Group, someone suggested the :convert_options could be passed additional attributes, like ''quality'',
2007 Sep 25
2
attachment_fu default path
Hi all. I''ve done a little google search, but doesn''t find anything (with "attachment_fu default path") that could help me in changing attachment_fu''s default path. My model: [audio.rb] has_attachment :max_size => 20.megabytes has_attachment :content_type => "audio/mpeg" has_attachment :storage => :file_system
2007 Mar 11
4
Faking it... import local files into attachment_fu
Hello, I''m working on an import utility that will match the functionality of uploading an object of a model that uses attachment_fu for thumbnailing, etc. Rather than uploading the file via a form, I want to populate the params[:image][:uploaded_data] with data from a file already on the server''s file system. So far, I''ve been able to copy to an instance of Tempfile
2009 Apr 21
3
attachment_fu giving problem on production
Hello friends, I have configured attachment_f. It''s working fine on Local(development) system but giving problem on production. Basically on production the attachment_fu is not able to generate thumbnail image it saving the original size image. Below is the configuration. has_attachment :content_type => :image, :storage => :file_system, :max_size
2007 Apr 27
3
attachment_fu content_type problem
Hi all.... Admittedly I''m new to Rails and trying to find my way but I''m having an issue with uploading documents with attachment_fu. I have a form where I''m uploading multiple attachments (using AJAX to add file_filed_tags). That seems to work pretty well. The problem is I can''t seem to get the content_type to work as I would expect. For example, if I use
2008 May 28
1
Attachment_fu, polymorphism and customization
Hi, I got Image model that has_attachment and belongs_to 2 other models via polymorphic association. The problem is that I''d like to customize has_attachment options (resize image) depending on which model the Image is related to - i.e. if Image belongs to Article it should be resized using different settings than if it belongs to Header. Is there a smart way to do it or do I have to
2007 Apr 17
1
attachment_fu - propagating attributes to thumbnails
I have a model using attachment_fu (via has_attachment) and I''m creating thumbnails for the attached images. I have an extra field ''foo'' that I''m validating on create with validates_presence_of :foo. One problem arises when I upload an image: The ''foo'' is not propogating down to the thumbnails. What should I put in my model to grab the
2007 Sep 18
2
Making attachment_fu polymorphic
I am working on a small model mixin called attachment_kung to make attachment_fu polymorphic, so you no longer need a different table and Model class for every associated attachment (Productimage, Ad_doc, etc). All you really need is one model and table to handel all your attachments - in some cases, anyway. I have the code working, but have run into one small hitch that I can''t seem to
2007 May 07
1
attachment_fu seems to be searching the wrong location for my images
I just installed attachment_fu and for some reason, it seems to be looking in the wrong location for my images. I have a Product model that belongs to a photo model. the photo model has the attachment_fu installed and configured like so: class Photo < ActiveRecord::Base has_attachment :content_type => :image, #Allow standard image formats :path_prefix
2007 Aug 22
8
How to spec an attachment_fu model
First off, I''m not trying to spec attachment_fu, I know it''s been tested. But, I added some code to that model that I do need to test. Basically, I need to somehow fulfill the "uploaded_data" property so I can actually run my tests(otherwise they fail because of validations). The "uploaded_data" field is what would grab the multipart data from form. Here
2007 Apr 21
3
attachment_fu thumbnails
howdy! I had the problem that attachment_fu didn''t make a thumbnail, but everything else worked. I read this post http://www.ruby-forum.com/topic/104213 and added a parent_id column. now I get the following error when I trie to add a photo: undefined method `find_or_initialize_by_thumbnail_and_parent_id'' for Photo:Class my code is: class Photo < ActiveRecord::Base
2010 Apr 03
0
Change from attachment_fu db BLOB to Paperclip S3
Hi: I have moved from using attachment_fu with files stored in the DB to Paperclip using S3. The trick now is to migrate the files from the DB to S3. I have tried a few methods like: SThreeFile.create(:file => AttachmentFuFile.first.data) and @attachment = AttachmentFuFile.first SThreeFile.create(:file => ActionController::Streaming.send_data @attachment.data, :filename =>
2007 Mar 28
3
attachment_fu Not Resizing
Hello, Recently attachment_fu stopped resizing images for me. I''m puzzled because before today it was resizing them and I don''t know what''s changed. Here''s my code: class Product < ActiveRecord::Base has_attachment :content_type => :image, :storage => :file_system, :max_size => 18.megabytes,
2007 Apr 08
13
attachment_fu thumbnail not created
I followed the instructions on Mike Clark''s weblog and everything works perfectly except the thumbnail column in my DB is alwas NULL. I''m using S3 as my storage system. Anyone else having this issue with thumbnails? has_attachment :content_type => :image, :storage => :s3, :max_size => 500.kilobytes, :resize_to =>
2009 Aug 17
0
Paperclip: processor proc not firing
Hi It''s extremely rare that I have to post something on the Rails list, but this is one of those times that I''ve been completely stuck for countless hours. Environment: Rails 2.3.3 I''ve implemented a custom processor proc for video thumbnailing with Paperclip (latest trunk version as git submodule, and yes, it''s updated) using the instructions posted
2010 Sep 29
4
Best image upload plugin?
Hey everyone, I''ve been dealing with Rails 3, Paperclip and Windows 7 for a few nights now and don''t feel like I''m actually getting anywhere. I''ve hit config issue after config issue and it''s a bit of a nightmare. Can anyone recommend any other gems that will accomplish the same thing? Thanks, Brandon -- Posted via http://www.ruby-forum.com/. --
2011 Sep 15
2
Dragonfly and Zip uploads
I''m poring through the Dragonfly source code right now, trying to get a handle on how to apply the following technique there: Client uploads a Zip archive containing N images, PDF files, text files, etc. When that file arrives at the server, but before it is stored as an attachment to the current object, the Zip is burst open, contents are iterated over, and each contained file is saved
2008 Jun 09
10
Testing file attachment with Paperclip
Does someone have an example on faking a file upload for just ensuring it gets called, without actually uploading the file to s3. I thought that stubbing Model.has_attached_file would be enough, but it doesn''t seem so ... This is what I did: Video.stub!( :has_attached_file ).with( :name ).and_return( true ) has_attached_file is from paperclip, it gets mixed to the model. 1)
2007 Jun 30
8
attachment_fu not working on Textdrive
I have attachment_fu working on my local Windows machine (localhost: 3000) But when I transfer it to Textdrive (Solaris), it doesn''t work. Any ideas? Give it a shot: http://haloresearch.textdriven.com:8217/raw_data_files/new I haven''t got the logger working yet on TextDrive, but that will be my next step. Any suggestion on what things to look at first? Chirag