Commit bb9bd32a authored by Jelle van der Waa's avatar Jelle van der Waa 🚧
Browse files

todolists: Remove unused ModelManager

parent 5d6401ac
from django.contrib.auth.models import User
from django.contrib.sites.models import Site
from django.db import models
from django.db.models import Q
from django.db.models.signals import pre_save
from main.models import Arch, Repo, Package
from main.utils import set_created_field
class TodolistManager(models.Manager):
def incomplete(self):
not_done = ((Q(todolistpackage__status=TodolistPackage.INCOMPLETE) |
Q(todolistpackage__status=TodolistPackage.IN_PROGRESS)) &
return self.order_by().filter(not_done).distinct()
class Todolist(models.Model):
slug = models.SlugField(max_length=255, unique=True)
old_id = models.IntegerField(null=True, unique=True)
......@@ -27,8 +18,6 @@ class Todolist(models.Model):
last_modified = models.DateTimeField(editable=False)
raw = models.TextField(blank=True)
objects = TodolistManager()
class Meta:
get_latest_by = 'created'
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment