Flask-AppsReusable application classes to streamline creation of application modules, url routes, etc | |
Download |
Flask-Apps Ranking & Summary
Advertisement
- License:
- MIT/X Consortium Lic...
- Price:
- FREE
- Publisher Name:
- Seth Buntin
- Publisher web site:
- http://buntin.org
Flask-Apps Tags
Flask-Apps Description
Reusable application classes to streamline creation of application modules, url routes, etc The Flask-Apps module offers reusable application classes to streamline creation of application modules, URL routes, etc. for use as Flask modules.Installation:Install the extension with one of the following commands:easy_install Flask-Appsor alternatively if you have pip installed:pip install Flask-AppsUsage:Apps are created as subclasses of RestfulApp (currently the only available class). Here’s an example:from flask import Flaskfrom flaskext.apps import RestfulAppapp = Flask(__name__)class ClientApp(RestfulApp): def index(self): # GET "/clients" pass def new(self): # GET "/clients/new" pass def create(self): # POST "/clients" pass def show(self, id=None): # GET "/clients/< id >" pass def edit(self, id=None): # GET "/clients/< id >/edit" pass def update(self, id=None): # POST "/clients/< id >" pass def delete_confirm(self, id=None): # GET "/clients/< id >/delete" pass def delete(self, id=None): # POST "/clients/< id >/delete" passclients = ClientApp("clients")app.register_module(clients.module) Requirements: · Python
Flask-Apps Related Software