Skip to content

Commit c77d384

Browse files
authored
SAML: add flag to allow SAML with old dashboard (#12013)
We have an organization that hasn't migrated to their SAML integration to the new dashboard, adding a flag so we don't wait on them to onboard new organizations to the new dashboard. ref readthedocs/readthedocs-corporate#1954
1 parent 6c57f5a commit c77d384

File tree

2 files changed

+33
-1
lines changed

2 files changed

+33
-1
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Generated by Django 4.2.18 on 2025-02-20 16:26
2+
3+
from django.db import migrations, models
4+
from django_safemigrate import Safe
5+
6+
7+
class Migration(migrations.Migration):
8+
safe = Safe.before_deploy
9+
dependencies = [
10+
("sso", "0002_add_saml_app"),
11+
]
12+
13+
operations = [
14+
migrations.AddField(
15+
model_name="ssointegration",
16+
name="using_old_dashboard",
17+
field=models.BooleanField(
18+
default=False,
19+
null=True,
20+
blank=True,
21+
help_text="Whether the SSO integration is using the old dashboard for authentication. Mainly used for SAML integrations.",
22+
),
23+
),
24+
]

readthedocs/sso/models.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99

1010
class SSOIntegration(models.Model):
11-
1211
"""Single Sign-On integration for an Organization."""
1312

1413
PROVIDER_ALLAUTH = "allauth"
@@ -53,6 +52,15 @@ class SSOIntegration(models.Model):
5352
blank=True,
5453
)
5554

55+
using_old_dashboard = models.BooleanField(
56+
default=False,
57+
null=True,
58+
blank=True,
59+
help_text=(
60+
"Whether the SSO integration is using the old dashboard for authentication. Mainly used for SAML integrations."
61+
),
62+
)
63+
5664
def __str__(self):
5765
return self.name or self.provider
5866

0 commit comments

Comments
 (0)