[2021-06-17 14:42:51.00970] [909] [warn] OpenAPI <<< PUT api/v1/return_claims/1/resolve [{"message":"Properties not allowed: updated_by.","path":"\/body"}] To recreate: Checkout Claim it Go to claims Action > resolve > resolve claim
Created attachment 122083 [details] [review] Bug 28586: Pass the right parameter to resolve claim Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This is yet another case highlighted by adding additionalProperties: false.
Created attachment 122092 [details] [review] Bug 28586: (follow-up) updated_by should be set This patch makes the route set the 'updated_by' attribute as well, when resolving a return claim through the API. Tests are added for this behavior. To test: 1. Apply this patch 2. Run: $ kshell k$ prove t/db_dependent/api/v1/return_claims.t => SUCCESS: Tests pass! updated_by is set correctly! 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 122110 [details] [review] Bug 28586: Pass the right parameter to resolve claim Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com>
Created attachment 122111 [details] [review] Bug 28586: (follow-up) updated_by should be set This patch makes the route set the 'updated_by' attribute as well, when resolving a return claim through the API. Tests are added for this behavior. To test: 1. Apply this patch 2. Run: $ kshell k$ prove t/db_dependent/api/v1/return_claims.t => SUCCESS: Tests pass! updated_by is set correctly! 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com>
Testing notes (koha-testing-docker): - To reproduce the issue: . Set a value for ClaimReturnedLostValue, for example: 4 . Check out an item to a patron . Go to the patron's check out page > show check outs . In the 'Return claims' column select 'Claim returned', enter a note and click 'Make claim" . Go to to the Claim(s) tab and select Actions > Resolve > select a resolution reason from the drop down list > Click on 'Resolve claim' . Select a reason and enter some text - Before the patch is applied the page just hangs and there is the [warn] message (see bug description) in /var/log/koha/kohadev/plack-error.log - After the patch is applied (and browser cache cleared) the browser no longer hangs and there is no warning message in the log
Created attachment 122124 [details] [review] Bug 28586: Pass the right parameter to resolve claim Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
Created attachment 122125 [details] [review] Bug 28586: (follow-up) updated_by should be set This patch makes the route set the 'updated_by' attribute as well, when resolving a return claim through the API. Tests are added for this behavior. To test: 1. Apply this patch 2. Run: $ kshell k$ prove t/db_dependent/api/v1/return_claims.t => SUCCESS: Tests pass! updated_by is set correctly! 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
Created attachment 122126 [details] [review] Bug 28586: Pass the right parameter to resolve claim Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
Created attachment 122127 [details] [review] Bug 28586: (follow-up) updated_by should be set This patch makes the route set the 'updated_by' attribute as well, when resolving a return claim through the API. Tests are added for this behavior. To test: 1. Apply this patch 2. Run: $ kshell k$ prove t/db_dependent/api/v1/return_claims.t => SUCCESS: Tests pass! updated_by is set correctly! 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
Created attachment 122129 [details] [review] Bug 28586: Pass the right parameter to resolve claim Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Created attachment 122130 [details] [review] Bug 28586: (follow-up) updated_by should be set This patch makes the route set the 'updated_by' attribute as well, when resolving a return claim through the API. Tests are added for this behavior. To test: 1. Apply this patch 2. Run: $ kshell k$ prove t/db_dependent/api/v1/return_claims.t => SUCCESS: Tests pass! updated_by is set correctly! 3. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Pushed to master for 21.11, thanks to everybody involved!
(In reply to Jonathan Druart from comment #13) > Pushed to master for 21.11, thanks to everybody involved! Pushed to 21.05.x for 21.05.01
Pushed to 20.11.x for 20.11.08
Backported: Pushed to 20.05.x branch for 20.05.14
Backported to 19.11.x for 19.11.20