[Koha-bugs] [Bug 28895] Don't fill in items.location with NewItemsDefaultLocation if blank

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Sep 17 19:20:51 CEST 2021


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28895

Hannah Co <hannah.co at northwestu.edu> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hannah.co at northwestu.edu

--- Comment #6 from Hannah Co <hannah.co at northwestu.edu> ---
(In reply to Andrew Fuerste-Henry from comment #5)
> Actually, testing this on master this morning it's very much not working as
> intended.
> 
> I have NewItemsDefaultLocation set to PROC.
> On additem.pl, when I create a load the new item page, location is
> automatically set to PROC. If I create my item without changing it, the item
> has both location and shelving_location set to PROC.
> There is no reason to set the default to PROC here, but I guess it doesn't
> hurt anything.
> 
> On additem.pl, if I change the shelving location to any value other than
> PROC before I create my item, both the location and permanent location are
> set to whatever new value I've selected.
> Whatever I've selected should go into permanent_location, but location
> should be PROC.
> 
> If I delete PROC without selecting something else on creating my item, then
> location and permanent_location end up as PROC anyway.
> This bug asserts that in this case I should get location=PROC and
> permanent_location=NULL. I support that change.
> 
> This could debatably be a new bug, but there are a lot of old bugs around
> this syspref already.

In order for UpdateItemLocationOnCheckin to work correctly for items with no
shelving location, the NewItemsDefaultLocation needs to stay out of the
permanent_location field. If NewItemsDefaultLocation is set to PROC, and
UpdateItemLocationOnCheckin has the line "PROC: _PERM_" items with no shelving
location remain in processing and don't get shelving location changed to NULL
on checkin, as they should. 

I agree that at item creation, if a shelving location is not selected then the
item should have location=PROC and permanent_location=NULL.

When editing an item, the NewItemsDefaultLocation currently replaces a NULL
value. If the shelving location is NULL, NewItemsDefaultLocation should not
replace the NULL upon editing.

-- 
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.


More information about the Koha-bugs mailing list