aboutsummaryrefslogtreecommitdiffstats
path: root/api/database/v2
diff options
context:
space:
mode:
authorRex Lee <limingjiang@huawei.com>2017-07-21 01:03:42 +0000
committerGerrit Code Review <gerrit@opnfv.org>2017-07-21 01:03:42 +0000
commitbc750fbee81d0b3a9edbd16c88c02e785f87dd7f (patch)
treed4f72614bdd5025758333ecd01ffa8e1ddb2b5d6 /api/database/v2
parent53825a386d6b7edd47754db41113bedfacc34432 (diff)
parent6bc4d2c813460cba201c390cc2380fb99bdc2c9d (diff)
Merge changes from topics 'get_project', 'get_projects'
* changes: Add API(V2) to get certain project info Add API(v2) to get all projects info
Diffstat (limited to 'api/database/v2')
-rw-r--r--api/database/v2/handlers.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/api/database/v2/handlers.py b/api/database/v2/handlers.py
index 3474af2c1..44c14df61 100644
--- a/api/database/v2/handlers.py
+++ b/api/database/v2/handlers.py
@@ -136,6 +136,9 @@ class V2ContainerHandler(object):
class V2ProjectHandler(object):
+ def list_all(self):
+ return V2Project.query.all()
+
def insert(self, kwargs):
project = V2Project(**kwargs)
db_session.add(project)