simplify creatign notifications
This commit is contained in:
1 parent
a86bc59e09
commit
440ce8a12b
4 files changed
+67
-298
No files matched your search
@@ -44,27 +44,11 @@ const Notifications = () => {
|
||||
return row.notificationName;
|
||||
},
|
||||
},
|
||||
{
|
||||
id: "type",
|
||||
content: "Type",
|
||||
render: (row) => {
|
||||
return row.type;
|
||||
},
|
||||
},
|
||||
{
|
||||
id: "target",
|
||||
content: "Target",
|
||||
render: (row) => {
|
||||
const type = row.type;
|
||||
if (type === "email") {
|
||||
return row.address;
|
||||
}
|
||||
if (type === "webhook") {
|
||||
return row.config?.webhookUrl;
|
||||
}
|
||||
if (type === "pager_duty") {
|
||||
return row.config?.routingKey;
|
||||
}
|
||||
return row.address;
|
||||
},
|
||||
},
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user