foreach my $p (
qw(homebranch holdingbranch location itype ccode issues datelastborrowed notforloan itemlost withdrawn damaged))
{
if ( my @q = $cgi->multi_param($p) ) {
if ( my @q = $cgi->multi_param($p . "[]") ) {
if ( $q[0] ne '' ) {
my $f = {
field => $p,
url: '/cgi-bin/koha/catalogue/itemsearch.pl',
data: function ( d ) {
for (i in params) {
d[params[i].name] = params[i].value;
if (! d.hasOwnProperty(params[i].name) ) {
d[params[i].name] = [];
}
d[params[i].name].push(params[i].value);
d.format = 'json';
d.columns = JSON.stringify( d.columns );
-