I've been trying to figure out why my patrons can't place holds on on-order items (items.notforloan = -1) from the OPAC. If found this in opac-reserve.pl (line 138): if (!$itm->{'notforloan'} && !($itm->{'itemnotforloan'} > 0)){ $forloan=1; } Trying to find out what the difference was between $itm->{'notforloan'} and $itm->{'itemnotforloan'} I checked GetItemsInfo() in Items.pm. GetItemsInfo() SELECTs both "items.*" and "items.notforloan as itemnotforloan." So $itm->{'notforloan'} and $itm->{'itemnotforloan'} are the same thing? Changing line 138 of opac-reserve.pl to if ($itm->{'notforloan'} <1){ $forloan=1; } ...would be correct wouldn't it? -- Owen -- Web Developer Athens County Public Libraries http://www.myacpl.org
Trying to find out what the difference was between $itm->{'notforloan'} and $itm->{'itemnotforloan'} I checked GetItemsInfo() in Items.pm. GetItemsInfo() SELECTs both "items.*" and "items.notforloan as itemnotforloan."
So $itm->{'notforloan'} and $itm->{'itemnotforloan'} are the same thing?
When I brought this up on IRC yesterday Galen pointed out that the purpose of selecting "items.notforloan as itemnotforloan" would be to differentiate from itemtypes.notforloan. That makes sense, except that in the case of GetItemsInfo() itemtypes.notforloan isn't being pulled. So, when opac-reserve.pl says: if (!$itm->{'notforloan'} && !($itm->{'itemnotforloan'} > 0)){ $forloan=1; } Is the intention that $item->{'notforloan'} be the value of itemtypes.notforloan? -- Owen -- Web Developer Athens County Public Libraries http://www.myacpl.org
participants (1)
-
Owen Leonard