Änderungen von Dokument Servermeldungen (SaaS)

Zuletzt geändert von MACH ProForms GmbH am 22.07.2024

Von Version 13.1
bearbeitet von MACH ProForms GmbH
am 17.07.2024
Änderungskommentar: Es gibt keinen Kommentar für diese Version
Auf Version 19.1
bearbeitet von MACH ProForms GmbH
am 22.07.2024
Änderungskommentar: Es gibt keinen Kommentar für diese Version

Zusammenfassung

Details

Seiteneigenschaften
Inhalt
... ... @@ -2,20 +2,7 @@
2 2  
3 3  Hier finden unsere SaaS-Kunden und Benutzer eine dynamische Anzeige der Uptime der Services und die geplanten Wartungsintervalle.
4 4  
5 -(% class="box infomessage" %)
6 -
7 7  {{html}}
8 - <style>
9 - .status-up {
10 - color: rgb(3, 133, 3); /* Green text color for "UP" status */
11 - }
12 - .status-down {
13 - color: rgb(187, 9, 9); /* Red text color for "DOWN" status */
14 - }
15 - .status-maintenance {
16 - color: gold; /* Gold text color for "Under Maintenance" status */
17 - }
18 - </style>
19 19  <!-- Servers Status -->
20 20  <div>
21 21   <h2>&Uuml;berblick Status</h2>
... ... @@ -65,8 +65,24 @@
65 65  
66 66   data.hostStatus.forEach(host => {
67 67   const listItem = document.createElement('li');
68 - listItem.innerHTML = `<span class="host-name">${host.host}:</span> <span class="status-${getStatusColor(host.status)}"><strong>${getStatusText(host.status)}</strong></span>`;
55 + const statusSpan = document.createElement('span');
56 + statusSpan.innerHTML = `<strong>${getStatusText(host.status)}</strong>`;
69 69  
58 + switch (host.status) {
59 + case 'Up':
60 + statusSpan.style.color = 'rgb(3, 133, 3)';
61 + break;
62 + case 'Down':
63 + statusSpan.style.color = 'rgb(187, 9, 9)';
64 + break;
65 + case 'Under Maintenance':
66 + statusSpan.style.color = 'gold';
67 + break;
68 + }
69 +
70 + listItem.innerHTML = `<span class="host-name">${host.host}:</span> `;
71 + listItem.appendChild(statusSpan);
72 +
70 70   if (host.host === "pdf.form-solutions.net" || host.host === "onlinedienste.form-solutions.de") {
71 71   productiveSystemsList.appendChild(listItem);
72 72   } else {
... ... @@ -99,20 +99,6 @@
99 99   }
100 100   }
101 101  
102 - // Function to get the appropriate status color class
103 - function getStatusColor(status) {
104 - switch (status) {
105 - case 'Up':
106 - return 'up';
107 - case 'Down':
108 - return 'down';
109 - case 'Under Maintenance':
110 - return 'maintenance';
111 - default:
112 - return '';
113 - }
114 - }
115 -
116 116   window.addEventListener('load', fetchData);
117 117  </script>
118 118  {{/html}}