From 0ffdf9bf13cce6c1e04e64694cc8b460409993b5 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Thu, 18 Feb 2016 16:40:47 +0000 Subject: [PATCH] Bug 15669 - alphabetize marc modification templates This patch sorts the modification templates when getting them from the database This affects the pages below: tools/batch_record_modification.pl tools/marc_modification.pl tools/stage-marc-import.pl tools/stage-marc-import.pl To test: 1 - Add some marc modification templates in a non alpha order (Shoes, Hats, Cats) 2 - visit the pages above and note the templates are in order added 3 - apply patch 4 - visit the three pages and note correct order 5 - verify all tools continue to work as expected --- C4/MarcModificationTemplates.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/C4/MarcModificationTemplates.pm b/C4/MarcModificationTemplates.pm index 203f445..d72b870 100644 --- a/C4/MarcModificationTemplates.pm +++ b/C4/MarcModificationTemplates.pm @@ -77,7 +77,7 @@ sub GetModificationTemplates { warn("C4::MarcModificationTemplates::GetModificationTemplates( $template_id )") if DEBUG; my $dbh = C4::Context->dbh; - my $sth = $dbh->prepare("SELECT * FROM marc_modification_templates"); + my $sth = $dbh->prepare("SELECT * FROM marc_modification_templates ORDER BY name"); $sth->execute(); my @templates; -- 2.1.4