]> git.koha-community.org Git - koha.git/commit
Bug 15722: Escape patron infos for JSON in patron searches
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 8 Mar 2016 14:09:09 +0000 (14:09 +0000)
committerJulian Maurice <julian.maurice@biblibre.com>
Thu, 7 Apr 2016 05:06:34 +0000 (07:06 +0200)
commiteba74c8e51a52432362150c38d674f661a6228e8
tree8089e1972e2c16f6f67609c6e771462f1af9becd
parent3779c5a70966a5bfac95f1b69406e197f8a790e8
Bug 15722: Escape patron infos for JSON in patron searches

If patron infos contain invalid JSON chars (\t for instance), the
results won't appear.
The solution is to escape these info.

Test plan:
Edit patron infos in DB (update borrowers set surname="foobar\t" where
borrowernumber=42)
Search for foobar (you should have more than 1 result)
Without this patch, DT retrieves a bad formatted JSON and the results
won't appear.
With this patch, the table result appears

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit cd20b61a7c845110e518e6dedc12ac50efebe4aa)
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/tables/members_results.tt
koha-tmpl/intranet-tmpl/prog/en/modules/members/tables/members_results.tt
koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/tables/members_results.tt
koha-tmpl/intranet-tmpl/prog/en/modules/serials/tables/members_results.tt