I noticed this on 16.05 and 16.11. If a patron categorycode is I, the patron detail page is broken. Test plan : 1. Create a a new patron category. Use "I" as a category code. 2. Go to patron detail page 3. Change the patron category for this new one. Save. 4. The patron detail page is broken.
I think there might be a confusion of variables - I is also the code for the category type of Institutional = Organisation patrons. I will investigate a bit.
Created attachment 66152 [details] [review] Bug 19129 - Clean up Details tab for Organisation patrons Problem: A patron category "I" would cause display problems on the details in the intranet. This is because the templates confused patron category "I" with patron type "I" (organisation). Patch: - Cleans up variable confusion by introducint a new variable 'is_organisation' instead of using 'I'. - The template contained code to change the labels below the address to 'Organisational phone:" etc., I have removed this part as it does not match the edit form anymore. - Initials, date of birth and gender are still hidden for organisation - matching the edit form. Bonus: - The patron category description was missing on the right and left side of the details tab. Now it displays. - Fixes some html issues: - doubled up class attribute in a tag - doubled up </li></li> To test: - Create 3 patrons - patron category code doesn't matter, but category type organisation - patron category code 'I', category type NOT organisation - patron category code NOT I, category type NOT organisaton - Check details tab in patron account in staff for all 3 - Verify patron category description shows correctly - Verify information added to the account displays correctly (phone numbers, emails, ...)
Created attachment 66153 [details] [review] Bug 19129 - Clean up Details tab for Organisation patrons Problem: A patron category "I" would cause display problems on the details in the intranet. This is because the templates confused patron category "I" with patron type "I" (organisation). Patch: - Cleans up variable confusion by introducint a new variable 'is_organisation' instead of using 'I'. - The template contained code to change the labels below the address to 'Organisational phone:" etc., I have removed this part as it does not match the edit form anymore. - Initials, date of birth and gender are still hidden for organisation - matching the edit form. Bonus: - The patron category description was missing on the right and left side of the details tab. Now it displays. - Fixes some html issues: - doubled up class attribute in a tag - doubled up </li></li> To test: - Create 3 patrons - patron category code doesn't matter, but category type organisation - patron category code 'I', category type NOT organisation - patron category code NOT I, category type NOT organisaton - Check details tab in patron account in staff for all 3 - Verify patron category description shows correctly - Verify information added to the account displays correctly (phone numbers, emails, ...)
Created attachment 66155 [details] [review] Bug 19129 - Clean up Details tab for Organisation patrons Problem: A patron category "I" would cause display problems on the details in the intranet. This is because the templates confused patron category "I" with patron type "I" (organisation). Patch: - Cleans up variable confusion between categorycode and categorytype. - The template contained code to change the labels below the address to 'Organisational phone:" etc., I have removed this part as it does not match the edit form anymore. - Initials, date of birth and gender are still hidden for organisation - matching the edit form. Bonus: - The patron category description was missing on the right and left side of the details tab. Now it displays. - Fixes some html issues: - doubled up class attribute in a tag - doubled up </li></li> To test: - Create 3 patrons - patron category code doesn't matter, but category type organisation - patron category code 'I', category type NOT organisation - patron category code NOT I, category type NOT organisaton - Check details tab in patron account in staff for all 3 - Verify patron category description shows correctly - Verify information added to the account displays correctly (phone numbers, emails, ...)
Created attachment 66156 [details] [review] Bug 19129 - Follow-up - Add changes to patron duplicate warning Adds logic from the previous fix to the brief patron summary shown when checking a possible patron duplicate. Bonus: Also fixes missing patron category description there. To Test: - Add 2 patrons - Add a patron with the same surname and firstname as an existing patron in order to trigger the duplicate message - Click "View existing patron" - Verify display is correct when existing patron is - an organisation - not an organisation - Verify that the patron category description shows
Created attachment 66257 [details] [review] [SIGNED-OFF] Bug 19129 - Clean up Details tab for Organisation patrons Problem: A patron category "I" would cause display problems on the details in the intranet. This is because the templates confused patron category "I" with patron type "I" (organisation). Patch: - Cleans up variable confusion between categorycode and categorytype. - The template contained code to change the labels below the address to 'Organisational phone:" etc., I have removed this part as it does not match the edit form anymore. - Initials, date of birth and gender are still hidden for organisation - matching the edit form. Bonus: - The patron category description was missing on the right and left side of the details tab. Now it displays. - Fixes some html issues: - doubled up class attribute in a tag - doubled up </li></li> To test: - Create 3 patrons - patron category code doesn't matter, but category type organisation - patron category code 'I', category type NOT organisation - patron category code NOT I, category type NOT organisaton - Check details tab in patron account in staff for all 3 - Verify patron category description shows correctly - Verify information added to the account displays correctly (phone numbers, emails, ...) Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Created attachment 66258 [details] [review] [SIGNED-OFF] Bug 19129 - Follow-up - Add changes to patron duplicate warning Adds logic from the previous fix to the brief patron summary shown when checking a possible patron duplicate. Bonus: Also fixes missing patron category description there. To Test: - Add 2 patrons - Add a patron with the same surname and firstname as an existing patron in order to trigger the duplicate message - Click "View existing patron" - Verify display is correct when existing patron is - an organisation - not an organisation - Verify that the patron category description shows Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Created attachment 66713 [details] [review] Bug 19129 - Clean up Details tab for Organisation patrons Problem: A patron category "I" would cause display problems on the details in the intranet. This is because the templates confused patron category "I" with patron type "I" (organisation). Patch: - Cleans up variable confusion between categorycode and categorytype. - The template contained code to change the labels below the address to 'Organisational phone:" etc., I have removed this part as it does not match the edit form anymore. - Initials, date of birth and gender are still hidden for organisation - matching the edit form. Bonus: - The patron category description was missing on the right and left side of the details tab. Now it displays. - Fixes some html issues: - doubled up class attribute in a tag - doubled up </li></li> To test: - Create 3 patrons - patron category code doesn't matter, but category type organisation - patron category code 'I', category type NOT organisation - patron category code NOT I, category type NOT organisaton - Check details tab in patron account in staff for all 3 - Verify patron category description shows correctly - Verify information added to the account displays correctly (phone numbers, emails, ...) Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Created attachment 66714 [details] [review] Bug 19129 - Follow-up - Add changes to patron duplicate warning Adds logic from the previous fix to the brief patron summary shown when checking a possible patron duplicate. Bonus: Also fixes missing patron category description there. To Test: - Add 2 patrons - Add a patron with the same surname and firstname as an existing patron in order to trigger the duplicate message - Click "View existing patron" - Verify display is correct when existing patron is - an organisation - not an organisation - Verify that the patron category description shows Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Pushed to master for 17.11, thanks to everybody involved!
Pushed to 17.05.x, will be in 17.05.05.
Doesn't apply cleanly - will need more work.
I don't have the time to rebase patches for 16.11.x. Closing.