Bugzilla – Attachment 33485 Details for
Bug 13226
Significant slowdown of checkins with fix for notices ignoring the dateformat preference
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
DO NOT PUSH: profiling for _parseletter
DO-NOT-PUSH-profiling-for-parseletter.patch (text/plain), 1.98 KB, created by
Jonathan Druart
on 2014-11-12 13:48:14 UTC
(
hide
)
Description:
DO NOT PUSH: profiling for _parseletter
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2014-11-12 13:48:14 UTC
Size:
1.98 KB
patch
obsolete
>From 0ccf35a3c467f76b638681e9dc7c1b89c09f0558 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Wed, 12 Nov 2014 14:47:28 +0100 >Subject: [PATCH] DO NOT PUSH: profiling for _parseletter > >http://bugs.koha-community.org/show_bug.cgi?id=13226 >--- > C4/Letters.pm | 6 ++++++ > 1 file changed, 6 insertions(+) > >diff --git a/C4/Letters.pm b/C4/Letters.pm >index 519c0f6..eae9dc4 100644 >--- a/C4/Letters.pm >+++ b/C4/Letters.pm >@@ -643,6 +643,7 @@ sub _parseletter { > } > > while ( my ($field, $val) = each %$values ) { >+ warn "warn replacing field $table.$field"; > my $replacetablefield = "<<$table.$field>>"; > my $replacefield = "<<$field>>"; > $val =~ s/\p{P}$// if $val && $table=~/biblio/; >@@ -651,17 +652,22 @@ sub _parseletter { > #but excludes items. Removed unneeded global and lookahead. > > $val = GetAuthorisedValueByCode ('ROADTYPE', $val, 0) if $table=~/^borrowers$/ && $field=~/^streettype$/; >+ warn "1>" . localtime; > my $replacedby = defined ($val) ? $val : ''; > if ( $replacedby > and not $replacedby =~ m|0000-00-00| > and $replacedby =~ m|^\d{4}-\d{2}-\d{2}( \d{2}:\d{2}:\d{2})?$| ) > { >+ warn "2>" . localtime; >+ warn "Trying to replace $replaced_by"; > # If the value is XXXX-YY-ZZ[ AA:BB:CC] we assume it is a date > my $dateonly = defined $1 ? 0 : 1; #$1 refers to the capture group wrapped in parentheses. In this case, that's the hours, minutes, seconds. > eval { > $replacedby = output_pref({ dt => dt_from_string( $replacedby ), dateonly => $dateonly }); > }; > warn "$replacedby seems to be a date but an error occurs on generating it ($@)" if $@; >+ warn "3>" . localtime; >+ warn "Has been replaced by $replaced_by"; > } > ($letter->{title} ) and do { > $letter->{title} =~ s/$replacetablefield/$replacedby/g; >-- >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 13226
:
33426
|
33485
|
33494
|
33495
|
33496
|
33539