From 59b22883948f01152da795bf802aa0d60ec9a12e Mon Sep 17 00:00:00 2001 From: Johan Berggren Date: Mon, 14 May 2012 15:56:57 +0200 Subject: Fix in autodiscover for consumer app. Updated settings for Django 1.4. Some small fixes in consumer.models --- coip/apps/link/models.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'coip/apps/link') diff --git a/coip/apps/link/models.py b/coip/apps/link/models.py index b81215d..6d64dda 100644 --- a/coip/apps/link/models.py +++ b/coip/apps/link/models.py @@ -19,7 +19,7 @@ class Link(models.Model): lastupdated = models.DateTimeField(auto_now=True) class Meta: - unique_together = ('content_type','content_id','url','tag') + unique_together = ('content_type','object_id','url','tag') def __unicode__(self): return "%s:%s (%s) on %s" % (self.tag,self.url,self.text,self.name) @@ -28,4 +28,4 @@ class Link(models.Model): def add_link(o,url,tag,text): typ = ContentType.objects.get_for_model(o) r,cr = Link.objects.get_or_create(object_id=o.id,content_type=typ,url=url,tag=tag) - return r \ No newline at end of file + return r -- cgit v1.1