-
- Downloads
#2834 Use event tokens for participant badges
Overview ---------------------------------------- Convert the rest of event badge token replacement to use the token processor Before ---------------------------------------- Testing and conversion had been done for contact and participant tokens within the event badges - but for the event tokens tests had been added but the conversion was pending solving date formatting After ---------------------------------------- Event badges use the token processor for event tokens At this point all token processing in core for participant or event tokens is done in the token processor & attention can switch to cleaning that up Technical Details ---------------------------------------- The challenge switching over event tokens was that badges used a custom date format and we needed to figure out how to support that first. This also standardises the event.event_id token to participant.event_id and updates it in the db for scheduled reminders (badges were using 'event.id' format & reminders the event.event_id format). There are still some tokens on the scheduled reminders to standarsise and a loading challenge to fix - but this concludes the badge portion of fixing up event tokens Note that the tokenConsistencyTest is the main test cover for event tokens and it turns out we are not quite there on the dates based on https://github.com/civicrm/civicrm-core/pull/21584
Showing
- CRM/Badge/BAO/Badge.php 19 additions, 42 deletionsCRM/Badge/BAO/Badge.php
- CRM/Badge/Form/Layout.php 7 additions, 3 deletionsCRM/Badge/Form/Layout.php
- CRM/Event/Tokens.php 84 additions, 27 deletionsCRM/Event/Tokens.php
- CRM/Upgrade/Incremental/php/FiveFortyThree.php 12 additions, 4 deletionsCRM/Upgrade/Incremental/php/FiveFortyThree.php
- sql/civicrm_generated.mysql 4050 additions, 4032 deletionssql/civicrm_generated.mysql
- tests/phpunit/CRM/Event/Form/Task/BadgeTest.php 4 additions, 4 deletionstests/phpunit/CRM/Event/Form/Task/BadgeTest.php
- tests/phpunit/CRM/Utils/TokenConsistencyTest.php 4 additions, 4 deletionstests/phpunit/CRM/Utils/TokenConsistencyTest.php
- xml/templates/civicrm_navigation.tpl 1 addition, 1 deletionxml/templates/civicrm_navigation.tpl
Loading
Please register or sign in to comment