Ad Widget

Collapse

JSON to HTML table in email

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • wonderfulll
    Junior Member
    • Dec 2020
    • 1

    #1

    JSON to HTML table in email

    Hello! Help me, please. Zabbix 4.4. I have an item that gets data from db.odbc.get request. I get something like this:

    [{"TASK":"TASK555556","STATE":"6"},{"TASK":"TASK999 956","STATE":"5"},{"TASK":"TASK9222","STATE":"1"}]

    Quantity of these TASKs varies every request. I need to send this information via email in a table view. It must be table with two columns (TASK and STATE). Help, how can I do this. By preprocessing, or actions or else...
  • CharlieRoot
    Junior Member
    Zabbix Certified Specialist
    • Oct 2020
    • 15

    #2
    I would say you could use preprocessing, create a custom Javascript for it to transform JSON to HTML.

    Comment

    Working...