dallasrb / dallasrb-web

The Dallas Ruby Brigade Website
10 stars 14 forks source link

Members page issues #51

Open caseylang opened 10 years ago

caseylang commented 10 years ago

I think someone created a script a while back to display members based on different criteria such as profile completeness. I also seem to remember it not being compute on request but being a rake task. It might be time to run that script again as the first page is all blank profiles.

There is also a style issue with the paginator

screen shot 2014-06-30 at 5 11 12 pm

ckrailo commented 10 years ago

Running rake sort:epic didn't seem to fix that. :( I'll have to dig in more.

ckrailo commented 10 years ago

Here's the problem on production...

irb(main):005:0> Profile.where("name != ''").count
   (2.3ms)  SELECT COUNT(*) FROM "profiles" WHERE (name != '')
=> 107
irb(main):006:0> Profile.where("name = ''").count
   (2.0ms)  SELECT COUNT(*) FROM "profiles" WHERE (name = '')
=> 22
irb(main):007:0> Profile.where("name = ''").pluck(:sort_order)
   (1.7ms)  SELECT sort_order FROM "profiles" WHERE (name = '')
=> [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
irb(main):008:0> Profile.where("name != ''").pluck(:sort_order)
   (1.9ms)  SELECT sort_order FROM "profiles" WHERE (name != '')
=> [0, 0, 0, 0, 0, 95, 0, 96, 0, 86, 0, 1, 99, 90, 0, 33, 81, 0, 85, 0, 94, 65, 49, 20, 93, 94, 93, 84, 86, 68, 99, 91, 99, 88, 81, 82, 96, 50, 88, 93, 83, 72, 89, 89, 2, 88, 3, 0, 0, 37, 5, 98, 94, 5, 81, 39, 18, 86, 76, 90, 82, 86, 6, 91, 25, 86, 82, 49, 23, 4, 93, 83, 97, 99, 33, 59, 93, 98, 93, 85, 12, 97, 86, 92, 84, 82, 84, 99, 84, 95, 94, 6, 99, 0, 0, 0, 5, 0, 0, 0, 0, 92, 31, 47, 85, 98, 10]