recording card tapping

This commit is contained in:
iWarpBTC
2022-08-09 18:36:42 +02:00
committed by Gene Takavic
parent 519866efc9
commit c39bea3d54
5 changed files with 102 additions and 7 deletions
+16
View File
@@ -18,3 +18,19 @@ async def m001_initial(db):
);
"""
)
await db.execute(
"""
CREATE TABLE boltcards.hits (
id TEXT PRIMARY KEY,
card_id TEXT NOT NULL,
ip TEXT NOT NULL,
useragent TEXT,
old_ctr INT NOT NULL DEFAULT 0,
new_ctr INT NOT NULL DEFAULT 0,
time TIMESTAMP NOT NULL DEFAULT """
+ db.timestamp_now
+ """
);
"""
)