common/test/data/entities.py
author Katia Saurfelt <katia.saurfelt@logilab.fr>
Thu, 30 Apr 2009 14:43:14 +0200
changeset 1612 0be8605c411a
parent 0 b97547f5f1fa
permissions -rw-r--r--
validation of preferencies done by ajax

from cubicweb.entities import AnyEntity, fetch_config

class Personne(AnyEntity):
    """customized class forne Person entities"""
    id = 'Personne'
    fetch_attrs, fetch_order = fetch_config(['nom', 'prenom'])
    rest_attr = 'nom'


class Societe(AnyEntity):
    id = 'Societe'
    fetch_attrs = ('nom',)
    
class AnotherNote(AnyEntity):
    id = 'AnotherNote'