Skip to content

Commit

Permalink
Remove db_table from many_to_many relationships
Browse files Browse the repository at this point in the history
  • Loading branch information
aloftus23 committed Nov 20, 2024
1 parent 3e821a7 commit 3ed79be
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions backend/src/xfd_django/xfd_api/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,7 @@ class Cve(models.Model):

cpes = models.ManyToManyField(
"Cpe",
related_name="cves",
db_table="cve_cpes_cpe",
related_name="cves"
)

class Meta:
Expand Down Expand Up @@ -291,8 +290,7 @@ class OrganizationTag(models.Model):
name = models.CharField(max_length=255, unique=True)
organizations = models.ManyToManyField(
"Organization",
related_name="tags",
db_table="organization_tag_organizations_organization",
related_name="tags"
)

class Meta:
Expand Down Expand Up @@ -419,8 +417,7 @@ class Scan(models.Model):
)
organizations = models.ManyToManyField(
"Organization",
related_name="granularScans",
db_table="scan_organizations_organization",
related_name="granularScans"
)

class Meta:
Expand Down Expand Up @@ -452,7 +449,6 @@ class ScanTask(models.Model):
organizations = models.ManyToManyField(
"Organization",
related_name="allScanTasks",
db_table="scan_task_organizations_organization",
)

class Meta:
Expand Down

0 comments on commit 3ed79be

Please sign in to comment.