Bugzilla – Attachment 67448 Details for
Bug 18447
Datepicker only shows -10/+10 years for date of birth
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18447: (follow-up) years range not dependent on current value
Bug-18447-follow-up-years-range-not-dependent-on-c.patch (text/plain), 2.18 KB, created by
Fridolin Somers
on 2017-09-29 13:15:38 UTC
(
hide
)
Description:
Bug 18447: (follow-up) years range not dependent on current value
Filename:
MIME Type:
Creator:
Fridolin Somers
Created:
2017-09-29 13:15:38 UTC
Size:
2.18 KB
patch
obsolete
>From 52aa60ed2d5edf561d6cc0ecf2f4bf839eb40a89 Mon Sep 17 00:00:00 2001 >From: Fridolin Somers <fridolin.somers@biblibre.com> >Date: Fri, 29 Sep 2017 14:44:51 +0200 >Subject: [PATCH] Bug 18447: (follow-up) years range not dependent on current > value > >Bug 18447 sets for date of birth a year range "c-100:c" meaning current year and 100 years earlier. >This is good when imput is empty. >But when input already contains a date, say "01/01/1950", years range is 1850 to 1950. > >This patch sets for date of birth a year range "-120:+0" to not be dependent on current value. >Some people may have more than 100 years (maybe more often in the future) so i choose to propose maximum 120 years old. > >To test : >1) Go to intranet >2) Create a new patron >3) Click on date picker on "Date of birth" input >4) Look at available years in combobox, you see from 1897 to 2017 >5) Edit an existing patron with for example date of birth in 1950 >6) Repeat 3) and 4) >7) Go to OPAC >8) Login with a patron with for example date of birth in 1950 >9) Go to "your personal details" >10) Repeate 3) and 4) >--- > koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc | 2 +- > koha-tmpl/opac-tmpl/bootstrap/en/includes/calendar.inc | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >index f13a1fa..e8bf5e1 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/calendar.inc >@@ -140,7 +140,7 @@ $.datepicker.setDefaults({ > }); > > $("#dateofbirth").datepicker({ >- yearRange: "c-100:c" >+ yearRange: "-120:+0" > }); > > $( ".datepicker" ).datepicker({ >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/includes/calendar.inc b/koha-tmpl/opac-tmpl/bootstrap/en/includes/calendar.inc >index 018cdb6..fb086c1 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/calendar.inc >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/includes/calendar.inc >@@ -61,7 +61,7 @@ > }); > > $("#borrower_dateofbirth").datepicker({ >- yearRange: "c-100:c" >+ yearRange: "-120:+0" > }); > > $( ".datepicker" ).datepicker(); >-- >2.7.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 18447
:
62300
|
62306
|
62323
|
65116
|
65117
|
65118
|
65135
|
65136
|
65137
|
65140
|
65141
|
65142
|
65309
|
66459
|
66460
|
66461
|
66462
|
67448