Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(41)  |  Call(0)  |  Derive(41)  |  Import(0)

src/f/l/flask-admin-HEAD/examples/mongoengine/simple.py   flask-admin(Download)
class User(db.Document):
    name = db.StringField(max_length=40)
    tags = db.ListField(db.ReferenceField('Tag'))
    password = db.StringField(max_length=40)
 
    def __unicode__(self):
        return self.name
 
 
class Todo(db.Document):
class Tag(db.Document):
    name = db.StringField(max_length=10)
 
    def __unicode__(self):
        return self.name
class Post(db.Document):
    name = db.StringField(max_length=20, required=True)
    value = db.StringField(max_length=20)
    inner = db.ListField(db.EmbeddedDocumentField(Comment))
    lols = db.ListField(db.StringField(max_length=20))
 
 
class File(db.Document):

src/f/l/flask-mongorest-HEAD/example/app.py   flask-mongorest(Download)
class User(db.Document):
    email = db.EmailField(unique=True, required=True)
    first_name = db.StringField(max_length=50)
    last_name = db.StringField(max_length=50)
    emails = db.ListField(db.EmailField())
class Post(db.Document):
    title = db.StringField(max_length=120, required=True)
    description = db.StringField(max_length=120, required=False)
    author = db.ReferenceField(User)
    editor = db.ReferenceField(User)
class TestDocument(db.Document):
    name = db.StringField()
    other = db.StringField()
    dictfield = db.DictField()
    is_new = db.BooleanField()
class A(db.Document):
    txt = db.StringField()
 
class B(db.Document):
    ref = db.ReferenceField(A, dbref=True)

src/f/l/flask-mongoengine-HEAD/examples/simpleapp/app.py   flask-mongoengine(Download)
class Todo(db.Document):
    title = db.StringField(max_length=60)
    text = db.StringField()
    done = db.BooleanField(default=False)
    pub_date = db.DateTimeField(default=datetime.datetime.now)

src/f/l/flask-mongoengine-HEAD/examples/biggerapp/models.py   flask-mongoengine(Download)
class Todo(db.Document):
    title = db.StringField(max_length=60)
    text = db.StringField()
    done = db.BooleanField(default=False)
    pub_date = db.DateTimeField(default=datetime.datetime.now)

src/f/l/flask-admin-HEAD/examples/auth-mongoengine/auth.py   flask-admin(Download)
class User(db.Document):
    login = db.StringField(max_length=80, unique=True)
    email = db.StringField(max_length=120)
    password = db.StringField(max_length=64)
 

src/c/o/comimoc-1.0.0/comimoc/admin/models.py   comimoc(Download)
class User(db.Document, UserMixin):
    """
    User document for admin purpose only
    """
    login       = db.StringField(required=True, min_length=4, unique=True)

src/c/o/comimoc-1.0.0/comimoc/models.py   comimoc(Download)
class Comment(db.Document):
    """
    A Comment is just a single comment on a page for a website
    """
    website         = db.StringField(required=True)

src/p/y/PythonORMSleepy-HEAD/sleepy/api_mongoengine.py   PythonORMSleepy(Download)
class Item(db.Document):
    name = mdb.StringField(max_length=100, required=True)
    checked_out = mdb.BooleanField(default=False)
    updated = mdb.DateTimeField(default=datetime.utcnow)
 
    def __repr__(self):
        return '<Item {0!r}>'.format(self.name)
 
 
class Person(db.Document):

src/f/l/flask-social-HEAD/tests/test_app/mongoengine.py   flask-social(Download)
    class Role(db.Document, RoleMixin):
        name = db.StringField(required=True, unique=True, max_length=80)
        description = db.StringField(max_length=255)
 
    class User(db.Document, UserMixin):
    class Connection(db.Document):
        user_id = db.ObjectIdField()
        provider_id = db.StringField(max_length=255)
        provider_user_id = db.StringField(max_length=255)
        access_token = db.StringField(max_length=255)

src/f/l/flask-mongoengine-HEAD/tests/test_basic_app.py   flask-mongoengine(Download)
        class Todo(db.Document):
            title = db.StringField(max_length=60)
            text = db.StringField()
            done = db.BooleanField(default=False)
            pub_date = db.DateTimeField(default=datetime.datetime.now)

  1 | 2  Next