14 lines
208 B
Ruby
14 lines
208 B
Ruby
module AccessHelper
|
|
def can_create_user? user
|
|
user && user.admin?
|
|
end
|
|
|
|
def can_edit_user? user
|
|
user && user.admin?
|
|
end
|
|
|
|
def can_page? user
|
|
user && (user.admin? || user.staff?)
|
|
end
|
|
end
|