class Mymodel(Model): # mymodel = related.OneOf('Mymodel') id = fields.CharField(blank=False, null=False, max_length=36, auto_created=True) site = fields.CharField(max_length=40, blank=True, null=True) name = fields.CharField(max_length=40) rootCategories = related.ListOf('Mymodel')
class ListOfCharFields(Model): names = related.ListOf(StringType)
class ToValidateListOfChilds(Model): name = fields.CharField(max_length=300, null=False, blank=False) childs = related.ListOf(ToValidateChild, null=False, min_length=2, max_length=100)
class ToValidateList(Model): language_codes = related.ListOf(types.StringType, choices=LANGUAGECODES)
class Images(Model): urls = related.ListOf(Image, verbose_name='image', null=True, blank=True)
class Organisation(documents.Model): postAddress = related.OneOf(Address, verbose_name ={"nl": "Post adres"}, is_group = True) images = related.ListOf(Image, is_group = True, verbose_name ={"nl": "Afbeeldingen"})
class ShopFacility(Model): values = related.ListOf(types.StringType, choices=TYPE_SHOPPING_FACILITY, null=True, verbose_name={"nl": u"Types"})
class ModelWithListModelWithAllBaseFields(persistentmodels.Model): name = fields.CharField() listOf = related.ListOf(ModelWithAllBaseFields)
class ModelWithListOffStringType(persistentmodels.Model): name = fields.CharField() listOfString = related.ListOf(types.StringType)