Skip to content

Commit

Permalink
Exclude gwml2 model from wagtail_reference_index (#134)
Browse files Browse the repository at this point in the history
  • Loading branch information
meomancer authored Jul 25, 2024
1 parent 28abe77 commit 571ba30
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
2 changes: 2 additions & 0 deletions harvesters/models/harvester.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ class Harvester(models.Model):
help_text=_('Default indicator : well can be downloaded.')
)

wagtail_reference_index_ignore = True

class Meta:
db_table = 'harvester'

Expand Down
3 changes: 2 additions & 1 deletion models/metadata/creation.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from django.utils import timezone
from django.contrib.auth import get_user_model
from django.contrib.gis.db import models
from django.utils import timezone
from django.utils.translation import ugettext_lazy as _

User = get_user_model()
Expand All @@ -24,6 +24,7 @@ class CreationMetadata(models.Model):
_('Last edited by'),
null=True, blank=True
)
wagtail_reference_index_ignore = True

class Meta:
abstract = True
Expand Down
4 changes: 3 additions & 1 deletion models/term.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from django.contrib.gis.db import models
from adminsortable.models import Sortable
from django.contrib.gis.db import models


class _Term(Sortable):
Expand All @@ -9,6 +9,8 @@ class _Term(Sortable):
max_length=512, unique=True)
description = models.TextField(null=True, blank=True)

wagtail_reference_index_ignore = True

def __str__(self):
return self.name

Expand Down
2 changes: 2 additions & 0 deletions models/well_management/organisation.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ class Organisation(models.Model):
)
)

wagtail_reference_index_ignore = True

class Meta:
db_table = 'organisation'
ordering = ['name']
Expand Down

0 comments on commit 571ba30

Please sign in to comment.