mirror of
https://github.com/ShaYmez/HBMonv2.git
synced 2025-04-05 19:08:33 -04:00
Update monitor.py
This commit is contained in:
parent
41f2b476da
commit
1437717baf
@ -773,7 +773,7 @@ def process_message(_bmessage):
|
||||
f.write("<fieldset style=\"border-radius: 8px; background-color:#f0f0f0f0;margin-left:15px;margin-right:15px;font-size:14px;border-top-left-radius: 10px; border-top-right-radius: 10px;border-bottom-left-radius: 10px; border-bottom-right-radius: 10px;\">\n")
|
||||
f.write("<legend><b><font color=\"#000\"> .: DMR Server activity :. </font></b></legend>\n")
|
||||
f.write("<table style=\"width:100%; font: 10pt arial, sans-serif\">\n")
|
||||
f.write("<TR style=\" height: 32px;font: 10pt arial, sans-serif;"+THEME_COLOR+"\"><TH>Date</TH><TH>Time</TH><TH>Callsign (DMR-Id)</TH><TH>Name</TH><TH>TG#</TH><TH>TG Name</TH><TH> TX (s) </TH><TH>Slot</TH><TH>System</TH></TR>\n")
|
||||
f.write("<TR style=\" height: 32px;font: 10pt arial, sans-serif;"+THEME_COLOR+"\"><TH>Date</TH><TH>Time</TH><TH>Callsign (DMR-Id)</TH><TH>Name</TH><TH>TG#</TH><TH>TG Name</TH><TH> TX (s) </TH><TH>System</TH></TR>\n")
|
||||
with open(LOG_PATH+"lastheard.log", "r") as textfile:
|
||||
for row in islice(reversed(list(csv.reader(textfile))),400):
|
||||
duration_in_s = 0
|
||||
@ -804,11 +804,11 @@ def process_message(_bmessage):
|
||||
else:
|
||||
qrz = "<a style=\"font: 9pt arial,sans-serif;font-weight:bold;color:#0066ff;\" target=\"_blank\" href=https://qrz.com/db/"+row[11]+">"+row[11]+"</a></b><span style=\"font: 7pt arial,sans-serif\"> ("+row[10]+")</span>"
|
||||
if len(row) < 13:
|
||||
hline="<TR style=\"background-color:#f9f9f9f9;\"><TD>"+row[0][:10]+"</TD><TD>"+row[0][11:16]+"</TD><TD>"+qrz+"</TD><TD><font color=#002d62><b></b></font></TD><TD><font color=#b5651d><b>"+row[8][2:]+"</b></font></TD><TD><font color=green><b>"+row[9]+"</b></font></TD>"+durtx+"<TD>"+row[7][2:]+"</TD><TD>"+row[4]+"</TD></TR>"
|
||||
hline="<TR style=\"background-color:#f9f9f9f9;\"><TD>"+row[0][:10]+"</TD><TD>"+row[0][11:16]+"</TD><TD>"+qrz+"</TD><TD><font color=#002d62><b></b></font></TD><TD><font color=#b5651d><b>"+row[8][2:]+"</b></font></TD><TD><font color=green><b>"+row[9]+"</b></font></TD><TD>"+durtx+"</TD><TD>"+row[4]+"</TD></TR>"
|
||||
my_list.append(row[10])
|
||||
n += 1
|
||||
else:
|
||||
hline="<TR style=\"background-color:#f9f9f9f9;\"><TD>"+row[0][:10]+"</TD><TD>"+row[0][11:16]+"</TD><TD>"+qrz+"</TD><TD><font color=#002d62><b>"+row[12]+"</b></font></TD><TD><font color=#b5651d><b>"+row[8][2:]+"</b></font></TD><TD><font color=green><b>"+row[9]+"</b></font></TD>"+durtx+"<TD>"+row[7][2:]+"</TD><TD>"+row[4]+"</TD></TR>"
|
||||
hline="<TR style=\"background-color:#f9f9f9f9;\"><TD>"+row[0][:10]+"</TD><TD>"+row[0][11:16]+"</TD><TD>"+qrz+"</TD><TD><font color=#002d62><b>"+row[12]+"</b></font></TD><TD><font color=#b5651d><b>"+row[8][2:]+"</b></font></TD><TD><font color=green><b>"+row[9]+"</b></font></TD><TD>"+durtx+"</TD><TD>"+row[4]+"</TD></TR>"
|
||||
my_list.append(row[10])
|
||||
n += 1
|
||||
f.write(hline+"\n")
|
||||
|
Loading…
Reference in New Issue
Block a user