Extend backup verification to include Vision 2026 tables

Add DokumentDatei, EmailEingang, Verwaltungskosten, and
GeschichteSeite to post-restore verification table checks.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
SysAdmin Agent
2026-03-12 12:04:35 +00:00
parent 7a9dc533c3
commit 7e42b50d5b

View File

@@ -389,7 +389,11 @@ def restore_database(db_backup_file):
from django.db import connection from django.db import connection
with connection.cursor() as cursor: with connection.cursor() as cursor:
# Check some key tables # Check some key tables
test_tables = ['stiftung_person', 'stiftung_land', 'stiftung_destinataer'] test_tables = [
'stiftung_person', 'stiftung_land', 'stiftung_destinataer',
'stiftung_dokumentdatei', 'stiftung_emaileingang',
'stiftung_verwaltungskosten', 'stiftung_geschichteseite',
]
for table in test_tables: for table in test_tables:
try: try:
cursor.execute(f"SELECT COUNT(*) FROM {table}") cursor.execute(f"SELECT COUNT(*) FROM {table}")