Class: SimpleCms::Page
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- SimpleCms::Page
- Defined in:
- app/models/simple_cms/page.rb
Direct Known Subclasses
Instance Method Summary collapse
Instance Method Details
#editable?(user) ⇒ Boolean
12 13 14 15 16 17 |
# File 'app/models/simple_cms/page.rb', line 12 def editable?(user) return false if user.nil? return true if user.admin? return true if users.include?(user) false end |