[Debconf-video-commits] r355 - package/branches/pycon09/src/debconfvideo/web/pyconvideo

benh at alioth.debian.org benh at alioth.debian.org
Sat Mar 21 16:17:56 UTC 2009


Author: benh
Date: 2009-03-21 16:17:56 +0000 (Sat, 21 Mar 2009)
New Revision: 355

Modified:
   package/branches/pycon09/src/debconfvideo/web/pyconvideo/models.py
Log:
Make the 'locked_by' columns refer to Django users.
This ought to be in the schema too but that will be applied before Django initialisation...


Modified: package/branches/pycon09/src/debconfvideo/web/pyconvideo/models.py
===================================================================
--- package/branches/pycon09/src/debconfvideo/web/pyconvideo/models.py	2009-03-21 16:05:04 UTC (rev 354)
+++ package/branches/pycon09/src/debconfvideo/web/pyconvideo/models.py	2009-03-21 16:17:56 UTC (rev 355)
@@ -1,5 +1,6 @@
 # Based on auto-generated Django model code.
 
+from django.contrib import auth
 from django.db import models
 import mx.DateTime
 import debconfvideo
@@ -74,7 +75,7 @@
     recording_filename = models.CharField(unique=True, max_length=100)
     file_status = models.ForeignKey(VideoFileStatus)
     comments = models.TextField()
-    locked_by = models.IntegerField()
+    locked_by = models.ForeignKey(auth.models.User, db_column='locked_by', null=True)
     def __unicode__(self):
         return self.recording_filename
     class Meta:
@@ -118,7 +119,7 @@
     target_format = models.ForeignKey(VideoTargetFormat)
     file_status = models.ForeignKey(VideoFileStatus)
     comments = models.TextField()
-    locked_by = models.IntegerField()
+    locked_by = models.ForeignKey(auth.models.User, db_column='locked_by', null=True)
     generated_time = models.DateTimeField()
     published_time = models.DateTimeField()
     def __unicode__(self):




More information about the Debconf-video-commits mailing list