Class: Topic

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
lib/generators/forum_monster/templates/models/topic.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#bodyObject

Accessors



9
10
11
# File 'lib/generators/forum_monster/templates/models/topic.rb', line 9

def body
  @body
end

Instance Method Details

#hit!Object

Methods



25
26
27
# File 'lib/generators/forum_monster/templates/models/topic.rb', line 25

def hit!
  self.class.increment_counter :hits, id
end