Bug 9329: Wrong message for already expired cards
authorAdrien Saurat <adrien.saurat@biblibre.com>
Fri, 28 Dec 2012 15:37:59 +0000 (16:37 +0100)
committerJared Camins-Esakov <jcamins@cpbibliography.com>
Fri, 8 Feb 2013 14:07:21 +0000 (09:07 -0500)
commit0dca3e58a77fc18e2424066e23af42b440be11f5
treec4b8c7bafaa90541f92414e16499117209801230
parent606279b5f19d9a6da48dfae7ed61e110ab245e72
Bug 9329: Wrong message for already expired cards

Previously users would see the same message whether their card was about
to expire or was already expired. This patch adds a new message to
handle cards which are about to expire, following the
NotifyBorrowerDeparture system preference.

TEST PLAN :

The best way to test would to have at the same time :
- a SQL client to change the expiry date of a borrower
- an OPAC session opened for the same patron.

Case 1: expiry date is set in the future
-> no warning

Case 2: expiry date is set in the near future (within the
"NotifyBorrowerDeparture" system preference range)
-> a warning says the card will expire on **date**

Case 3: expiry date is set in the past
-> before patch, same warning as Case 2
-> after patch, new warning indicating that the card has expired

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Added description to the patch and copied test plan from the bug report.
Patch passes test plan.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt
opac/opac-user.pl