The 'age' check is in the wrong location in patron-age.inc and removes the date of birth date entirely when the patrons age is '0' years.
Created attachment 116936 [details] [review] Bug 27717: Display date of birth even if the patron is under 1 This patch moves the 'age' condition to below the date of birth display, allowing the date to display for babies. Test plan 1/ Add a user with a date of birth within the last year 2/ Check that the date of birth appears on the patron details page (under contact details) with the patch applied.
This breaks patron search in the patrons module--the JSON is broken.
Created attachment 116999 [details] [review] Bug 27717: Display date of birth even if the patron is under 1 This patch moves the 'age' condition to below the date of birth display, allowing the date to display for babies. Test plan 1/ Add a user with a date of birth within the last year 2/ Check that the date of birth appears on the patron details page (under contact details) with the patch applied.
OK, That was rather unexpected!.. Thanks for testing Owen, new patch attached.
Created attachment 117094 [details] [review] Bug 27717: Display date of birth even if the patron is under 1 This patch moves the 'age' condition to below the date of birth display, allowing the date to display for babies. Test plan 1/ Add a user with a date of birth within the last year 2/ Check that the date of birth appears on the patron details page (under contact details) with the patch applied. Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov>
The birthdate and age calculation appeared correctly. I was also able to search for patrons. Everything looked good to me.
Created attachment 117756 [details] [review] Bug 27717: Display date of birth even if the patron is under 1 This patch moves the 'age' condition to below the date of birth display, allowing the date to display for babies. Test plan 1/ Add a user with a date of birth within the last year 2/ Check that the date of birth appears on the patron details page (under contact details) with the patch applied. Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Pushed to master for 21.05, thanks to everybody involved!
Pushed to 20.11.x for 20.11.04
Missing dependency, not backported to 20.05