mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-07-26 12:38:36 +02:00
Fix migrations and issue
This commit is contained in:
parent
83ac30f3e5
commit
f36ac30945
3 changed files with 4 additions and 3 deletions
|
@ -139,7 +139,8 @@ class DomainRequestFixture:
|
||||||
da.federal_agency, _ = FederalAgency.objects.get_or_create(name=app["federal_agency"])
|
da.federal_agency, _ = FederalAgency.objects.get_or_create(name=app["federal_agency"])
|
||||||
else:
|
else:
|
||||||
federal_agencies = FederalAgency.objects.all()
|
federal_agencies = FederalAgency.objects.all()
|
||||||
da.federal_agency = random.choice(federal_agencies)
|
# Random choice of agency for selects, used as placeholders for testing.
|
||||||
|
da.federal_agency = random.choice(federal_agencies) # nosec
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def _set_many_to_many_relations(cls, da: DomainRequest, app: dict):
|
def _set_many_to_many_relations(cls, da: DomainRequest, app: dict):
|
||||||
|
|
|
@ -18,4 +18,4 @@ class Migration(migrations.Migration):
|
||||||
model_name="domainrequest",
|
model_name="domainrequest",
|
||||||
name="federal_agency",
|
name="federal_agency",
|
||||||
),
|
),
|
||||||
]
|
]
|
||||||
|
|
|
@ -20,4 +20,4 @@ class Migration(migrations.Migration):
|
||||||
old_name="updated_federal_agency",
|
old_name="updated_federal_agency",
|
||||||
new_name="federal_agency",
|
new_name="federal_agency",
|
||||||
),
|
),
|
||||||
]
|
]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue