Bugzilla – Attachment 192170 Details for
Bug 40813
Add ability to embed page start and end timing
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40813: (follow-up) Add milliseconds
Bug-40813-follow-up-Add-milliseconds.patch (text/plain), 3.48 KB, created by
Kyle M Hall (khall)
on 2026-01-29 16:52:12 UTC
(
hide
)
Description:
Bug 40813: (follow-up) Add milliseconds
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2026-01-29 16:52:12 UTC
Size:
3.48 KB
patch
obsolete
>From 19cd246ef4019ee4acd29764d0b619ee26e7b244 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Thu, 29 Jan 2026 11:51:02 -0500 >Subject: [PATCH] Bug 40813: (follow-up) Add milliseconds > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > C4/Auth.pm | 4 ++-- > Koha/DateUtils.pm | 3 ++- > koha-tmpl/intranet-tmpl/prog/en/includes/intranet-bottom.inc | 4 ++-- > 3 files changed, 6 insertions(+), 5 deletions(-) > >diff --git a/C4/Auth.pm b/C4/Auth.pm >index 8414922ef0f..975fb81e0e0 100644 >--- a/C4/Auth.pm >+++ b/C4/Auth.pm >@@ -165,7 +165,7 @@ Output.pm module. > =cut > > sub get_template_and_user { >- my $start_time = dt_from_string; >+ my $start_time = DateTime->from_epoch( epoch => Time::HiRes::time() ); > > my $in = shift; > my ( $user, $cookie, $sessionID, $flags ); >@@ -1239,7 +1239,7 @@ sub checkauth { > : Koha::Cash::Registers->search( > { branch => $branchcode, branch_default => 1 }, > { rows => 1 } >- )->single; >+ )->single; > $register_id = $register->id if ($register); > $register_name = $register->name if ($register); > } >diff --git a/Koha/DateUtils.pm b/Koha/DateUtils.pm >index f822dfbf05f..604be135388 100644 >--- a/Koha/DateUtils.pm >+++ b/Koha/DateUtils.pm >@@ -29,6 +29,7 @@ BEGIN { > } > > use DateTime; >+use Time::HiRes; > use C4::Context; > use Koha::Exceptions; > use Koha::DateTime::Format::RFC3339; >@@ -69,7 +70,7 @@ sub dt_from_string { > my $server_tz = C4::Context->tz; > $tz = C4::Context->tz unless $tz; > >- return DateTime->now( time_zone => $tz ) unless $date_string; >+ return DateTime->from_epoch( epoch => Time::HiRes::time(), time_zone => $tz ) unless $date_string; > > $date_format = C4::Context->preference('dateformat') unless $date_format; > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/intranet-bottom.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/intranet-bottom.inc >index c1340280d42..eb06243a998 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/intranet-bottom.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/intranet-bottom.inc >@@ -98,7 +98,7 @@ > <span class="navbar-text start_time" data-start="[% start_time | html %]"> > <span class="badge text-bg-light"> > Start >- <span class="badge bg-info-subtle">[% start_time.hms(':') | html %]</span> >+ <span class="badge bg-info-subtle">[% start_time.hms(':') | html %]:[% start_time.millisecond | format('%03d') | html %]</span> > </span> > </span> > >@@ -106,7 +106,7 @@ > <span class="navbar-text end_time" data-end="[% end_time | html %]"> > <span class="badge text-bg-light"> > End >- <span class="badge bg-primary-subtle">[% end_time.hms(':') | html %]</span> >+ <span class="badge bg-primary-subtle">[% end_time.hms(':') | html %]:[% end_time.millisecond | format('%03d') | html %]</span> > </span> > </span> > </div> >-- >2.50.1 (Apple Git-155)
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 40813
:
186445
|
186490
|
192095
|
192117
|
192128
|
192167
|
192168
|
192169
| 192170