Bugzilla – Attachment 55165 Details for
Bug 14060
Remove readonly on date inputs
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14060: Consider an empty string as a valid date
Bug-14060-Consider-an-empty-string-as-a-valid-date.patch (text/plain), 1.11 KB, created by
Jonathan Druart
on 2016-09-05 08:16:39 UTC
(
hide
)
Description:
Bug 14060: Consider an empty string as a valid date
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2016-09-05 08:16:39 UTC
Size:
1.11 KB
patch
obsolete
>From 1cf6fe52d0360131b96c6121ec32ea1ea240b0bb Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 5 Sep 2016 09:16:02 +0100 >Subject: [PATCH] Bug 14060: Consider an empty string as a valid date > >--- > koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc | 3 +++ > 1 file changed, 3 insertions(+) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >index 14ec21d..7175df2 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >@@ -9,6 +9,9 @@ if (debug > 1) {alert("dateformat: " + dformat + "\ndebug is on (level " + debug > var MSG_PLEASE_ENTER_A_VALID_DATE = _("Please enter a valid date (should match %s)."); > > function is_valid_date(date) { >+ // An empty string is considered as a valid date for convenient reasons. >+ if ( date === '' ) return 1; >+ > var dateformat = dateformat_str = '[% Koha.Preference('dateformat') %]'; > if ( dateformat == 'us' ) { > if ( date.search(/\d{2}\/\d{2}\/\d{4}/) == -1 ) return 0; >-- >2.8.1
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 14060
:
38484
|
38540
|
38541
|
44542
|
44543
|
44544
|
45282
|
46224
|
54606
|
54607
|
54608
|
54609
|
54610
|
54902
|
54903
|
54904
|
54905
|
54906
|
54907
|
55001
|
55002
|
55012
|
55013
|
55014
|
55015
|
55016
|
55017
|
55018
|
55019
|
55165
|
55246
|
55247
|
55248
|
55249
|
55250
|
55251
|
55252
|
55253
|
55254
|
55255
|
55256