reformatted a bit project model
This commit is contained in:
parent
9eba4ca4d9
commit
de2dc18249
|
@ -1,10 +1,11 @@
|
||||||
class Project < ActiveRecord::Base
|
class Project < ActiveRecord::Base
|
||||||
|
belongs_to :platform
|
||||||
|
|
||||||
validate :name, :uniqueness => true, :presence => true
|
validate :name, :uniqueness => true, :presence => true
|
||||||
validate :unixname, :uniqueness => true, :presence => true
|
validate :unixname, :uniqueness => true, :presence => true
|
||||||
before_validation :generate_unixname
|
|
||||||
validate :validate_unixname
|
validate :validate_unixname
|
||||||
|
|
||||||
belongs_to :platform
|
before_validation :generate_unixname
|
||||||
|
|
||||||
protected
|
protected
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue