aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/DB/Result/Problem.pm
Commit message (Collapse)AuthorAgeLines
* [Oxfordshire] Traffic Management out of base.M Somerville2020-10-12-11/+0
|
* Do not display deleted priorities in inspect form.M Somerville2020-10-02-1/+5
|
* Remove use of $c from various functions.M Somerville2020-08-06-18/+22
| | | | This means these functions can more easily be used in a non-web context.
* Rewrite open311-update-reports to share code.Matthew Somerville2020-07-06-81/+0
| | | | | Make GetUpdates and GetServiceRequestUpdates share a common base; spot all visible states.
* Move per-row Contact lookup to the database.Matthew Somerville2020-05-06-20/+22
| | | | | | | | | | | On admin report lists, and in front-end lists when an inspector, each row was querying the database for `category_display`. We create a new relationship for this query, and join/prefetch it wherever we request this data. Include staff joins on /around page, copying what happens on /reports to prevent more lookups there too. Also add some joins for user email in admin report list.
* [EastSussex] display council reference number on reportStruan Donald2020-04-29-1/+1
|
* Fix lookup; App not available when run from scriptMatthew Somerville2020-02-14-1/+1
| | | | Not caught by test because App is loaded in tests.
* Link in other-reported email shows private report.Matthew Somerville2020-02-13-0/+25
| | | | | Use a token that does not log the user in, but lets the report be shown, even if it's a private report. Allow old tokens of that type to work.
* Display inline map for duplicate suggestions on mobileDave Arter2020-01-31-3/+7
| | | | For #2668.
* [Inactive] Add option to fully delete reports.Matthew Somerville2020-01-09-0/+11
|
* [fixmystreet.com] Limit TfL cobrand report displayMatthew Somerville2019-12-09-0/+2
| | | | | | | | | On fixmystreet.com, you cannot view reports made on the TfL cobrand, apart from on reporting seeing pins labelled with the report's category, linking through to the TfL cobrand. Output the pin's base URL if different from normal, so e.g. app can link appropriately.
* [TfL] Updates are sent to the body.Matthew Somerville2019-12-09-0/+2
|
* Switch to default-escaped in templates.Matthew Somerville2019-12-09-6/+11
| | | | | | | This means any variable used in a template is automatically HTML-escaped, unless it is marked as safe either in code by using a SafeString, or in the template with the `mark_safe` function or the `safe` filter.
* Allow cobrands to override category display.Matthew Somerville2019-10-25-1/+22
|
* [IsleOfWight] display external id as ref noStruan Donald2019-09-27-1/+1
| | | | Fixes mysociety/fixmystreet-commercial#1522
* Slightly simplify new report category handling.Matthew Somerville2019-09-05-7/+0
|
* prevent including email address in report titleStruan Donald2019-08-02-0/+3
| | | | | | | | If autofill on Chrome is turned on and has saved the user's login it can autofill the user's email address in the report title, so add validation to make sure the title does not look like an email. Fixes #2570
* [Hounslow] Show external ID on /report to staff.Matthew Somerville2019-06-11-1/+1
|
* Use EncodedColumn subclass.Matthew Somerville2019-05-02-3/+3
|
* Refactor datetime inflation.Matthew Somerville2019-05-02-57/+48
|
* Associate moderation history with admin log.Matthew Somerville2018-11-27-18/+6
|
* Show moderation history in report/update admin.Matthew Somerville2018-11-26-0/+7
|
* Store all moderation change history in database.Matthew Somerville2018-11-26-0/+4
| | | | | Currently keeping the same front end functionality of only reverting to the original.
* Deal with possible multiple send_method_useds.Matthew Somerville2018-11-06-1/+7
|
* Have body.url work in hashref lookup.Matthew Somerville2018-10-10-1/+1
| | | | | | | body.url could still be in use by old-school /reports table index pages (though they were dropped in 2.1, so a cobrand would have to have overridden it since then) and the update to speed up body lists in #2248 broke it. This puts it back in minimal form.
* Remove hard-coded body name in Problem.Matthew Somerville2018-10-09-4/+4
| | | | We can now use the new open311_post_update_skip function.
* Add get_cobrand_logged to Comment.Matthew Somerville2018-10-09-1/+1
|
* [Lincolnshire] Show external ID on report pagesDave Arter2018-08-17-1/+1
|
* Fix inspector dragging of pins.Matthew Somerville2018-08-09-0/+1
|
* Improve wording/grammar when report is sent to more than two bodiesDave Arter2018-03-29-10/+14
|
* [Zurich] Prefetch report users, cache body lookupsMatthew Somerville2018-03-19-1/+2
|
* Pass columns CSV needs into Problem->as_hashref.Matthew Somerville2018-03-19-12/+12
| | | | Then it can skip working out some things as they are not needed.
* [Zurich] Switch to more modern database states.Matthew Somerville2018-03-07-1/+13
| | | | | | | The Zurich code was written a long time ago, and used overriding so that e.g. the hard-coded 'investigating' state referred to Wunsch (wish). Now that states are stored in the database, we can create ones specially for Zurich and use them instead. Hooray!
* Hide 'updates not sent' message on reports sent via Open311Dave Arter2018-01-23-0/+27
| | | | | | | | | | | | | | | The 'updates are not sent to the council' message was incorrectly being shown on reports where updates would in fact be sent. This was affecting non-Bromley/Stevenage reports on fms.com and all cobrands using Open311. This commit moves the logic out of the template and adds the Problem->updates_sent_to_body method which inspects the receiving body's Open311 configuration to determine whether updates will be sent. The duplication of the Lewisham/Oxfordshire logic between Problem.pm and send-comments isn't ideal but hopefully there won't be any new Open311 bodies that only send and don't receive updates. If there are we'll have to look at refactoring that list.
* [Zurich] Allow publishing of individual photos.Matthew Somerville2018-01-18-32/+0
| | | | | When more than one photo has been uploaded, allow each one to be published/not independently.
* Store all successful send methods.Matthew Somerville2017-12-13-0/+11
|
* Fix issues with Problem->as_hashref.Matthew Somerville2017-11-30-2/+8
| | | | | Include actual times, not just human-readable ones, and make sure state is translated correctly.
* Adapt things that assume email will be present.Matthew Somerville2017-09-30-1/+10
| | | | | | This includes stopping some emails being sent (moderation, alert, questionnaire), dealing with Open311/email report sending, and tokenised_url.
* show nearest address for report in inspector panelStruan Donald2017-09-28-0/+9
| | | | | | | If we've stored the nearest address then display that at the top of the inspector panel. Fixes mysociety/fixmystreetforcouncils#234
* Fix bug in cookie passthrough query parameter.Matthew Somerville2017-09-27-5/+9
| | | | | For temp URLs there was not already a query string, and so "?" needs to be used rather than "&" when appending.
* include ward in dashboard csv exportStruan Donald2017-09-04-0/+1
| | | | | | | Adds a Ward column to the council dashboard CSV export with the name of the ward. Fixes mysociety/fixmystreetforcouncils#220
* Merge branch 'move-report-states-to-database'Matthew Somerville2017-08-31-38/+8
|\
| * Remove hardcoded states from Problem model.Matthew Somerville2017-08-31-38/+8
| | | | | | | | | | We keep the internal states hardcoded, plus the core open (confirmed) and closed ones, but the remainder are moved to the database.
* | Add LOGIN_REQUIRED config keyDave Arter2017-08-31-6/+12
|/ | | | If set to 1, this restricts all pages on the site to logged-in users.
* Drop council_states and $visible_states.Matthew Somerville2017-08-29-48/+4
|
* Use a schema cache to remember body lookups.Matthew Somerville2017-08-23-1/+5
|
* Cache Problem->bodies and prefetch the body areas.Matthew Somerville2017-08-18-7/+14
|
* Store duplicate reverse lookups upon dupe setting.Matthew Somerville2017-08-17-2/+13
| | | | | | This avoids the need to search the whole table to find a report's duplicates. And is easier than constructing an index or upgrading PostgreSQL.
* Prevent unnecessary string translation.Matthew Somerville2017-08-11-1/+1
| | | | | | Calling the function 'translate' causes gettext-extract to add the string to the .po file. Also, we no longer need an admin 'updated' message as the main form has its own success message.
* Set up translatable category columns.Matthew Somerville2017-08-10-7/+7
| | | | | | As category is used both for display and as a link between Problem and Contact tables, add `category_display` for use whenever a category is displayed.