Skip to content

Commit

Permalink
Add upgrade step for column renaming tickets.group
Browse files Browse the repository at this point in the history
  • Loading branch information
Tschuppi81 committed Jul 21, 2023
1 parent 5ab1328 commit 44de655
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/onegov/search/upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,11 @@
from onegov.core.upgrade import upgrade_task


@upgrade_task('Rename tickets group column')
def rename_tickets_group_column(context):
if context.has_column('tickets', 'group'):
context.operations.alter_column(
table_name='tickets',
column_name='group',
new_column_name='group_title'
)

0 comments on commit 44de655

Please sign in to comment.