Bugzilla – Attachment 153204 Details for
Bug 34232
Item groups dropdown on add item form does not respect display order
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 34232: Make dropdown on additem page rescept display order
Bug-34232-Make-dropdown-on-additem-page-rescept-di.patch (text/plain), 1.53 KB, created by
Emily Lamancusa (emlam)
on 2023-07-07 20:33:04 UTC
(
hide
)
Description:
Bug 34232: Make dropdown on additem page rescept display order
Filename:
MIME Type:
Creator:
Emily Lamancusa (emlam)
Created:
2023-07-07 20:33:04 UTC
Size:
1.53 KB
patch
obsolete
>From 10ca4392b443088a3464241a1a5a35255fec4a1d Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Fri, 7 Jul 2023 19:31:15 +0000 >Subject: [PATCH] Bug 34232: Make dropdown on additem page rescept display > order > >To test: >1. EnableItemGroups >2. Find a record and add some new item groups with different display orders >3. Now edit an item on the record and scroll down to the dropdown underneath "+ Add to item group" >4. Notice that the values in the dropdown do not respect the display order. >5. Apply patch and restart_all >6. The display order should now be respected > >Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov> >--- > cataloguing/additem.pl | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > >diff --git a/cataloguing/additem.pl b/cataloguing/additem.pl >index 2c9871280c..4d7b00b4b0 100755 >--- a/cataloguing/additem.pl >+++ b/cataloguing/additem.pl >@@ -752,11 +752,13 @@ if( my $default_location = C4::Context->preference('NewItemsDefaultLocation') ) > } > > my @ig = Koha::Biblio::ItemGroups->search({ biblio_id => $biblionumber })->as_list(); >+#sort by display order >+my @sorted_ig = sort { $a->display_order <=> $b->display_order } @ig; > # what's the next op ? it's what we are not in : an add if we're editing, otherwise, and edit. > $template->param( > biblio => $biblio, > items => \@items, >- item_groups => \@ig, >+ item_groups => \@sorted_ig, > item_header_loop => \@header_value_loop, > subfields => $subfields, > itemnumber => $itemnumber, >-- >2.34.1
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 34232
:
153203
|
153204
|
153304
|
153305