Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
MR Dash
Início: 13 de Outubro de 2011
Deadline: 13 de Abril de 2013
Dias restantes: 375
Dias totais: 548
Membros: 17461
Restantes: 82539
Ideal: 183
Média real: 100
Ontem: 40
Hoje: 221
##########################
# #
# Dashboard do Meu Rio #
# #
##########################
Restam 82539 membros
Precisamos de 220 novos membros por dia
Ontem tivemos 40 novos membros
Ontem atingimos 18% da meta diária
remaining = 100000 - Member.where("created_at < ?", Date.today).count
daily_goal = remaining/(Date.parse("13/4/2013") - Date.today).to_i
yesterday_counter = Member.where("created_at >= ? AND created_at < ?",Date.today - 1.day, Date.today).count
yesterday_percent = yesterday_percent = yesterday_counter.to_f/daily_goal
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.