Put back impressions for new and bulletin.
Add view_count field to tag.
This commit is contained in:
parent
4d7a53866e
commit
f3ccbce5c8
|
@ -4,7 +4,9 @@ class Tag
|
||||||
include Impressionist::Impressionable
|
include Impressionist::Impressionable
|
||||||
|
|
||||||
is_impressionable :counter_cache => { :column_name => :view_count }
|
is_impressionable :counter_cache => { :column_name => :view_count }
|
||||||
|
|
||||||
field :key
|
field :key
|
||||||
|
field :view_count, :type => Integer, :default => 0
|
||||||
#field :cloud_amper,:type: Integer,:default=> 0
|
#field :cloud_amper,:type: Integer,:default=> 0
|
||||||
belongs_to :module_app
|
belongs_to :module_app
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@ class Bulletin
|
||||||
|
|
||||||
#scope :searchable,where(:is_checked=>true,:is_hidden=>false,:is_pending=>false)
|
#scope :searchable,where(:is_checked=>true,:is_hidden=>false,:is_pending=>false)
|
||||||
|
|
||||||
# is_impressionable :counter_cache => { :column_name => :view_count }
|
is_impressionable :counter_cache => { :column_name => :view_count }
|
||||||
|
|
||||||
field :title, localize: true
|
field :title, localize: true
|
||||||
field :subtitle, localize: true
|
field :subtitle, localize: true
|
||||||
|
|
|
@ -17,7 +17,7 @@ class NewsBulletin
|
||||||
|
|
||||||
#scope :searchable,where(:is_checked=>true,:is_hidden=>false,:is_pending=>false)
|
#scope :searchable,where(:is_checked=>true,:is_hidden=>false,:is_pending=>false)
|
||||||
|
|
||||||
# is_impressionable :counter_cache => { :column_name => :view_count }
|
is_impressionable :counter_cache => { :column_name => :view_count }
|
||||||
|
|
||||||
field :title, localize: true
|
field :title, localize: true
|
||||||
field :subtitle, localize: true
|
field :subtitle, localize: true
|
||||||
|
|
Loading…
Reference in New Issue