sprint velocity optimizations and fixes

velocities cached in model
mean velocity based on projects's sprints instead of all sprints
task danger is working again
migration for calculating velocities ans storing them in model