Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Button to revert status of requests marked for admin attention #8230

Open
HelenWDTK opened this issue May 1, 2024 · 0 comments
Open

Button to revert status of requests marked for admin attention #8230

HelenWDTK opened this issue May 1, 2024 · 0 comments

Comments

@HelenWDTK
Copy link
Contributor

Replaces #1773, deleted in error:

On 14 September 2022 @garethrees wrote:

Context

After dealing with a reported request, to reset the state admins need to review the event history to find the previous
status, remember it, then go to the edit page for the request to reset this state. It's pretty tedious and occasionally we
revert to an incorrect status.
We want a one-click way of reseting this state.

Scope

If a request is in a reported state (attention_requested , requires_admin, error_message), we'll add a new
section in the "Actions" grouping on the request's admin page. In it we'll have a label, the button, and an indication of
the previous state that the request is going to be put back into.
1

Technical Considerations

I think we'll probably need to store the previous state in the params_yaml of the report_request event.
Alternatively, we may be able to use calculated_state. Note how below, the response event is described as
successful but then calculated as attention_requested now that the report has been made. It may be that we can
essentially do the reverse when reporting a request.
2
I'm a little less sure on the mechanics of all this, so it's worth exploring the code to see which approach makes more
sense conceptually.

Out of Scope

A link in the email of reports was suggested, but that adds extra complexity to the controller handling these, in terms
of handling different HTTP verbs, how we present the params in the URL, and giving an indication of what the request
is being reset to. What happens to old links if they're clicked but the request is no longer reported? Too much hassle
for the value at this stage.

We do want a Reportable in future (#6931), but extracting out all of the report mechanics from InfoRequest is going
to be too difficult for the value in this context. If we can make any refactorings that help directly with this issue and also
benefit a future Reportable though, we should.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant