https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43296 --- Comment #12 from Pedro Amorim (ammopt) <pedro.amorim@openfifth.co.uk> --- Created attachment 205329 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=205329&action=edit Bug 43296: Support valid patron attribute codes in circulation stats Circulation statistics only recognise numeric patron attribute codes, while patron attribute type codes are not restricted to numbers. Validate Row, Column and Filter_borrower_attributes against the available patron attribute types. Use generated SQL aliases and pass attribute codes as bind parameters. Test plan: 1. In Administration > Patron attribute types, create attribute types with codes SHOW-BCODE, SHOW.BCODE, SHOW BCODE and SQL); DROP TABLE borrowers; --.. 2. Go to Reports > Statistics wizards > Circulation. 3. Use each attribute as Row and Column with an ordinary field on the other axis. 4. Confirm the report fails or uses the wrong field. Apply the patch. 5. Restart Plack. 6. Repeat steps 3-4. 7. Confirm the reports succeed and use the selected patron attribute. 8. Test the same attributes as filters. 9. Confirm ordinary Row, Column and Filter fields still work. Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> -- You are receiving this mail because: You are watching all bug changes.