Hi there!

I am trying to get attachment_fu to work. It is so good as done, just
one strange error is still there.

this is my model:

--------------------------------------------------------------------

class Motorbike < ActiveRecord::Base

  has_attachment :content_type => :image,
                 :storage => :file_system,
                 :max_size => 500.kilobytes,
                 :resize_to => '800x600>',
                 :thumbnails => { :thumb => '100x100>' }

  validates_as_attachment

  validates_presence_of :brand

end

--------------------------------------------------------------------

If there is an other validation instead of the attachment_fu the model
pop up this error:

ActiveRecord::RecordInvalid in MotorbikesController#create
Validation failed: Brand can't be blank

If there is only the attachment_fu validation, everything works great.

What could be the reason or is there a good way around?

Greenting Chaos
-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to