Exemplo n.º 1
0
class NewBaseClass(models.Model):
    name = models.TextField(default='aaaaa')
    active = models.BooleanField(column_name='is_active', default=False)
    list_f = models.ListField(default=[], column_name='lista')
    map_f = models.MapField(default={}, column_name='mapa')

    class Meta:
        abstract = True
        collection_name = 'collection_name'
Exemplo n.º 2
0
class Class(models.Model):
    name = models.TextField()
    active = models.BooleanField(column_name='is_active')
    list_f = models.ListField(blank=True)
    map_f = models.MapField(blank=True)
Exemplo n.º 3
0
class Class2(BaseClass):
    map_f = models.MapField(blank=True, column_name='mapa')