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

All Samples(6)  |  Call(3)  |  Derive(0)  |  Import(3)
A MongoEngine datastore implementation for Flask-Security that assumes
the use of the Flask-MongoEngine extension.

src/q/u/quokka-0.2.0/quokka/ext/__init__.py   quokka(Download)
# coding: utf-8
from flask.ext.mail import Mail
from flask.ext.cache import Cache
from flask.ext.security import Security as _Security
from flask.ext.security import MongoEngineUserDatastore
    template_filters.configure(app)
 
    user_datastore = MongoEngineUserDatastore(db, User, Role)
    Security(app, user_datastore)
 

src/f/l/Flask-Security-1.7.1/tests/test_app/mongoengine.py   Flask-Security(Download)
 
from flask.ext.mongoengine import MongoEngine
from flask.ext.security import Security, UserMixin, RoleMixin, \
     MongoEngineUserDatastore
 
        populate_data(app.config.get('USER_COUNT', None))
 
    app.security = Security(app, datastore=MongoEngineUserDatastore(db, User, Role), **kwargs)
 
    add_context_processors(app.security)

src/f/l/flask-social-HEAD/tests/test_app/mongoengine.py   flask-social(Download)
 
from flask.ext.mongoengine import MongoEngine
from flask.ext.security import Security, UserMixin, RoleMixin, \
     MongoEngineUserDatastore
from flask.ext.social import Social, MongoEngineConnectionDatastore
            return User.objects(id=self.user_id).first()
 
    app.security = Security(app, MongoEngineUserDatastore(db, User, Role))
    app.social = Social(app, MongoEngineConnectionDatastore(db, Connection))