class Logotype(models.Model):
brand = models.ForeignKey('Brand', on_delete=models.PROTECT)
logo = models.TextField(null=True, unique=True)
hasSvg = models.BooleanField(default=False)
views = models.IntegerField(null=True)
date = models.DateField(default=datetime.now())
is_active = models.BooleanField(default=True)
class Brand(models.Model):
brand = models.TextField(unique=True)
obj = Brand.objects.filter(
brand__icontains=query, "как получить только те у которых is_active=True")