Bugzilla – Attachment 57006 Details for
Bug 17524
Datepicker on checkout fails when dateformat = iso
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 17524: Fix datepicker check for iso dates
Bug-17524-Fix-datepicker-check-for-iso-dates.patch (text/plain), 1.36 KB, created by
Mark Tompsett
on 2016-10-31 15:41:05 UTC
(
hide
)
Description:
Bug 17524: Fix datepicker check for iso dates
Filename:
MIME Type:
Creator:
Mark Tompsett
Created:
2016-10-31 15:41:05 UTC
Size:
1.36 KB
patch
obsolete
>From 059b73a119e06cf132e01baa3f80f1f2c280c113 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 31 Oct 2016 14:40:51 +0000 >Subject: [PATCH] Bug 17524: Fix datepicker check for iso dates > >Iso dates are yyyy-mm-dd, the is_valid JS function >expects \d{2}-\d{2}-\d{4} when it should be \d{4}-\d{2}-\d{2} > >Test plan: >Switch DateFormat to iso >Set a due date using the datepicker >=> Should work as expected > >Signed-off-by: Mark Tompsett <mtompset@hotmail.com> >--- > koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >index aba713e..f6d9e9b 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >@@ -20,7 +20,7 @@ function is_valid_date(date) { > if ( date.search(/^\d{2}\/\d{2}\/\d{4}($|\s)/) == -1 ) return 0; > dateformat = 'dd/mm/yy'; > } else if (dateformat == 'iso' ) { >- if ( date.search(/^\d{2}-\d{2}-\d{4}($|\s)/) == -1 ) return 0; >+ if ( date.search(/^\d{4}-\d{2}-\d{2}($|\s)/) == -1 ) return 0; > dateformat = 'yy-mm-dd'; > } else if ( dateformat == 'dmydot' ) { > if ( date.search(/^\d{2}\.\d{2}\.\d{4}($|\s)/) == -1 ) return 0; >-- >2.1.4
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 17524
:
57001
|
57006
|
57007