Bug 36249: Fix generic_confirm op
authorPedro Amorim <pedro.amorim@ptfs-europe.com>
Wed, 6 Mar 2024 15:58:06 +0000 (15:58 +0000)
committerKatrin Fischer <katrin.fischer@bsz-bw.de>
Thu, 7 Mar 2024 15:36:35 +0000 (16:36 +0100)
commit4214e5415db28a2b054899e556b89cd02b8d91f2
tree7bf03495ba6d21a9ef0c86bf3197396b7576110e
parent2e633b7f9d7729a84dd8580f512ea9ae433b0f22
Bug 36249: Fix generic_confirm op

Test plan, k-t-d:

1) Install FreeForm, enable ILL module, run:
bash <(curl -s https://raw.githubusercontent.com/ammopt/koha-ill-dev/master/start-ill-dev.sh)
2) You'll have to switch the FreeForm branch to the one compatible with this work, i.e.:
cd /kohadevbox/koha/Koha/Illbackends/FreeForm
git checkout b_36243
3) Restart plack:
koha-plack --restart kohadev
4) Start by adding an e-mail address to the patron of category "Inter-library Loan", visit:
<staff_url>/cgi-bin/koha/members/memberentry.pl?op=edit_form&destination=circ&borrowernumber=16
5) Add an e-mail address to "Primary e-mail"
6) Create a new FreeForm request, visit:
<staff_url>/cgi-bin/koha/ill/ill-requests.pl?method=create&backend=FreeForm
7) Set 'type' enter '42' in cardnumber and pick a library. Click 'Create'.
8) Click "Place request with partners"
9) Pick a partner library (will be the same patron from step 4)
10) Click "Send email". Notice the CSRF error.
11) Apply patch and restart plack
koha-plack --restart kohadev
12) Repeat 8-10. Notice error no longer shows.
13) Notice the request's status is now 'Requested from partners'

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Koha/Illrequest.pm
ill/ill-requests.pl
koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt