fix(migrations): rebase audit_logs migration onto main's 027_ensure_shared_links_table

- Add 027_ensure_shared_links_table.py from main branch
- Renumber 027_add_audit_logs → 028_add_audit_logs
- Update down_revision to chain from 027_ensure_shared_links_table
- Restore all model imports in migrations/env.py (were dropped in previous PR)
- Restore shared_links in db_migrate.py _TABLE_ORDER

Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-03-10 21:34:15 +00:00
parent 653c137222
commit 6e2e4a830f
4 changed files with 82 additions and 4 deletions
+15
View File
@@ -20,14 +20,29 @@ from app.database import Base
# Ensure all models are imported so Base.metadata is populated.
from app.models import ( # noqa: F401
ApiToken,
ApplicationSettings,
AuditLog,
BackupRecord,
DocumentMetadata,
FileProcessingStep,
FileRecord,
InAppNotification,
LocalUser,
Pipeline,
PipelineStep,
ProcessingLog,
SavedSearch,
ScheduledJob,
SettingsAuditLog,
SharedLink,
SubscriptionPlan,
UserImapAccount,
UserIntegration,
UserNotificationPreference,
UserNotificationTarget,
UserProfile,
WebhookConfig,
)
# Alembic Config object provides access to values in alembic.ini.