Auto-commit local changes before build (2026-01-15 10:21:30)
This commit is contained in:
parent
f6310da575
commit
d5fdc9a8d9
@ -1 +1 @@
|
|||||||
v20260115-01-autotask-settings
|
v20260115-02-autotask-settings-migration-fix
|
||||||
|
|||||||
@ -22,6 +22,27 @@ def _is_column_nullable(table_name: str, column_name: str) -> bool:
|
|||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
||||||
|
def _column_exists_on_conn(conn, table_name: str, column_name: str) -> bool:
|
||||||
|
"""Return True if the given column exists using the provided connection.
|
||||||
|
|
||||||
|
This helper is useful inside engine.begin() blocks so we can check
|
||||||
|
column existence without creating a new inspector/connection.
|
||||||
|
"""
|
||||||
|
result = conn.execute(
|
||||||
|
text(
|
||||||
|
"""
|
||||||
|
SELECT 1
|
||||||
|
FROM information_schema.columns
|
||||||
|
WHERE table_name = :table
|
||||||
|
AND column_name = :column
|
||||||
|
LIMIT 1
|
||||||
|
"""
|
||||||
|
),
|
||||||
|
{"table": table_name, "column": column_name},
|
||||||
|
)
|
||||||
|
return result.first() is not None
|
||||||
|
|
||||||
|
|
||||||
def migrate_add_username_to_users() -> None:
|
def migrate_add_username_to_users() -> None:
|
||||||
"""Ensure users.username column exists and is NOT NULL and UNIQUE.
|
"""Ensure users.username column exists and is NOT NULL and UNIQUE.
|
||||||
|
|
||||||
@ -820,6 +841,7 @@ def run_migrations() -> None:
|
|||||||
migrate_system_settings_auto_import_cutoff_date()
|
migrate_system_settings_auto_import_cutoff_date()
|
||||||
migrate_system_settings_daily_jobs_start_date()
|
migrate_system_settings_daily_jobs_start_date()
|
||||||
migrate_system_settings_ui_timezone()
|
migrate_system_settings_ui_timezone()
|
||||||
|
migrate_system_settings_autotask_integration()
|
||||||
migrate_mail_messages_columns()
|
migrate_mail_messages_columns()
|
||||||
migrate_mail_messages_parse_columns()
|
migrate_mail_messages_parse_columns()
|
||||||
migrate_mail_messages_approval_columns()
|
migrate_mail_messages_approval_columns()
|
||||||
|
|||||||
@ -1,3 +1,22 @@
|
|||||||
|
## v20260115-01-autotask-settings
|
||||||
|
|
||||||
|
Changes:
|
||||||
|
- Added initial Autotask integration settings structure to Backupchecks.
|
||||||
|
- Introduced new system settings demonstrating Autotask configuration fields such as enable toggle, environment selection, credentials, tracking identifier, and Backupchecks base URL.
|
||||||
|
- Prepared data model and persistence layer to store Autotask-related configuration.
|
||||||
|
- Laid groundwork for future validation and integration logic without enabling ticket creation or customer mapping.
|
||||||
|
- Ensured changes are limited to configuration foundations only, keeping Phase 1 scope intact.
|
||||||
|
|
||||||
|
##
|
||||||
|
|
||||||
|
v20260115-02-autotask-settings-migration-fix
|
||||||
|
|
||||||
|
Changes:
|
||||||
|
- Fixed Autotask system settings migration so it is always executed during application startup.
|
||||||
|
- Added safe, idempotent column existence checks to prevent startup failures on re-deployments.
|
||||||
|
- Ensured all Autotask-related system_settings columns are created before being queried.
|
||||||
|
- Prevented aborted database transactions caused by missing columns during settings initialization.
|
||||||
|
- Improved overall stability of the Settings page when Autotask integration is enabled.
|
||||||
|
|
||||||
***
|
***
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user