fixing notification
This commit is contained in:
@@ -29,7 +29,7 @@ class NotifikasiWaService {
|
||||
// "c_6501": 0
|
||||
// }
|
||||
|
||||
if (topic === "morek") {
|
||||
if (topic === process.env.TOPIC_COD ?? "morek") {
|
||||
const dataMqtt = JSON.parse(message);
|
||||
|
||||
const resultChanel = [];
|
||||
@@ -78,11 +78,9 @@ class NotifikasiWaService {
|
||||
|
||||
const bodyMessage =
|
||||
`Hai ${dataUser.contact_name || "-"}\n` +
|
||||
`Terjadi peringatan dengan kode error ${
|
||||
errorCode?.error_code || "-"
|
||||
`Terjadi peringatan dengan kode error ${errorCode?.error_code || "-"
|
||||
} - ${errorCode?.error_code_name || "-"} ` +
|
||||
`pada device ${
|
||||
deviceNotification?.device_name || "-"
|
||||
`pada device ${deviceNotification?.device_name || "-"
|
||||
}, silahkan cek detail pada link berikut:\n` +
|
||||
`${shortUrl}`;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user