Bug 26666 - Display issue with address information
Summary: Display issue with address information
Status: Pushed to master
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Katrin Fischer
QA Contact: Testopia
URL:
Keywords: Academy
Depends on:
Blocks:
 
Reported: 2020-10-13 11:46 UTC by Séverine Queune
Modified: 2020-11-17 20:01 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Text to go in the release notes:
Version(s) released in:
20.11.00


Attachments
Line break tag visible on master 20.06 (25.07 KB, image/png)
2020-10-13 11:46 UTC, Séverine Queune
Details
Bug 26666: Fix line breaks in addresses displayed with AddressFormat French or German (2.89 KB, patch)
2020-10-16 00:04 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 26666: Fix line breaks in addresses displayed with AddressFormat French or German (3.03 KB, patch)
2020-10-16 06:52 UTC, Séverine Queune
Details | Diff | Splinter Review
Bug 26666: Fix line breaks in addresses displayed with AddressFormat French or German (3.09 KB, patch)
2020-10-16 07:57 UTC, Julian Maurice
Details | Diff | Splinter Review
Bug 26666: (QA follow-up) Add 'USE raw' in template (961 bytes, patch)
2020-10-16 07:57 UTC, Julian Maurice
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Séverine Queune 2020-10-13 11:46:50 UTC
Created attachment 111539 [details]
Line break tag visible on master 20.06

There is a display issue with the adress informations on patron's account : city and country are separated by an unexpected line break tag visible on patronbriefinfo and /moremember.pl page.
See screenshot attached.
Comment 1 Séverine Queune 2020-10-14 16:29:34 UTC
Seen also on return page when there is a hold.
Comment 2 Katrin Fischer 2020-10-15 23:41:59 UTC
This also happens for master for AddressFormat French and German, but not for US.
Comment 3 Katrin Fischer 2020-10-16 00:04:01 UTC
Created attachment 111819 [details] [review]
Bug 26666: Fix line breaks in addresses displayed with AddressFormat French or German

When Addressformat is set to French or German the addresses on the Details
tab will display <br /> in plain text. This is because a TT variable is used
for adding line breaks that is either set to <br /> or "". Then this variable is
escaped with the html filter... so we see the HTML tag uninterpreted.
Switching to $raw for this specific case.

To test:
- Go to any patron account,
- Fill in the various address fields
- Switch the AddressFormat system preference to different settings
- Verify the false display for French and German on the Details tab and
  in the brief info on the left side in the patron account
- Apply patch
- Repeat testing
- All AddressFormats should now display correctly
Comment 4 Séverine Queune 2020-10-16 06:52:25 UTC
Created attachment 111827 [details] [review]
Bug 26666: Fix line breaks in addresses displayed with AddressFormat French or German

When Addressformat is set to French or German the addresses on the Details
tab will display <br /> in plain text. This is because a TT variable is used
for adding line breaks that is either set to <br /> or "". Then this variable is
escaped with the html filter... so we see the HTML tag uninterpreted.
Switching to $raw for this specific case.

To test:
- Go to any patron account,
- Fill in the various address fields
- Switch the AddressFormat system preference to different settings
- Verify the false display for French and German on the Details tab and
  in the brief info on the left side in the patron account
- Apply patch
- Repeat testing
- All AddressFormats should now display correctly

Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Comment 5 Séverine Queune 2020-10-16 06:55:26 UTC
Thanks Katrin for the quick patch !
Comment 6 Julian Maurice 2020-10-16 07:57:38 UTC
Created attachment 111830 [details] [review]
Bug 26666: Fix line breaks in addresses displayed with AddressFormat French or German

When Addressformat is set to French or German the addresses on the Details
tab will display <br /> in plain text. This is because a TT variable is used
for adding line breaks that is either set to <br /> or "". Then this variable is
escaped with the html filter... so we see the HTML tag uninterpreted.
Switching to $raw for this specific case.

To test:
- Go to any patron account,
- Fill in the various address fields
- Switch the AddressFormat system preference to different settings
- Verify the false display for French and German on the Details tab and
  in the brief info on the left side in the patron account
- Apply patch
- Repeat testing
- All AddressFormats should now display correctly

Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Comment 7 Julian Maurice 2020-10-16 07:57:45 UTC
Created attachment 111831 [details] [review]
Bug 26666: (QA follow-up) Add 'USE raw' in template

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Comment 8 Jonathan Druart 2020-10-25 23:08:00 UTC
Pushed to master for 20.11, thanks to everybody involved!
Comment 9 Lucas Gass 2020-11-13 19:05:00 UTC
doesn't apply cleanly to 20.05.x, no backport