| Commit message (Collapse) | Author | Age | Lines |
|
|
|
| |
Some Public Body names contain commas (or other characters) which lead
to a malformed CSV where parts of the body name are in later columns.
|
|
|
|
|
| |
Was confusing what the number meant; easier to just sum numbers in the
quartery columns to get totals.
|
| |
|
|\
| |
| |
| | |
ssh://git.mysociety.org/data/git/public/alaveteli into rails-3-develop
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We have changed the denominator of the proportion-based statistics
to only include requests that are both visible and not
'awaiting_description'. This would mean, however, that the numerator
could be larger than the denominator. This commit updates the
calculation of those statistics to also exclude any hidden or
unclassified requests.
|
|/
|
|
| |
This is in the service of #1173 and #1174.
|
|
|
|
|
|
|
|
| |
This task was taking a huge amount of memory, even when fetching
the InfoRequest objects with find_each. With an additional find_each
for public bodies (10 at a time) and reducing the batch size for
info requests to 200 at a time, the memory size of this rake task is
kept down to about 400MB.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On PublicBody, we don't need to update info_requests_count
because that's already done with :counter_cache. On the
other hand, info_requests_successful_count and
info_requests_not_held_count can't be updated easily with
counter_cache (since they need conditions to be attached).
Instead we update them in post_save and post_destroy,
as suggested here:
http://blog.douglasfshearer.com/post/17495285851/custom-counter-cache-with-conditions
This also adds tests to ensure that the
after_(save|destroy) callbacks are called and that they
modify the counts correctly.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The statistics on the status of the requests to a particular
public body are too slow to calculate on-the-fly, so this
commit adds:
* Extra columns on public_bodies to store counts of
the successful, not held, and overdue request counts
for each public body.
* A rake task which should be run periodically to update
the overdue request count column.
If Javascript is not available, the summary statistics are
shown as tables. If Javascript is available, graphs are
drawn with Flot.
|
| |
|
| |
|
| |
|
|
|