Bugzilla – Attachment 44594 Details for
Bug 14956
Remove C4::Dates from files opac/*.pl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[PASSED QA] Bug 14956: (followup) Fix birthday date validation in Opac
PASSED-QA-Bug-14956-followup-Fix-birthday-date-val.patch (text/plain), 1.72 KB, created by
Kyle M Hall (khall)
on 2015-11-06 16:32:05 UTC
(
hide
)
Description:
[PASSED QA] Bug 14956: (followup) Fix birthday date validation in Opac
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2015-11-06 16:32:05 UTC
Size:
1.72 KB
patch
obsolete
>From 405395d13b59309ca6e4e90d6270299dd3ee7c11 Mon Sep 17 00:00:00 2001 >From: =?UTF-8?q?Marc=20V=C3=A9ron?= <veron@veron.ch> >Date: Thu, 5 Nov 2015 14:49:23 +0100 >Subject: [PATCH] [PASSED QA] Bug 14956: (followup) Fix birthday date validation in Opac > >To reproduce / test: > >- In Opac: Go to 'your personal details' >- Enter a valid birtday date >- In Staff client: Go to Home > Patrons > Update patron records > (Link on start page: Patrons requesting modification) >- Verify that the birtday date is correct >- Back in Opac, clear the birthday date, try to submit > => Validation message appears >- Enter an invalid date (32/32/2999 or 00/00/0000), try to submit > => Birthday date field is cleared, validation message appears. > >Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com> >Works as advertised. Wrong today corrected > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > opac/opac-memberentry.pl | 11 ++++++++--- > 1 files changed, 8 insertions(+), 3 deletions(-) > >diff --git a/opac/opac-memberentry.pl b/opac/opac-memberentry.pl >index 22fb843..ddaf914 100755 >--- a/opac/opac-memberentry.pl >+++ b/opac/opac-memberentry.pl >@@ -334,10 +334,15 @@ sub ParseCgiForBorrower { > > my $dob_dt; > $dob_dt = eval { dt_from_string( $borrower{'dateofbirth'} ); } >- if ( defined( $borrower{'dateofbirth'} ) ); >+ if ( $borrower{'dateofbirth'} ); > >- $borrower{'dateofbirth'} = output_pref ( { dt => $dob_dt, dateonly => 1, dateformat => 'iso' }) >- if ( $dob_dt ); >+ if ( $dob_dt ) { >+ $borrower{'dateofbirth'} = output_pref ( { dt => $dob_dt, dateonly => 1, dateformat => 'iso' } ); >+ } >+ else { >+ # Trigger validation >+ $borrower{'dateofbirth'} = undef; >+ } > > return %borrower; > } >-- >1.7.2.5
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 14956
:
43123
|
43356
|
43357
|
43359
|
43362
|
43408
|
44352
|
44353
|
44518
|
44534
|
44593
| 44594 |
88203
|
88204