my %cache_data = (
hold => [],
transit => [],
- shelf => []
+ shelf => [],
+ pl_changed => pickup_lib_changed_on_shelf_holds($e, $org_id, \@hold_ids)
);
for my $hold (@holds) {
}
}
+# returns IDs for holds that are on the holds shelf but
+# have had their pickup_libs change while on the shelf.
+sub pickup_lib_changed_on_shelf_holds {
+ my $e = shift;
+ my $org_id = shift;
+ my $ignore_holds = shift;
+ $ignore_holds = [$ignore_holds] if !ref($ignore_holds);
+
+ my $query = {
+ select => { alhr => ['id'] },
+ from => {
+ alhr => {
+ acp => {
+ field => 'id',
+ fkey => 'current_copy'
+ },
+ }
+ },
+ where => {
+ '+acp' => { status => OILS_COPY_STATUS_ON_HOLDS_SHELF },
+ '+alhr' => {
+ capture_time => { "!=" => undef },
+ fulfillment_time => undef,
+ current_shelf_lib => $org_id,
+ pickup_lib => {'!=' => {'+alhr' => 'current_shelf_lib'}}
+ }
+ }
+ };
+
+ $query->{where}->{'+alhr'}->{id} =
+ {'not in' => $ignore_holds} if @$ignore_holds;
+
+ my $hold_ids = $e->json_query($query);
+ return [ map { $_->{id} } @$hold_ids ];
+}
+
__PACKAGE__->register_method(
method => 'usr_hold_summary',
api_name => 'open-ils.circ.holds.user_summary',
<!ENTITY staff.main.menu.circ.hold_browse.accesskey "B">
<!ENTITY staff.main.menu.circ.hold_browse.label "Browse Holds Shelf">
<!ENTITY staff.main.menu.circ.hold_clear.accesskey "">
-<!ENTITY staff.main.menu.circ.hold_clear.label "Clear Shelf-Expired Holds">
+<!ENTITY staff.main.menu.circ.hold_clear.label "Clear Holds Shelf">
<!ENTITY staff.main.menu.circ.hold_capture.accesskey "H">
<!ENTITY staff.main.menu.circ.hold_capture.label "Capture Holds">
<!ENTITY staff.main.menu.circ.hold_pull.accesskey "S">
<!ENTITY staff.circ.checkin_overlay.checkin_auto_print_slips.accesskey "P">
<!ENTITY staff.circ.checkin_overlay.checkin_modifiers_btn.label "Checkin Modifiers">
<!ENTITY staff.circ.checkin_overlay.checkin_modifiers_btn.accesskey "M">
-<!ENTITY staff.circ.checkin_overlay.checkin_clear_shelf_expired.label "Clear Shelf-Expired Holds">
+<!ENTITY staff.circ.checkin_overlay.checkin_clear_shelf_expired.label "Clear Holds Shelf">
<!ENTITY staff.circ.checkin_overlay.checkin_clear_shelf_expired.accesskey "C">
<!ENTITY staff.circ.checkin_overlay.checkin_auto_retarget.label "Retarget Local Holds">
<!ENTITY staff.circ.checkin_overlay.checkin_auto_retarget.accesskey "R">
staff.circ.utils.hold_post_clear_shelf_action.hold=Need for Hold
staff.circ.utils.hold_post_clear_shelf_action.transit=Need for Transit
staff.circ.utils.hold_post_clear_shelf_action.shelf=Reshelve
+staff.circ.utils.hold_post_clear_shelf_action.pl_changed=Wrong Shelf
staff.circ.utils.frozen=Frozen?
staff.circ.utils.active=Active?
staff.circ.utils.thaw_date=Activation Date