Lines 133-139
sub GetHoldsQueueItems {
Link Here
|
133 |
my $dbh = C4::Context->dbh; |
133 |
my $dbh = C4::Context->dbh; |
134 |
|
134 |
|
135 |
my @bind_params = (); |
135 |
my @bind_params = (); |
136 |
my $query = q/SELECT tmp_holdsqueue.*, biblio.author, items.ccode, items.itype, biblioitems.itemtype, items.location, |
136 |
my $query = q/SELECT borrowers.surname, |
|
|
137 |
borrowers.othernames, |
138 |
borrowers.firstname, |
139 |
borrowers.cardnumber, |
140 |
borrowers.borrowernumber, |
141 |
borrowers.title AS borrower_title, |
142 |
tmp_holdsqueue.*, biblio.author, items.ccode, items.itype, biblioitems.itemtype, items.location, |
137 |
items.enumchron, items.cn_sort, biblioitems.publishercode, |
143 |
items.enumchron, items.cn_sort, biblioitems.publishercode, |
138 |
biblio.copyrightdate, biblio.subtitle, biblio.medium, |
144 |
biblio.copyrightdate, biblio.subtitle, biblio.medium, |
139 |
biblio.part_number, biblio.part_name, |
145 |
biblio.part_number, biblio.part_name, |
Lines 143-148
sub GetHoldsQueueItems {
Link Here
|
143 |
JOIN biblio USING (biblionumber) |
149 |
JOIN biblio USING (biblionumber) |
144 |
LEFT JOIN biblioitems USING (biblionumber) |
150 |
LEFT JOIN biblioitems USING (biblionumber) |
145 |
LEFT JOIN items USING ( itemnumber) |
151 |
LEFT JOIN items USING ( itemnumber) |
|
|
152 |
LEFT JOIN borrowers USING (borrowernumber) |
146 |
WHERE 1=1 |
153 |
WHERE 1=1 |
147 |
/; |
154 |
/; |
148 |
if ($params->{branchlimit}) { |
155 |
if ($params->{branchlimit}) { |
Lines 172-177
sub GetHoldsQueueItems {
Link Here
|
172 |
} |
179 |
} |
173 |
delete $row->{itemtype}; |
180 |
delete $row->{itemtype}; |
174 |
|
181 |
|
|
|
182 |
$row->{borrower} = { |
183 |
borrowernumber => $row->{borrowernumber}, |
184 |
cardnumber => $row->{cardnumber}, |
185 |
firstname => $row->{firstname}, |
186 |
othernames => $row->{othernames}, |
187 |
surname => $row->{surname}, |
188 |
title => $row->{borrower_title}, |
189 |
}; |
190 |
|
175 |
push @$items, $row; |
191 |
push @$items, $row; |
176 |
} |
192 |
} |
177 |
return $items; |
193 |
return $items; |