diff options
Diffstat (limited to 'testapi/opnfv_testapi/handlers/base_handlers.py')
-rw-r--r-- | testapi/opnfv_testapi/handlers/base_handlers.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/testapi/opnfv_testapi/handlers/base_handlers.py b/testapi/opnfv_testapi/handlers/base_handlers.py index 9eac737..3dbd53a 100644 --- a/testapi/opnfv_testapi/handlers/base_handlers.py +++ b/testapi/opnfv_testapi/handlers/base_handlers.py @@ -79,8 +79,8 @@ class GenericApiHandler(web.RequestHandler): @check.valid_token @check.no_body @check.miss_fields - @check.new_not_exists @check.is_authorized + @check.new_not_exists @check.values_check @check.carriers_exist def _create(self, **kwargs): @@ -179,6 +179,7 @@ class GenericApiHandler(web.RequestHandler): @gen.coroutine @check.not_exist @check.is_authorized + @check.is_reource_tied def _delete(self, data, query=None): yield dbapi.db_delete(self.table, query) self.finish_request() @@ -189,6 +190,7 @@ class GenericApiHandler(web.RequestHandler): @check.not_exist @check.updated_one_not_exist @check.is_authorized + @check.is_reource_tied def _update(self, data, query=None, **kwargs): data = self.table_cls.from_dict(data) update_req = self._update_requests(data) @@ -200,6 +202,7 @@ class GenericApiHandler(web.RequestHandler): @gen.coroutine @check.no_body @check.not_exist + @check.is_authorized @check.updated_one_not_exist def pure_update(self, data, query=None, **kwargs): data = self.table_cls.from_dict(data) |