Fixes #4912: Fix image attachment API endpoint; add API view tests

This commit is contained in:
Jeremy Stretch
2020-07-27 14:24:15 -04:00
parent b17e47101c
commit a206b422fb
4 changed files with 57 additions and 1 deletions

View File

@@ -387,6 +387,8 @@ class ImageAttachment(models.Model):
auto_now_add=True
)
objects = RestrictedQuerySet.as_manager()
class Meta:
ordering = ('name', 'pk') # name may be non-unique