| 24 | |
| 25 | class Message(models.Model): |
| 26 | message = models.TextField() |
| 27 | class Meta: |
| 28 | pass |
| 29 | class Admin: |
| 30 | pass |
| 31 | |
| 32 | class C2(models.Model): |
| 33 | message = models.TextField() |
| 34 | class Meta: |
| 35 | pass |
| 36 | class Admin: |
| 37 | pass |
| 38 | |
| 39 | class Translation(models.Model): |
| 40 | message = models.ForeignKey(Message, edit_inline=models.TABULAR) |
| 41 | language = models.CharField(maxlength=10) |
| 42 | translation = models.TextField(core=True) |
| 43 | |
| 44 | class Meta: |
| 45 | unique_together = (('language', 'message',),) |
| 46 | class Admin: |
| 47 | pass |
| 48 | |
| 49 | class Message2(models.Model): |
| 50 | message = models.TextField() |
| 51 | class Meta: |
| 52 | pass |
| 53 | class Admin: |
| 54 | pass |
| 55 | |
| 56 | class Registry(models.Model): |
| 57 | message = models.ForeignKey(Message2, edit_inline=True) |
| 58 | c2 = models.ForeignKey(C2) |
| 59 | obj = models.CharField(maxlength=255, core=True) |
| 60 | field = models.CharField(maxlength=255) |
| 61 | |
| 62 | class Meta: |
| 63 | unique_together = (('c2', 'field', 'obj'),) |
| 64 | class Admin: |
| 65 | pass |
| 66 | |
| 67 | |
| 68 | class Message3(models.Model): |
| 69 | message = models.TextField() |
| 70 | class Meta: |
| 71 | pass |
| 72 | class Admin: |
| 73 | pass |
| 74 | |
| 75 | class Registry2(models.Model): |
| 76 | message = models.ForeignKey(Message2, edit_inline=True) |
| 77 | c2 = models.ForeignKey(C2) |
| 78 | obj = models.CharField(maxlength=255, core=True) |
| 79 | field = models.CharField(maxlength=255) |
| 80 | |
| 81 | class Meta: |
| 82 | unique_together = (('message', 'c2', 'field', 'obj'),) |
| 83 | class Admin: |
| 84 | pass |
| 85 | |