Bugzilla – Attachment 37569 Details for
Bug 9472
Improve sequence of subfields used and unused while cataloguing
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 9472: Order subfields alphabeticaly when cataloging
Bug-9472-Order-subfields-alphabeticaly-when-catalo.patch (text/plain), 1.80 KB, created by
Jonathan Druart
on 2015-04-08 10:28:36 UTC
(
hide
)
Description:
Bug 9472: Order subfields alphabeticaly when cataloging
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2015-04-08 10:28:36 UTC
Size:
1.80 KB
patch
obsolete
>From 65f9b37b145aab8ae18a8758097965c331cfdf1d Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Wed, 8 Apr 2015 12:24:28 +0200 >Subject: [PATCH] Bug 9472: Order subfields alphabeticaly when cataloging > >On cataloging a record, the subfields without data were put at the end >of the other subfields. >This patch orders the subfields alphabeticaly even if they don't containt any data. > >Test plan: >1/ Edit a record with some subfields without any data >=> The subfield should not be visible (maybe they are if they are >mandatory). >2/ Click on a tag to expand the subfield list. >3/ The subfields should be ordered alphabaticaly >--- > cataloguing/addbiblio.pl | 2 ++ > 1 file changed, 2 insertions(+) > >diff --git a/cataloguing/addbiblio.pl b/cataloguing/addbiblio.pl >index 5d46d09..6f63eea 100755 >--- a/cataloguing/addbiblio.pl >+++ b/cataloguing/addbiblio.pl >@@ -640,6 +640,7 @@ sub build_tabs { > # note that the random() field is mandatory. Otherwise, on repeated fields, you'll > # have twice the same "name" value, and cgi->param() will return only one, making > # all subfields to be merged in a single field. >+ @subfields_data = sort { $a->{subfield} cmp $b->{subfield} } @subfields_data; > my %tag_data = ( > tag => $tag, > index => $index_tag, >@@ -686,6 +687,7 @@ sub build_tabs { > ); > } > if ( $#subfields_data >= 0 ) { >+ @subfields_data = sort { $a->{subfield} cmp $b->{subfield} } @subfields_data; > my %tag_data = ( > tag => $tag, > index => $index_tag, >-- >2.1.0
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 9472
:
37569