Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Check if identifier does not contain of all digits. #6572

Merged
Merged
9 changes: 9 additions & 0 deletions manage.py
Expand Up @@ -37,6 +37,15 @@ def add_event_identifier():
save_to_db(event)


@manager.command
def fix_digit_identifier():
events = Event.query.all()
prateekj117 marked this conversation as resolved.
Show resolved Hide resolved
for event in events:
if event.identifier.isdigit():
event.identifier = event.identifier + 'ref'
prateekj117 marked this conversation as resolved.
Show resolved Hide resolved
save_to_db(event)
prateekj117 marked this conversation as resolved.
Show resolved Hide resolved


@manager.option('-n', '--name', dest='name', default='all')
@manager.option('-s', '--switch', dest='switch', default='off')
def module(name, switch):
Expand Down