fix: restore tubco user onboarding access
This commit is contained in:
@@ -0,0 +1,62 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('workflows', '0058_alter_formsectionconfig_options_and_more'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.SeparateDatabaseAndState(
|
||||
database_operations=[
|
||||
migrations.RunSQL(
|
||||
sql=(
|
||||
"ALTER TABLE workflows_userprofile "
|
||||
"ADD COLUMN IF NOT EXISTS temporary_role_key varchar(64) NOT NULL DEFAULT '';"
|
||||
),
|
||||
reverse_sql=(
|
||||
"ALTER TABLE workflows_userprofile "
|
||||
"DROP COLUMN IF EXISTS temporary_role_key;"
|
||||
),
|
||||
),
|
||||
migrations.RunSQL(
|
||||
sql=(
|
||||
"ALTER TABLE workflows_userprofile "
|
||||
"ADD COLUMN IF NOT EXISTS temporary_role_expires_at timestamptz NULL;"
|
||||
),
|
||||
reverse_sql=(
|
||||
"ALTER TABLE workflows_userprofile "
|
||||
"DROP COLUMN IF EXISTS temporary_role_expires_at;"
|
||||
),
|
||||
),
|
||||
migrations.RunSQL(
|
||||
sql=(
|
||||
"ALTER TABLE workflows_userprofile "
|
||||
"ADD COLUMN IF NOT EXISTS temporary_role_reason text NOT NULL DEFAULT '';"
|
||||
),
|
||||
reverse_sql=(
|
||||
"ALTER TABLE workflows_userprofile "
|
||||
"DROP COLUMN IF EXISTS temporary_role_reason;"
|
||||
),
|
||||
),
|
||||
],
|
||||
state_operations=[
|
||||
migrations.AddField(
|
||||
model_name='userprofile',
|
||||
name='temporary_role_key',
|
||||
field=models.CharField(blank=True, default='', max_length=64),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='userprofile',
|
||||
name='temporary_role_expires_at',
|
||||
field=models.DateTimeField(blank=True, null=True),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='userprofile',
|
||||
name='temporary_role_reason',
|
||||
field=models.TextField(blank=True, default=''),
|
||||
),
|
||||
],
|
||||
),
|
||||
]
|
||||
Reference in New Issue
Block a user