root/app/models/artwork_group.rb @ a579432b
b689e231 | Marc Dequènes (Duck) | class ArtworkGroup < ActiveRecord::Base
|
|
belongs_to :artwork_set
|
|||
has_many :artworks, :order => "title ASC"
|
|||
validates_presence_of :name, :artwork_set_id
|
|||
validates_uniqueness_of :name
|
|||
validates_length_of :name, :within => 1..128, :allow_blank => true
|
|||
validates_associated :artwork_set
|
|||
end
|