Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

circulation : fix checkin of item that should go in transit #512

Merged
merged 0 commits into from
Sep 26, 2019

Conversation

benerken
Copy link
Contributor

Co-Authored-by: Benoit Erken [email protected]

@benerken benerken force-pushed the bee-#1026-checkin_transit branch 2 times, most recently from 734f56e to 34f24df Compare September 20, 2019 12:04
@@ -711,8 +711,7 @@ def item_location_retriever(cls, item_pid, **kwargs):
# to deal with multiple pickup locations for a library
item = cls.get_record_by_pid(item_pid)
if item:
library = item.get_library_of_last_location()
return library.get_pickup_location_pid()
return item.get_owning_pickup_location_pid()
Copy link

@BadrAly BadrAly Sep 23, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I recall that the PO asked to not rely on the the pickup location of the owning library. Instead he asked to find where the item is actually now by checking the library of the last transaction loan. This is a use case not documented in the Circulation state chart https://github.com/rero/rero-ils/blob/master/doc/circulation_statechart/circulation_loan_statechart.pdf.

The outcome, keep the two lines:

library = item.get_library_of_last_location()
return library.get_pickup_location_pid()

@lauren-d lauren-d force-pushed the bee-#1026-checkin_transit branch from 34f24df to f9ce4e9 Compare September 26, 2019 06:58
@Garfield-fr Garfield-fr merged commit f9ce4e9 into rero:dev Sep 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants