Page MenuHomeIn-Portal Phabricator

INP-1880 - Fix notice on missing event permission mapping
ClosedPublic

Authored by alex on Oct 23 2024, 8:28 AM.

Details

Test Plan
  • in IDE:
    1. open the core/units/email_templates/email_template_eh.php file for editing
    2. in the \EmailTemplateEventHandler::mapPermissions method:
      • set $permissions['OnMassApprove'] key to the Array ('self' => true)
      • set $permissions['OnMassDecline'] key to the Array ('subitem' => 'debug')
      • comment out $permissions['OnSend'] key
    3. save changes
  • in Admin Console:
    1. login
    2. go to Website & ContentE-mail Templates section
    3. select any event
    4. press the Enable toolbar button
    5. confirm, that page reloaded and no error happened
    6. press the Add toolbar button
    7. confirm, that new email template form is displayed and no error happened
    8. close the new email template form
    9. press the Disable toolbar button
    10. confirm, that you've got Permission mappings not defined for event email-template <- email-template:OnMassDecline exception and no notices
    11. press the Send toolbar button
    12. confirm, that you've got Permission mappings not defined for event email-template <- email-template:OnSend exception and no notices

Diff Detail

Repository
rINP In-Portal
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

alex created this revision.Oct 23 2024, 8:28 AM
alex requested review of this revision.Oct 23 2024, 8:28 AM
Harbormaster completed remote builds in B1313: Diff 1265.
alex added a project: Restricted Project.Oct 23 2024, 8:29 AM
erik accepted this revision.Dec 19 2024, 11:51 AM
This revision is now accepted and ready to land.Dec 19 2024, 11:51 AM
This revision was automatically updated to reflect the committed changes.