Bug 16857: Check on item.branches makes more sense

The test should be on the existence of the item.branches
method/attribute

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit f38bcf5505)
Signed-off-by: Frédéric Demians <f.demians@tamil.fr>
This commit is contained in:
Jonathan Druart 2016-07-07 16:40:47 +01:00 committed by Frédéric Demians
parent dc6ea8d5c9
commit 6a7fd3ecdc
1 changed files with 1 additions and 1 deletions

View File

@ -267,7 +267,7 @@ $(document).ready(function() {
<td>[% item.code |html %]</td>
<td>[% item.description %]</td>
<td>
[% IF ( item.branches.size && item.branches.size > 0 ) %]
[% IF ( item.branches && item.branches.size > 0 ) %]
[% branches_str = "" %]
[% FOREACH branch IN item.branches %]
[% branches_str = branches_str _ " " _ branch.branchname _ "(" _ branch.branchcode _ ")" %]