This commit is contained in:
+12
@@ -88,4 +88,16 @@ def migrate():
|
||||
stattdessen hier beim App-Start nachgerüstet."""
|
||||
with get_cursor() as cur:
|
||||
cur.execute('ALTER TABLE "Auftraege" ADD COLUMN IF NOT EXISTS "artikel" text')
|
||||
# Tablets: Geräte-Kennung (Cookie) -> zugeordnete Zielseite
|
||||
cur.execute(
|
||||
'CREATE TABLE IF NOT EXISTS "Tablets" ('
|
||||
'"id" serial PRIMARY KEY, '
|
||||
'"kennung" text NOT NULL UNIQUE, '
|
||||
'"name" text, '
|
||||
'"ziel_typ" text, '
|
||||
'"maschine_id" integer, '
|
||||
'"erstellt_am" bigint, '
|
||||
'"zuletzt_gesehen" bigint)'
|
||||
)
|
||||
cur.execute('CREATE TABLE IF NOT EXISTS "Einstellungen" ("schluessel" text PRIMARY KEY, "wert" text)')
|
||||
log.info("Schema-Migration geprüft/angewendet.")
|
||||
|
||||
Reference in New Issue
Block a user