equal
deleted
inserted
replaced
5 |
5 |
6 |
6 |
7 mutable = True |
7 mutable = True |
8 |
8 |
9 class Element(models.Model): |
9 class Element(models.Model): |
10 chapter_name = models.CharField('Chapter name', max_length=100, editable=False, |
10 paragraph_id = models.CharField('Paragraph Id', max_length=100, editable=False, primary_key=True) |
11 db_index=True) |
11 chapter_name = models.CharField('Chapter name', max_length=100, editable=False,db_index=True) |
12 |
12 |
13 |
13 |
14 def __unicode__(self): |
14 def __unicode__(self): |
15 return self.chapter_name |
15 return self.paragraph_id |
16 |
16 |
17 class Comment(models.Model): |
17 class Comment(models.Model): |
18 element = models.ForeignKey(Element, |
18 element = models.ForeignKey(Element, |
19 help_text='ID of paragraph that was commented on') |
19 help_text='ID of paragraph that was commented on') |
20 comment = models.TextField(editable=mutable, |
20 comment = models.TextField(editable=mutable, |