-
-
Notifications
You must be signed in to change notification settings - Fork 267
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
Add feature to revert tasks set as unavailable by a specific user #5955
Conversation
------------------------------------------ In the previous implementation this endpoint was only able to revert validated tasks by a user to mapped state. Now this endpoint has been modified so that it is able to revert validated and bad imagery tasks set by a user. ------------------------------------------ - Renames endpoint url to `projects/<int:project_id>/tasks/actions/reset-by-user/` from `projects/<int:project_id>/tasks/actions/reset-validated-by-user/`. - Introduces a query param action which is used to revert tasks of specific action performed by user. The value of this action can only be VALIDATED and BADIMAGERY. - Renames DTO and function so that it matches that task performed by them.
…the expected exceptions were not handled properly.
189f94d
to
ee08814
Compare
ee08814
to
ab75702
Compare
…ing multiple actions - Add support for revert actions in `RevertTasks` component; now supporting both revert actions for `VALIDATED` and `BADIMAGERY` tasks - Update messages for `BADIMAGERY` action and also `VALIDATED` action to use dynamically generated messages in the `RevertTasks` component
…points. ------------------------------------------ In the previous implementation bad imagery tasks were counted as mapped by user so this commit adds new fields in `UserContribution` dto for bad imagery tasks count and bad imagery tasks list.
…adding `badImagery` and `badImageryTasks` fields.
1600a65
to
d0929f2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested via both the front-end and api-docs. Works as expected on the UI🎉. Via the API-docs, we get a 500 internal server error if the string entered is not ALL CAPS. The change request is for the removal of case sensitivity.
… can be converted into desired format within the dto.
Kudos, SonarCloud Quality Gate passed!
|
I've updated the PR with the issue reported. Can you please re-review ? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
closes #5943
Backend changes:
projects/<int:project_id>/tasks/actions/reset-validated-by-user/
toprojects/<int:project_id>/tasks/actions/reset-by-user/
.action
in the endpoint above which is used to revert tasks of specificaction
performed by the user. The value of this action can only beVALIDATED
andBADIMAGERY
.badImagery
andbadImageryTasks
in the response ofprojects/<project_id>/contributions/
endpoint.