Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
I would like to define a new type of Drupal message called "Workflow" and manage these messages separately from the standard Status, Error and Warning message types.
How can I add this new message type to the list of message types in the Rules config pages? In other words, add an extra OPTION to the SELECT list?
I've tried hook_form_alter and jQuery... but haven't had any luck.
Is there a way to do this?
Thanks,
Steve
Comments
Comment #0.0
thevine CreditAttribution: thevine commentedRemoved word
Comment #1
TR CreditAttribution: TR commentedYou will have to do this in a custom module.
Now when you use the drupal_message action your function will be used to provide the message options, instead of the default which only knows about Status, Warning, and Error.
Comment #2
TR CreditAttribution: TR commentedHere's a complete, working example module called rules_alter.
In rules.alter.info:
In rules_alter.module:
Comment #4
TR CreditAttribution: TR commented