Skip to content

Commit

Permalink
client-configs | source/collection generic relation
Browse files Browse the repository at this point in the history
  • Loading branch information
snyaggarwal committed Feb 22, 2021
1 parent b7f5fde commit d349a09
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions core/common/models.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from celery.result import AsyncResult
from django.conf import settings
from django.contrib.contenttypes.fields import GenericRelation
from django.contrib.postgres.fields import JSONField, ArrayField
from django.core.exceptions import ValidationError
from django.core.validators import RegexValidator
Expand Down Expand Up @@ -331,6 +332,9 @@ class ConceptContainerModel(VersionedModel):
copyright = models.TextField(null=True, blank=True)
revision_date = models.DateField(null=True, blank=True)
text = models.TextField(null=True, blank=True) # for about description (markup)
client_configs = GenericRelation(
'client_configs.ClientConfig', object_id_field='resource_id', content_type_field='resource_type'
)

class Meta:
abstract = True
Expand Down

0 comments on commit d349a09

Please sign in to comment.