Manual order: you can now change the order by dragging and dropping

This commit is contained in:
Mahmoud
2023-12-25 19:44:23 +01:00
parent 45c14f6a12
commit 42839a5886
4 changed files with 157 additions and 121 deletions

View File

@@ -934,6 +934,8 @@ class RecipeBook(ExportModelOperationsMixin('book'), models.Model, PermissionMod
shared = models.ManyToManyField(User, blank=True, related_name='shared_with')
created_by = models.ForeignKey(User, on_delete=models.CASCADE)
filter = models.ForeignKey('cookbook.CustomFilter', null=True, blank=True, on_delete=models.SET_NULL)
order = models.IntegerField(default=0)
space = models.ForeignKey(Space, on_delete=models.CASCADE)
objects = ScopedManager(space='space')