Merge remote-tracking branch 'origin/new/bug_7178'
[koha-ffzg.git] / opac / opac-tags.pl
index dc229fd..36bc096 100755 (executable)
 # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 # A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
 #
-# You should have received a copy of the GNU General Public License along with
-# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
-# Suite 330, Boston, MA  02111-1307 USA
+# You should have received a copy of the GNU General Public License along
+# with Koha; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 
 
-=head1 
+=head1 NAME
+
+opac-tags.pl
+
+=head1 DESCRIPTION
 
 TODO :: Description here
 
@@ -35,7 +39,6 @@ use C4::Auth qw(:DEFAULT check_cookie_auth);
 use C4::Context;
 use C4::Debug;
 use C4::Output 3.02 qw(:html :ajax pagination_bar);
-use C4::Dates qw(format_date);
 use C4::Scrubber;
 use C4::Biblio;
 use C4::Tags qw(add_tag get_approval_rows get_tag_rows remove_tag);
@@ -49,7 +52,7 @@ my $perBibResults = {};
 # Indexes of @errors that do not apply to a particular biblionumber.
 my @globalErrorIndexes = ();
 
-sub ajax_auth_cgi ($) {     # returns CGI object
+sub ajax_auth_cgi {     # returns CGI object
        my $needed_flags = shift;
        my %cookies = fetch CGI::Cookie;
        my $input = CGI->new;
@@ -228,7 +231,6 @@ if ($loggedinuser) {
                my $date = $_->{date_created} || '';
                $date =~ /\s+(\d{2}\:\d{2}\:\d{2})/;
                $_->{time_created_display} = $1;
-               $_->{date_created_display} = format_date($_->{date_created});
        }
 }
 
@@ -289,7 +291,7 @@ if ($add_op) {
        }
 }
 (scalar @errors  ) and $template->param(ERRORS  => \@errors);
-my @orderedresult = sort { $a->{'term'} cmp $b->{'term'} } @$results;
+my @orderedresult = sort { uc($a->{'term'}) cmp uc($b->{'term'}) } @$results;
 (scalar @$results) and $template->param(TAGLOOP => \@orderedresult );
 (scalar @$my_tags) and $template->param(MY_TAGS => $my_tags);