mirror of https://github.com/fspc/BikeShed-1.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
250 B
16 lines
250 B
class Role < ActiveRecord::Base
|
|
attr_accessible :role
|
|
|
|
has_many :user_role_joins
|
|
has_many :users, through: :user_role_joins
|
|
validates_uniqueness_of :role
|
|
|
|
|
|
def to_s
|
|
self.role
|
|
end
|
|
|
|
def ==(other)
|
|
self.role == other.role
|
|
end
|
|
end
|
|
|