Super-simple comment display.
[zzz-floof.git] / floof / model / comments.py
diff --git a/floof/model/comments.py b/floof/model/comments.py
new file mode 100644 (file)
index 0000000..f46b37d
--- /dev/null
@@ -0,0 +1,11 @@
+from elixir import *
+
+class Discussion(Entity):
+    """Represents a collection of comments attached to some other object."""
+    count = Field(Integer)
+    comments = OneToMany('Comment')
+
+class Comment(Entity):
+    discussion = ManyToOne('Discussion')
+    text = Field(Unicode(65536))
+