diff options
Diffstat (limited to 'src/home/database/bots.py')
-rw-r--r-- | src/home/database/bots.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/home/database/bots.py b/src/home/database/bots.py index 99befc0..26fb170 100644 --- a/src/home/database/bots.py +++ b/src/home/database/bots.py @@ -37,13 +37,14 @@ class BotsDatabase(MySQLDatabase): self.commit() def add_openwrt_logs(self, - lines: List[Tuple[datetime, str]]): + lines: List[Tuple[datetime, str]], + access_point: int): now = datetime.now() with self.cursor() as cursor: for line in lines: time, text = line - cursor.execute("INSERT INTO openwrt (log_time, received_time, text) VALUES (%s, %s, %s)", - (time.strftime(datetime_fmt), now.strftime(datetime_fmt), text)) + cursor.execute("INSERT INTO openwrt (log_time, received_time, text, ap) VALUES (%s, %s, %s, %s)", + (time.strftime(datetime_fmt), now.strftime(datetime_fmt), text, access_point)) self.commit() def add_sound_hits(self, |