Add description to monitor

* Add description to monitor model
* Add description field to database
* Add english and spanish translation for description
* Closes: #482
This commit is contained in:
Juan Cruz Vincenti
2021-11-11 20:06:32 -03:00
parent 5bc68d7f3b
commit 934d633d4d
10 changed files with 26 additions and 0 deletions

View File

@@ -53,6 +53,7 @@ class Database {
"patch-2fa-invalidate-used-token.sql": true,
"patch-notification_sent_history.sql": true,
"patch-monitor-basic-auth.sql": true,
"patch-add-description-monitor.sql": true,
}
/**

View File

@@ -31,6 +31,7 @@ class Monitor extends BeanModel {
return {
id: this.id,
name: this.name,
description: this.description,
};
}
@@ -54,6 +55,7 @@ class Monitor extends BeanModel {
return {
id: this.id,
name: this.name,
description: this.description,
url: this.url,
method: this.method,
body: this.body,

View File

@@ -568,6 +568,7 @@ exports.entryPage = "dashboard";
}
bean.name = monitor.name;
bean.description = monitor.description;
bean.type = monitor.type;
bean.url = monitor.url;
bean.method = monitor.method;
@@ -1134,6 +1135,7 @@ exports.entryPage = "dashboard";
let monitor = {
// Define the new variable from earlier here
name: monitorListData[i].name,
description: monitorListData[i].description,
type: monitorListData[i].type,
url: monitorListData[i].url,
method: monitorListData[i].method || "GET",