Add search fields to views

Make receptoraddress list views
searchable by "address"

Other changes:
- Add help text to source and target of the
InstanceLink model

Signed-off-by: Seth Foster <fosterbseth@gmail.com>
This commit is contained in:
Seth Foster
2023-11-16 00:50:38 -05:00
committed by Seth Foster
parent 04cbbbccfa
commit ab0e9265c5
4 changed files with 15 additions and 15 deletions

View File

@@ -70,8 +70,8 @@ class InstanceLink(BaseModel):
ordering = ("id",)
constraints = [models.UniqueConstraint(fields=['source', 'target'], name='source_target_unique_together')]
source = models.ForeignKey('Instance', on_delete=models.CASCADE)
target = models.ForeignKey('ReceptorAddress', on_delete=models.CASCADE)
source = models.ForeignKey('Instance', on_delete=models.CASCADE, help_text=_("The source instance of this peer link."))
target = models.ForeignKey('ReceptorAddress', on_delete=models.CASCADE, help_text=_("The target receptor address of this peer link."))
class States(models.TextChoices):
ADDING = 'adding', _('Adding')