Track newly created cards
This commit is contained in:
parent
6a6a31b77c
commit
7419056e2c
2 changed files with 4 additions and 2 deletions
|
@ -37,6 +37,8 @@ class Card < ActiveRecord::Base
|
||||||
|
|
||||||
default_scope { order(:gameid) }
|
default_scope { order(:gameid) }
|
||||||
|
|
||||||
|
scope :new_this_week, -> { where('created_at > ?', 1.week.ago) }
|
||||||
|
|
||||||
def dokkan?
|
def dokkan?
|
||||||
dokkan_id != nil
|
dokkan_id != nil
|
||||||
end
|
end
|
||||||
|
|
|
@ -5,8 +5,8 @@
|
||||||
.col-xs-3
|
.col-xs-3
|
||||||
= glyph 'credit-card', classes: 'large-icon'
|
= glyph 'credit-card', classes: 'large-icon'
|
||||||
.col-xs-9.text-right
|
.col-xs-9.text-right
|
||||||
.huge XX
|
.huge= Card.new_this_week.count
|
||||||
div New Cards!
|
div New Cards This Week!
|
||||||
a href="#"
|
a href="#"
|
||||||
.panel-footer
|
.panel-footer
|
||||||
.pull-left View Details
|
.pull-left View Details
|
||||||
|
|
Loading…
Reference in a new issue