Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Get level of notification in Cpanel::iContact::Provider::Example

Discussion in 'cPanel Developers' started by nicoalonsop, Aug 25, 2017.

  1. nicoalonsop

    nicoalonsop Registered

    Joined:
    Jul 10, 2017
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Uruguay
    cPanel Access Level:
    Root Administrator
    Hi, Im creating a Custom Server Notification for Slack and i cant find how can i get the level of importance of the notification inside the Provider Module. I need it to put different colors.

    Can anyone help me?

    Thanks in advance.
     
  2. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,512
    Likes Received:
    32
    Trophy Points:
    308
    cPanel Access Level:
    Root Administrator
    Hi,

    We don't currently include the notification level in the notification object :( I'll file a case to have that added.
     
  3. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,512
    Likes Received:
    32
    Trophy Points:
    308
    cPanel Access Level:
    Root Administrator
    Case CPANEL-15504 was filed to include the notification priority.

    It is currently possible to use the human-friendly form of the notification priority by accessing CPANEL.module_event_importance_description in your template. That provides a textual form of the level, which may be localized. I've requested we provide the numerical form along with the human-friendly version.
     
Loading...

Share This Page