diff options
author | Cédric Bonhomme <cedric@cedricbonhomme.org> | 2016-04-14 00:02:47 +0200 |
---|---|---|
committer | Cédric Bonhomme <cedric@cedricbonhomme.org> | 2016-04-14 00:02:47 +0200 |
commit | b4b175e0a8bb3844c1c6f846c1b4eb1970520864 (patch) | |
tree | 1cc59a636e2c4dffdb86bc2daaeee6f14a28eefa /src/web/views/api/category.py | |
parent | updated some JS dependencies. (diff) | |
download | newspipe-b4b175e0a8bb3844c1c6f846c1b4eb1970520864.tar.gz newspipe-b4b175e0a8bb3844c1c6f846c1b4eb1970520864.tar.bz2 newspipe-b4b175e0a8bb3844c1c6f846c1b4eb1970520864.zip |
testing a new API
Diffstat (limited to 'src/web/views/api/category.py')
-rw-r--r-- | src/web/views/api/category.py | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/src/web/views/api/category.py b/src/web/views/api/category.py deleted file mode 100644 index eecfa785..00000000 --- a/src/web/views/api/category.py +++ /dev/null @@ -1,27 +0,0 @@ -from conf import API_ROOT -from flask import current_app -from flask.ext.restful import Api - -from web.controllers.category import CategoryController -from web.views.api.common import (PyAggResourceNew, - PyAggResourceExisting, - PyAggResourceMulti) - - -class CategoryNewAPI(PyAggResourceNew): - controller_cls = CategoryController - - -class CategoryAPI(PyAggResourceExisting): - controller_cls = CategoryController - - -class CategoriesAPI(PyAggResourceMulti): - controller_cls = CategoryController - - -api = Api(current_app, prefix=API_ROOT) -api.add_resource(CategoryNewAPI, '/category', endpoint='category_new.json') -api.add_resource(CategoryAPI, '/category/<int:obj_id>', - endpoint='category.json') -api.add_resource(CategoriesAPI, '/categories', endpoint='categories.json') |