aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/DB
Commit message (Collapse)AuthorAgeLines
* Update templates when category/state changed.Matthew Somerville2017-06-30-0/+27
| | | | | | When the category or state changes, the list of available templates updates (previously it was frozen at what the category was on page load, and didn't care about the state).
* [fixmystreet.com] Template/priorities in fixture.Matthew Somerville2017-06-20-0/+25
| | | | Also include areas in auto-generated problems.
* Return Response Priorities as JSON.pezholio2017-06-20-13/+11
| | | | | This now lets the response priority and defect type handling share the same code.
* Populate defect types dropdown on category changepezholio2017-06-20-13/+19
|
* [UK] Remove requirement for fixed body IDs.Matthew Somerville2017-06-20-14/+19
| | | | | | | | | | | | Historically in UK cobrands, bodies have had IDs the same as the MapIt area ID they cover. This can be confusing (if you are setting up a dev environment, say) and should not be necessary. This commit removes the requirement entirely, by switching any ID checks to either the name of the body, or the actual area it covers. One note: the body name in the test has to match so that we do not get two bodies both covering 2237 created. This will not be necessary when the tests are compartmentalized in the next commit.
* [fixmystreet.com] Improve fixture loading script.Matthew Somerville2017-06-20-0/+155
| | | | | | Given a MapIt area ID, the script will create a body and categories, users with different levels of permissions, and some random problems and updates. It can optionally empty out the database first.
* [Oxfordshire] Show problem state in marker tooltipZarino Zappia2017-06-10-2/+3
| | | | Add hook so that cobrands can change pin hover title.
* Refactor pretty state display.Matthew Somerville2017-06-10-31/+2
|
* Add update URL model method.Matthew Somerville2017-05-31-0/+5
|
* Move alert signup logic out of controllerpezholio2017-05-05-0/+21
|
* Add customisable defect types.Dave Arter2017-03-23-6/+178
| | | | | | | | | Problems can have an associated defect type, that can be assigned during an inspection. Include an admin interface for managing these types, that can also be assigned on a per-category basis, currently available to the Oxfordshire cobrand. (Also include 'TM' in traffic management Exor RDI output.)
* Add is_in_progress Problem helper.Matthew Somerville2017-03-10-0/+10
|
* Refactor SendReport::Open311 to use cobrand hooks.Matthew Somerville2017-03-09-3/+16
| | | | | | | | | | | | | | Avoid doing cobrand-specific logic within SendReport::Open311. The hooks defined are: open311_config: set extra fields open311_pre_send: set endpoints and munge data These are tested in the new t/app/sendreport/open311.t, which does not send any actual reports, but just checks that all the data is munged into the expected format. (tests under t/open311* should already test the actual sending) Remove unused Open311 special cases.
* [Oxfordshire] Use 'days ago' format on problem listspezholio2017-02-27-0/+14
| | | | Fixes mysociety/fixmystreetforcouncils#98
* [Oxfordshire] Add Exor RDI file download featureDave Arter2017-02-15-0/+9
| | | | | | | | | | The RDI file format encapsulates information about inspections that have taken place, and can be uploaded into Exor to create defects in bulk. This commit adds a page to the Oxfordshire cobrand's admin allowing RDI files to be generated and downloaded from FMS. For mysociety/fixmystreetforcouncils#127
* Add external_id field to ResponsePriority for use with ExorDave Arter2017-02-15-2/+4
|
* Add cobrand call_hook fn, calls a fn if defined.Matthew Somerville2017-02-15-14/+5
|
* Add Problem->tokenised_url for logging user inpezholio2017-02-15-0/+26
| | | | | | This method creates a token that logs the reporting user in, optionally with some parameters which are stored with the token for use when redirecting after login.
* Add Problem->time_ago for pretty-printed durationpezholio2017-02-15-0/+14
|
* [Oxfordshire] Allow cobrand-specific traffic management optionsDave Arter2017-02-08-0/+13
| | | | Fixes mysociety/fixmystreetforcouncils#159
* Fix crash on reports with empty bodies_strDave Arter2017-02-07-1/+4
|
* [Greenwich] Add a badge to official status updatesrbg-joe2017-02-06-0/+2
| | | | | | | | | Adding an official badge to Greenwich updates so as to avoid exchanges in which public contributions are mistaken for official ones. As per the Bromley version e.g. https://fix.bromley.gov.uk/report/973784 - this helps to avoid situations where public contributions are mistaken for official ones.
* Merge branch 'version-2.0.2'v2.0.2Matthew Somerville2017-02-03-4/+2
|\
| * Show ‘unable to fix’ state as ‘no further action’.Dave Arter2017-02-02-4/+2
| | | | | | | | Bromley had this already in its update state change messages.
* | Add a 'closest_address' hidden Open311 attribute.Matthew Somerville2017-02-03-1/+1
|/ | | | This joins easting, northing and an external ID field.
* No need to translate this string at present.Matthew Somerville2017-01-21-1/+1
|
* Merge remote-tracking branch ↵pezholio2017-01-17-4/+12
|\ | | | | | | 'origin/issues/forcouncils/136-show-user-details-for-council-report'
| * Show user details for users with correct permissionspezholio2017-01-17-4/+12
| |
* | Merge remote-tracking branch ↵pezholio2017-01-17-1/+87
|\ \ | | | | | | | | | 'origin/issues/forcouncils/142-allow-anonymous-council-updates'
| * | Allow users with permission to see update usernamepezholio2017-01-17-1/+5
| | |
| * | Refactor updates metadata output into modelpezholio2017-01-17-1/+83
| |/
* | Merge branch 'listshort'Matthew Somerville2017-01-12-0/+2
|\ \ | |/ |/|
| * Add shortlist buttons to report lists.Matthew Somerville2017-01-12-0/+2
| | | | | | | | | | | | | | This includes adding/removing reports from a user's shortlist, and manual reordering of a shortlist with up/down buttons. The backend code can cope with an item moving to any point in the list.
* | Update has_body_permission_to to allow superusers.Matthew Somerville2017-01-10-6/+9
|/
* Add ‘state’ field to ResponseTemplate modelDave Arter2017-01-10-2/+4
|
* Only load user body permissions once per request.Matthew Somerville2016-12-16-8/+16
| | | | This should help if a template uses has_permission_to a lot.
* Merge branch 'issues/forcouncils/108-pick-up-a-priority'Matthew Somerville2016-12-15-11/+24
|\
| * Update priorities in inspect form on cat. change.Matthew Somerville2016-12-15-10/+23
| | | | | | | | | | Different categories may have a different list of priorities, so store them all and update as the category changes.
| * Fail in has_permission_to if given an empty arrayref.Matthew Somerville2016-12-13-1/+1
| |
* | Display nearby candidate reports when marking as duplicateDave Arter2016-12-13-0/+1
| | | | | | | | | | | | | | | | - Use Problem->pin_data for single report page - Promote markers_highlight to fixmystreet.maps API We want to highlight map pins on the duplicate report selection UI, so let's use what's already there instead of writing something new. - Make sure duplicate report pins aren’t draggable
* | If a problem has duplicates, display them on its detail pageDave Arter2016-12-13-0/+12
| |
* | Add test for correct display of duplicate reportDave Arter2016-12-13-2/+3
| |
* | Store and display selected duplicate reportDave Arter2016-12-13-0/+11
|/
* Always return arrayref from bodies_str_ids.Matthew Somerville2016-11-29-1/+1
| | | | Prevents potential odd-element hash in e.g. response_priorities.
* Merge branch 'issues/forcouncils/99-sorting'Matthew Somerville2016-11-04-11/+23
|\
| * Add sort order options to list pages.Matthew Somerville2016-11-04-11/+23
| | | | | | | | | | | | | | | | Includes newest, oldest, least/most recently updated, and most comments. The default remains the same, which is last updated on /reports, and newest on /my and /around (the latter plus not-in-view sorted-by-distance ones).
* | Merge branch 'issues/forcouncils/116-inspect-show-bug'Matthew Somerville2016-11-04-4/+2
|\ \ | |/ |/|
| * Only return active shortlisted user for a problem.Matthew Somerville2016-10-28-4/+2
| |
* | Pre-filter map pages if user has categories assignedDave Arter2016-10-31-0/+15
|/ | | | | This pre-filters the 'all reports' link in the main nav and the /around page reached via the front page postcode form
* Merge branch 'issues/forcouncils/100-fix-template-list'Matthew Somerville2016-10-20-4/+6
|\