mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-05-17 18:09:25 +02:00
Remove db_index, add meta index
This commit is contained in:
parent
aa9ec2d716
commit
24a18f1562
7 changed files with 31 additions and 13 deletions
|
@ -24,6 +24,15 @@ logger = logging.getLogger(__name__)
|
|||
class DomainRequest(TimeStampedModel):
|
||||
"""A registrant's domain request for a new domain."""
|
||||
|
||||
class Meta:
|
||||
"""Contains meta information about this class"""
|
||||
indexes = [
|
||||
models.Index(fields=["requested_domain"]),
|
||||
models.Index(fields=["approved_domain"]),
|
||||
models.Index(fields=["status"]),
|
||||
models.Index(fields=["generic_org_type"]),
|
||||
]
|
||||
|
||||
# https://django-auditlog.readthedocs.io/en/latest/usage.html#object-history
|
||||
# If we note any performace degradation due to this addition,
|
||||
# we can query the auditlogs table in admin.py and add the results to
|
||||
|
@ -537,7 +546,6 @@ class DomainRequest(TimeStampedModel):
|
|||
organization_name = models.CharField(
|
||||
null=True,
|
||||
blank=True,
|
||||
db_index=True,
|
||||
)
|
||||
|
||||
address_line1 = models.CharField(
|
||||
|
@ -566,7 +574,6 @@ class DomainRequest(TimeStampedModel):
|
|||
null=True,
|
||||
blank=True,
|
||||
verbose_name="zip code",
|
||||
db_index=True,
|
||||
)
|
||||
urbanization = models.CharField(
|
||||
null=True,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue