| Commit message (Collapse) | Author | Age | Lines |
|
|
|
|
|
| |
As the templates were using `grep`, they failed to match on a category
such as "Footpaths (right of way)". Changing the stash variables to be
hashes instead of lists makes checking for a key simpler. Fixes #1688.
|
|\ |
|
| | |
|
|/
|
|
|
|
|
|
|
| |
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.)
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
|
|
| |
Rather than assigning +1 to a user's reputation every time a report is
inspected, this allows cobrands to specify which states should increment or
decrement the reputation value when a report is inspected.
The default behaviour is for reputation to never be changed, but the Oxfordshire
cobrand will increment the reputation when a report is marked as 'action
scheduled'.
For mysociety/fixmystreetforcouncils#119
|
|
|
|
|
|
| |
A report is now considered 'inspected' if its state was changed by an inspector.
Additionally, an AdminLog entry is created so the time of inspection and
inspector can be recorded.
|
|
|
|
|
| |
Assume that if they inspect and save a report, they want
to go back to their shortlist.
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This allows the inspect form to be submitted when offline, with the data
saved in localStorage, the number of saved forms shown in the banner,
and the forms to be uploaded when back online.
It copes if you go back to a report after having submitted the form, and
if the back-online submission fails due to CSRF failure, retrying once
with a new token.
|
|\ \
| |/
|/| |
|
| |
| |
| |
| |
| | |
Different categories may have a different list of priorities, so store
them all and update as the category changes.
|
| |
| |
| |
| |
| |
| | |
- Record state change when leaving update and marking as duplicate
- Change save button wording to match problem state when inspecting
- Make it clearer that updates marking a report as duplicate actually close the report
|
| |
| |
| |
| |
| |
| |
| |
| | |
- 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
|
| | |
|
| | |
|
|/ |
|
| |
|
| |
|
| |
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We want to make sure the extra metadata stored on a problem is kept in sync with
the requirements of the category the report is in. Thus, if a report is moved to
a category that collects extra metadata then the appropriate input fields should
be shown so the inspector can enter the data.
This commit shows the category extra HTML elements for every selectable category
on the inspector page hiding those that don't apply to the selected category. JS
is used to show/hide the extra fields when the category dropdown is changed.
A consequence of the implementation is that any extra metadata from the original
category is lost when the category is changed. Some thought was given to storing
the old values elsewhere in the problem's extra field but I decided against this
for the time being.
For mysociety/fixmystreetforcouncils#45
|
| |
| |
| |
| |
| |
| | |
Inspectors can now tick the optional “Save with a public update”
checkbox, to reveal the “Public update” textarea. This means there is
no longer a need for two separate submit buttons.
|
| |
| |
| |
| |
| |
| |
| |
| | |
IDs and locations at the top, then location-related actions (including
a new “navigate to this problem” button), then status and category
inputs (since these can have an effect on how we display the rest of
the form), then any status/category-related inputs, and finally inputs
for internal details like priority and traffic management.
|
|/ |
|
| |
|
|
|
|
|
|
|
| |
This adds an update field to the bottom of the inspect form, requiring the
inspector to provide an update to be added to the report as it's sent.
See mysociety/fixmystreetforcouncils#64
|
|
|
|
|
|
|
| |
This is a cut-down version of the full inspect screen.
We truncate the co-ordinates just in case (they should be anyway but
e.g. the test report isn't).
|
|
|
|
|
|
|
| |
This moves the response priority values from a cobrand-specific method to a full
DB model, and includes management screens in the admin for administering them.
For mysociety/fixmystreetforcouncils#66
|
|
|
|
|
|
|
|
|
|
|
| |
Categories can now require reports to be marked as 'inspected' via the frontend
before they're sent by send-reports.
A side-effect here is that send-reports will perform an extra n queries for each
report, where n is the number of bodies that report is being sent to, but
hopefully in practice this won't matter as it's an offline cronjob.
See mysociety/fixmystreetforcouncils#50
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Users with the `report_inspect` permission can click a new 'inspect' button on a
report page to input more detailed problem information into a new form that
appears in a column alongside the report detail.
- Inspector data is stored in problem's 'extra' field
- Report category/state can be edited
- Location can be changed by dragging the pin or HTML5 geolocation
(Factored out Zurich admin pin drag into own function)
For mysociety/fixmystreetforcouncils#22
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This rearranges the moderation UI into logical chunks,
and improves the 'revert to original' checkboxes by:
- hiding them unless there's some original text to revert
to
- displaying the text that will be reverted to in the
appropriate input fields when checked.
Part of mysociety/FixMyStreet-Commercial#731
|
|
|
|
| |
And associated, e.g. nothing references fixmystreet-old-box.js any more.
|
|
|
|
|
|
| |
Travis has Cpanel::JSON::XS preinstalled, which means that the build
would fail there, as JSON::MaybeXS would try and upgrade JSON::XS to
version 3 which the snapshot did not contain.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Requirements:
=============
1: DM to be able to mark a problem as Wish, Extern, Not contactable,
Hidden, Jurisdiction unknown
2: SDM to be able to mark a problem as Not contactable.
3: DM to be able to add information to such a problem, and trigger
emails to external agencies, and to user, closing the problem at the
same time.
4: Closed reports must be categorized as Wish/Extern/NC/Hidden/JU for
statistical reporting
5: Non-closed reports must appear as open, to allow DM to see them in
the list, similar to what is currently done for Ruckmeldung Ausstehend
(Feedback outstanding).
5b: however "Hidden" problems must be immediately hidden from public
view.
Proposal:
=========
a) Requirement 1 will be carried out in exactly the same way by
DM. e.g. Category dropdown select
b) Requirement 2 will be carried out in exactly the same way by SDM.
e.g. "Not contactable" button
c) BUT, for a), c), the category will be diverted to "Ruckmeldung
Ausstehend" (Feedback outstanding), and metadata will be saved with the
appropriate closure type.
d) NOTE: this means the report will still be visible to public as "In
bearbeitung" (Except for Hidden reports, as per 5b)
e) The extra fields will be presented on the "Ruckmeldung Ausstehend"
page, just as defined in the PDF, depending on the metadata. e.g.
- Wish: Zustaendige Stelle + Message
- Extern: External body + Message2
- Not contactable: (no extra info)
- Hidden: (no extra info)
- Jurisdiction unknown: (no extra info)
f) When the DM publishes the answer (e.g. "Antwort Veroeffentlichen"
button), the state will normally change to Fixed. BUT in the new cases,
the metadata saved in step c) will be checked, and the report will
change state to Wish/Extern/Not contactable/Hidden/Jurisdiction unknown,
as appropriate. The report will now be visible/hidden as previously
discussed depending on the new state.
g) If the report is edited again (in /admin/report_edit) it will be in
the relevant state, and any extra fields will be visible as per e).
Those fields may be updated.
Alternatively, the state may be changed, possibly triggering a) again,
and clearing any metadata.
- Fix javascript interactions 690
- show new statuses in summary
- fix photos on SDM page
- fix Planned => Planned+metadata transition
- stop "assignation .select" js affecting templates
- fix redirection for Extern and generally
See mysociety/FixMyStreet-Commercial#672, mysociety/FixMyStreet-Commercial#690
|
|
|
|
|
|
|
| |
Have moved the generation of banner text from the template into
problem_as_hashref
See mysociety/FixMyStreet-Commercial#672
|
|
|
|
| |
Add a site_name template parameter available to all templates.
|
|
|
|
|
| |
This override is not used anywhere, it dates from a very old long-gone
test script, and causes issues with database query planning.
|
|
|
|
|
|
|
| |
Restrict email_sign_in token to one day, unused confirmation tokens to
one month. Used tokens will redirect to the created thing but not log
in; don't log in with alert links (unsubscribe link never expires, reply
link will still show "reopen" tickbox).
|
|
|
|
|
|
|
| |
Use a central get_param and get_param_list functions dependent on
whether we're after a scalar or a list (almost always a scalar). This
prevents any possibility of confusion where param() could return a list,
or params->{} an arrayref.
|
|
|
|
|
| |
Rather than redirecting to the report if they're already logged in.
Fixes #1003.
|
|
|
|
|
|
|
| |
This includes MapIt postcode lookups, geocoding, query parameters, tile
clicks. Stringifying truncates them to six decimal places, which means
we no longer need any "short" versions anywhere, and the JSON response
will always uses a decimal point regardless of locale.
|
|
|
|
|
|
|
| |
This matches the email template behaviour, and makes it much easier to
override without requiring a cobrand package file.
Fixes #979.
|
|
|
|
|
|
|
|
|
| |
The feature to hide reports is still enabled, as it is used by other
`users_can_hide` bodies. As we want to roll out moderation to Bromley,
in this commit we hide the functionality *only* for Bromley. Of course
if we migrate those other users to this moderation method, then we will
need to make equivalent change to general template, and remove the
functionality from Report.pm.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In order to allow us to do funnel analysis in google analytics we need
to send a differnt page url when a user completes a report. To do this
we add a report_created=1 to the query string on either the report page
or the report confirmation page for logged in and confirm by email users
respectively.
There's a bit of complication as we don't want to set a session cookie
everywhere as that will break caching so we set a stash variable,
although if the user is logged in this is controlled by a variable in
the flash as there is already a session cookie at this point.
also, removes the code that sends an event upon report completion as
this was no use for funnel analysis.
|
|
|
|
|
|
|
|
|
| |
New cobrand function of pin_path that sets the path to where the image
files for pins are located. Defaults to /i
This still means they need to use the same file names but they can at
least put those in a cobrand directory rather than having to overwrite
the files in /i or fudge it with pin_colour
|