]> git.koha-community.org Git - koha.git/commit
Bug 10921: Prevent an order from a closed basket to be edited
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Fri, 31 Jul 2020 09:15:57 +0000 (11:15 +0200)
committerLucas Gass <lucas@bywatersolutions.com>
Fri, 16 Oct 2020 14:56:45 +0000 (14:56 +0000)
commitdeffb12491fa1a928a427b25f55ea5929f030266
tree20c207250e3aacae3c6bfa526b742491eae1f9d1
parent3b9b55eb3ed7041e0a7e369ac1ea8385f648ce55
Bug 10921: Prevent an order from a closed basket to be edited

We don't allow editing of orders that are part of a closed basket, but
we don't enforce the rule in the controller file.

This patch use output_and_exit to stop the script and display an error
to the end user.

Test plan:
Create a basket, add an order
On the basket view you see the "Modify" link, open it in a separate tab
=> You can edit the basket
Keep this tab open, get back to the other one and close the basket
Reload the tab with the order edition form
=> You cannot longer edit the basket

QA: Do we need a check in addorder.pl as well?

Signed-off-by: Henry Bolshaw <bolshawh@parliament.uk>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 0310e973a4c28a7e02baad03799eb40869ce4506)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
acqui/neworderempty.pl
koha-tmpl/intranet-tmpl/prog/en/includes/blocking_errors.inc