| Commit message (Collapse) | Author | Age | Lines |
|
|
|
| |
These are regenerated with "bundle exec annotate"
|
|
|
|
|
|
|
|
| |
For importing a very large number of public bodies, it's mostly likely
less frustrating to import them from the CSV file using this rake task
instead of using the form in the admin interface.
Fixes #1132
|
|\ |
|
| |
| |
| |
| |
| | |
Apart from anything else, we don't want translators to have to worry
about the special case text. See https://github.com/mysociety/whatdotheyknow-theme/commit/2078febca5181ce3b1a9c0fae0123ae5f6448718 for the corresponding change to whatdotheyknow-theme.
|
|\ \ |
|
| |/ |
|
|/
|
|
|
|
|
|
| |
In the rare circumstance that someone created a public body
whose name started with a lower case letter outside [a-z]
with Alaveteli running under Ruby 1.8, the letter would not be
upcased correctly before saving to the first_letter column.
This commit fixes that by using a Unicode-aware upcase function.
|
|
|
|
| |
Fixes #1104.
|
|\ |
|
| |
| |
| |
| | |
Fixes #1082.
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
Gemfile
app/views/admin_request/edit_outgoing.html.erb
config/packages
doc/CHANGES.md
doc/INSTALL.md
spec/models/info_request_spec.rb
spec/models/public_body_spec.rb
|
| | |
| | |
| | |
| | |
| | | |
Make old_unclassified_params method consistent with
last_public_response_event and associated methods.
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
get_last_response_event and get_last_outgoing_event are used in various
places to determine which events to link to, use in queries etc.
Restrict them to refer to the last publicly visible event of the
relevant type, and rename them to make that clear.
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | | |
Add some tests that it's working on the outgoing message model.
|
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
app/views/request/_incoming_correspondence.html.erb
|
| | |
| | |
| | |
| | |
| | |
| | | |
At least some of the logic for incoming and outgoing message prominence
is going to be identical, so move it to a module they can both include
and use.
|
| | |
| | |
| | |
| | |
| | |
| | | |
Use send_file to send zips. Also adds 'all_can_view_all_correspondence?'
- is this request completely cachable, or do we need to cache different
versions for different levels of privilege?
|
| | | |
|
| | |
| | |
| | |
| | | |
We're about to reuse them for the text view.
|
| | | |
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | | |
This will cover changes in prominence to incoming messages.
|
| | | |
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | | |
Move it into the Ability module.
|
| | | |
|
| | |
| | |
| | |
| | | |
A super user will be able to see all hidden things, not just requests.
|
| | |
| | |
| | |
| | |
| | | |
Add a convenience method for getting the 'response' event associated
with an incoming message.
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Add a migration to remove the unused column 'prominence' from
info_request_events, remove validation of prominence, remove unused
InfoRequestEvent.user_can_view? method. Remove references to
InfoRequestEvent.prominence.
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
We were already excluding graphs where all the data was NULL
but it's possible by directly manipulating the database to
have some values NULL and some non-NULL, so exclude any NULL
values anyway.
|
| | |
| | |
| | |
| | |
| | |
| | | |
Move the calculation of statistics on public bodies into
the PublicBody model, so that there's less logic in the
controller.
|
| |/
|/|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
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.
|
| |
| |
| |
| |
| |
| | |
Add some notes on the logic and expectations around
InfoRequest.described_state and calculate_status and
InfoRequestEvent.described_state and calculated_state.
|
| |
| |
| |
| |
| |
| |
| | |
Make sure that admin edits changing the described state of an info
request are reflected in the latest_status and status values of info
request events so that the info requests are retrieved correctly in
status-based searches.
|
|/
|
|
|
|
|
|
| |
Update test expectations and add further test to explicitly show that we
want the described status from a status update to be propagated to a
preceding response, as well as being filled in in the status update
itself (which is mostly to deal with the case where there isn't a
preceding response). Make those changes to calculate_event_states
|
|
|
|
| |
ruby 1.8 by using mb_chars for length comparison - it counts multibyte characters.
|
|\
| |
| |
| |
| |
| |
| | |
'openaustralia_github/tests_set_described_state' into rails-3-develop
Conflicts:
spec/models/info_request_spec.rb
|
| | |
|