From: Eevee Date: Fri, 23 Oct 2009 02:31:14 +0000 (-0700) Subject: Merge branch 'comments' X-Git-Url: http://git.veekun.com/zzz-floof.git/commitdiff_plain/7c20a2661d532fe1e338f0f0dfb9fe42113ab103?hp=--cc Merge branch 'comments' --- 7c20a2661d532fe1e338f0f0dfb9fe42113ab103 diff --cc floof/model/art.py index c21c74a,451383b..0732684 --- a/floof/model/art.py +++ b/floof/model/art.py @@@ -20,7 -21,18 +21,8 @@@ class Art(Entity) uploader = ManyToOne('User', required=True) tags = OneToMany('Tag') + discussion = ManyToOne('Discussion') - # def __init__(self, **kwargs): - # # I wanted to check for the existence of the file, but... - # # for some reason this FieldStorage object always conditions as falsey. - # # self.hash = save_file("art", kwargs.pop('file')) - # super(Art, self).__init__(**kwargs) - # # this is what super is doing, pretty much. - # # for key, value in kwargs.items(): - # # setattr(self, key, value) - # left for posterity. - def set_file(self, file): self.hash = save_file("art", file) self.original_filename = file.filename