reverse_in_out

This commit is contained in:
SpudGunMan
2025-01-20 10:54:51 -08:00
parent 33abe646ae
commit 76006dcda7
3 changed files with 5 additions and 3 deletions
+1
View File
@@ -172,6 +172,7 @@ satList = 25544,7530
[checklist]
enabled = False
checklist_db = data/checklist.db
reverse_in_out = False
[qrz]
# QRZ Hello to new nodes with message
+3 -3
View File
@@ -120,7 +120,7 @@ def list_checkin():
timeCheckedIn = time.strftime("%H:%M:%S", time.gmtime(time.time() - time.mktime(time.strptime(row[2] + " " + row[3], "%Y-%m-%d %H:%M:%S"))))
checkin_list += "ID: " + row[1] + " checked-In for " + timeCheckedIn
if row[5] != "":
checkin_list += " note: " + row[5]
checkin_list += "📝" + row[5]
if row != rows[-1]:
checkin_list += "\n"
# if empty list
@@ -140,9 +140,9 @@ def process_checklist_command(nodeID, message, name="none", location="none"):
except IndexError:
comment = ""
# handle checklist commands
if "checkin" in message.lower():
if ("checkin" in message.lower() and not reverse_in_out) or ("checkout" in message.lower() and reverse_in_out):
return checkin(name, current_date, current_time, location, comment)
elif "checkout" in message.lower():
elif ("checkout" in message.lower() and not reverse_in_out) or ("checkin" in message.lower() and reverse_in_out):
return checkout(name, current_date, current_time, location, comment)
elif "purgein" in message.lower():
return delete_checkin(nodeID)
+1
View File
@@ -272,6 +272,7 @@ try:
# checklist
checklist_enabled = config['checklist'].getboolean('enabled', False)
checklist_db = config['checklist'].get('checklist_db', 'data/checklist.db')
reverse_in_out = config['checklist'].getboolean('reverse_in_out', False)
# qrz hello
qrz_hello_enabled = config['qrz'].getboolean('enabled', False)