From a8c9d158aa445abea41ffdfbb598172f89d96b0f Mon Sep 17 00:00:00 2001 From: gitadmin Date: Sun, 12 Oct 2025 17:53:07 +0300 Subject: [PATCH] =?UTF-8?q?=D0=B4=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=D0=B8=D0=B5=20=D0=BF=D0=BE=D0=BB=D1=8F=20auto=5Funit?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ensure_db.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ensure_db.py b/ensure_db.py index fcd9d6a..94eed26 100644 --- a/ensure_db.py +++ b/ensure_db.py @@ -83,7 +83,8 @@ def ensure_database_structure(): tg_poll_results TEXT DEFAULT '', is_event BOOLEAN DEFAULT 0, shortname VARCHAR(100), - action_number BIGINT NULL + action_number BIGINT NULL, + auto_unit VARCHAR(255) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ''', 'marks': ''' @@ -178,6 +179,9 @@ def ensure_database_structure(): # Проверка и добавление новых полей в существующие таблицы table_alterations = { + 'posts': [ + {'column': 'auto_unit', 'type': 'VARCHAR(255)'} + ], 'marks': [ {'column': 'autolink', 'type': 'BOOLEAN DEFAULT 0'}, {'column': 'reminded_at', 'type': 'DATETIME NULL'}