]> git.koha-community.org Git - koha.git/commit
Bug 26797: Escape firstname to prevent relative's checkouts to crash
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Wed, 2 Dec 2020 10:25:13 +0000 (11:25 +0100)
committerFridolin Somers <fridolin.somers@biblibre.com>
Mon, 11 Jan 2021 13:00:53 +0000 (14:00 +0100)
commit95410a3a64c1cbe6f2a33c71b247d17675fa86e3
tree461dc0f325fef240d48ef3a0e7261c3ddec1fd40
parent46ae40d6ad489629e55c3f13cedae414e799a5f3
Bug 26797: Escape firstname to prevent relative's checkouts to crash

If no firstname is defined for a relative, the "Relative's checkouts"
tab will be "processing" forever.
JS error:
  TypeError: oObj.borrower.firstname is null

Test plan:
1 - Create a patron (PatronA) in a category with type 'Org'
    'School' in sample data works
2 - Add a guarantee (Patron B)
3 - Check out an item to PatronA
4 - Go to PatronB's record and click relativwe's checkouts
5 - There is an error and the table doe snot load
6 - Apply patch
7 - Reload
8 - Table loads correctly

Signed-off-by: Kelly McElligott <kelly@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 13fb0906be41e6f2f5effb89321bcac8371c8b45)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
koha-tmpl/intranet-tmpl/prog/js/checkouts.js