Module: Cms::Behaviors::Hiding::InstanceMethods

Defined in:
lib/cms/behaviors/hiding.rb

Instance Method Summary collapse

Instance Method Details

#hideObject


23
24
25
26
27
# File 'lib/cms/behaviors/hiding.rb', line 23

def hide
  self.hidden = true
  self.version_comment = "Hidden"         
  self.save
end

#hide!Object


28
29
30
31
32
# File 'lib/cms/behaviors/hiding.rb', line 28

def hide!
  self.hidden = true
  self.version_comment = "Hidden"
  self.save!
end

#unhideObject


33
34
35
36
37
# File 'lib/cms/behaviors/hiding.rb', line 33

def unhide
  self.hidden = false
  self.version_comment = "Unhidden"          
  self.save
end

#unhide!Object


38
39
40
41
42
# File 'lib/cms/behaviors/hiding.rb', line 38

def unhide!
  self.hidden = false
  self.version_comment = "Unhidden"          
  self.save!
end