rubyforgood / growhaus_sign_in

Growhaus Sign in
3 stars 2 forks source link

mightnight cleanup #79

Open bjmllr opened 9 years ago

bjmllr commented 9 years ago
SoldierCoder commented 9 years ago

this will be running on an ipad?

bjmllr commented 9 years ago

It will happen on the same server rails and pg are on, probably via cron.

rlwinter commented 9 years ago

@bjmllr There's a couple of wrinkles to the midnight cleanup that I explained to @SoldierCoder: The first you probably know: when ending activity_sessions, award them 1 hour of work and mark the one hour as estimated - the customer liked that idea. They also liked this more sophisticated idea: Try to lookup past activity_sessions and award the automatically closed activity_session the average of the last 3 activity_sessions, otherwise award 1 hour.

bjmllr commented 9 years ago

That makes sense. Since an activity_session refers to both a user and an activity, when estimating, would we limit the scope of activity_sessions considered by 0, 1, or both of those associations?