Bugzilla – Attachment 143009 Details for
Bug 24860
Add ability to place item group level holds
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 24860: (QA follow-up) Show group holds on Holds to pull
Bug-24860-QA-follow-up-Show-group-holds-on-Holds-t.patch (text/plain), 3.28 KB, created by
Katrin Fischer
on 2022-11-02 16:48:20 UTC
(
hide
)
Description:
Bug 24860: (QA follow-up) Show group holds on Holds to pull
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2022-11-02 16:48:20 UTC
Size:
3.28 KB
patch
obsolete
>From 2e0d1ec201722f4c2721733c1f8a7e1cd84995a7 Mon Sep 17 00:00:00 2001 >From: Kyle Hall <kyle@bywatersolutions.com> >Date: Fri, 21 Oct 2022 12:02:08 -0400 >Subject: [PATCH] Bug 24860: (QA follow-up) Show group holds on Holds to pull > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > circ/pendingreserves.pl | 10 ++++++++-- > .../prog/en/modules/circ/pendingreserves.tt | 12 +++++++++++- > 2 files changed, 19 insertions(+), 3 deletions(-) > >diff --git a/circ/pendingreserves.pl b/circ/pendingreserves.pl >index 86a18b14f0..5019e0c50c 100755 >--- a/circ/pendingreserves.pl >+++ b/circ/pendingreserves.pl >@@ -229,7 +229,7 @@ my $all_holds = { > map { $_->biblionumber => $_ } @{ Koha::Holds->search( > { reserve_id => [ values %$holds_biblios_map ]}, > { >- prefetch => [ 'borrowernumber', 'itembib', 'biblio' ], >+ prefetch => [ 'borrowernumber', 'itembib', 'biblio', 'item_group' ], > } > )->as_list > } >@@ -265,6 +265,8 @@ foreach my $bibnum ( @biblionumbers ){ > } > $hold_info->{itemtypes} = \@res_itemtypes; > >+ my $res_info = $all_holds->{$bibnum}; >+ > # get available values for each biblio > my $fields = { > locations => 'location', >@@ -282,6 +284,10 @@ foreach my $bibnum ( @biblionumbers ){ > [ uniq map { defined $_->$field ? $_->$field : () } @$items ]; > } > >+ if ( $res_info->item_group ) { >+ $hold_info->{barcodes} = [ uniq map { defined $_->barcode && $_->item_group->id == $res_info->item_group_id ? $_->barcode : () } @$items ]; >+ } >+ > # items available > $hold_info->{items_count} = $items_count; > >@@ -292,11 +298,11 @@ foreach my $bibnum ( @biblionumbers ){ > $hold_info->{pull_count} = $pull_count; > > # get other relevant information >- my $res_info = $all_holds->{$bibnum}; > $hold_info->{patron} = $res_info->patron; > $hold_info->{item} = $res_info->item; > $hold_info->{biblio} = $res_info->biblio; > $hold_info->{hold} = $res_info; >+ $hold_info->{item_group} = $res_info->item_group; > > push @holds_info, $hold_info; > } >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/pendingreserves.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/pendingreserves.tt >index 1b7aecabd7..2220cf9043 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/pendingreserves.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/pendingreserves.tt >@@ -129,7 +129,17 @@ > <td> > [% IF ( hold_info.barcodes.size ) %] > [% SET barcode = hold_info.barcodes.first %] >- [% IF ( hold_info.item ) %]<span>Only [% barcode | html %]</span>[% ELSE %]<span>[% barcode | html %] or any available.</span>[% END %] >+ [% IF ( hold_info.item ) %] >+ <span>Only [% barcode | html %]</span> >+ [% ELSE %] >+ <span>[% barcode | html %] or >+ [% IF hold_info.item_group %] >+ any available from item group <em>[% hold_info.item_group.description | html %]</em>. >+ [% ELSE %] >+ any available. >+ [% END %] >+ </span> >+ [% END %] > [% END %] > </td> > <td> >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 24860
:
100644
|
100645
|
100646
|
100647
|
100648
|
100649
|
100650
|
100651
|
101744
|
101745
|
101746
|
101747
|
101748
|
101749
|
101750
|
101751
|
101827
|
101828
|
101829
|
101830
|
101831
|
101832
|
101833
|
101834
|
101835
|
102230
|
102231
|
102232
|
102233
|
102234
|
102235
|
102236
|
102237
|
102238
|
102239
|
102240
|
102241
|
102242
|
102243
|
102244
|
102245
|
102246
|
102247
|
106589
|
106590
|
106591
|
106592
|
106593
|
106594
|
106595
|
106596
|
106597
|
106682
|
106683
|
106684
|
106685
|
106686
|
106687
|
106688
|
106689
|
106690
|
106742
|
106743
|
106744
|
106745
|
106746
|
106747
|
106748
|
106749
|
106750
|
108458
|
108459
|
108460
|
108461
|
108462
|
108463
|
108464
|
108465
|
108466
|
109097
|
109098
|
109099
|
109100
|
109101
|
109102
|
109103
|
109104
|
109105
|
109171
|
109172
|
109173
|
109174
|
109175
|
109176
|
109177
|
109178
|
109179
|
113616
|
113617
|
113618
|
113619
|
113620
|
113621
|
113622
|
113623
|
113624
|
135922
|
135923
|
135924
|
135925
|
135926
|
135927
|
135928
|
135929
|
135930
|
138221
|
138222
|
138224
|
138225
|
138226
|
138227
|
138228
|
138229
|
138230
|
141214
|
141215
|
141735
|
141736
|
141737
|
141738
|
141739
|
141740
|
141741
|
141742
|
141743
|
141744
|
141745
|
141746
|
141747
|
141748
|
141749
|
141750
|
142413
|
142414
|
142415
|
142416
|
142417
|
142418
|
142419
|
142420
|
142421
|
142422
|
142423
|
142424
|
142425
|
142426
|
142427
|
142428
|
142429
|
142430
|
142827
|
142955
|
142956
|
142957
|
142958
|
142959
|
142960
|
142961
|
142962
|
142963
|
142964
|
142965
|
142966
|
142967
|
142968
|
142969
|
142970
|
142971
|
142972
|
142973
|
142974
|
142975
|
142992
|
142993
|
142994
|
142995
|
142996
|
142997
|
142998
|
142999
|
143000
|
143001
|
143002
|
143003
|
143004
|
143005
|
143006
|
143007
|
143008
| 143009 |
143010
|
143011