From 98b44bd19ff6bfdd5be0a8c57acbec17c02d80fc Mon Sep 17 00:00:00 2001 From: Bin Sun Date: Mon, 26 Mar 2018 15:48:48 +0800 Subject: Fix the data format of GET Change-Id: I676064d128436149d1efb22c4af1e288272374cd Issue-ID: MULTICLOUD-152 Signed-off-by: Bin Sun --- vio/vio/api_v2/api_router/controller_builder.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/vio/vio/api_v2/api_router/controller_builder.py b/vio/vio/api_v2/api_router/controller_builder.py index 4e6d39d..9c01301 100644 --- a/vio/vio/api_v2/api_router/controller_builder.py +++ b/vio/vio/api_v2/api_router/controller_builder.py @@ -141,10 +141,11 @@ def _build_api_controller(api_meta): resp = session.get(full_url, endpoint_filter=service) mc_res = _convert_vim_res_to_mc_res(resp.json(), resource_properties) - return {"vimName": vim_id, - name: mc_res, - "tenantId": tenant_id, - "vimid": vim_id} + mc_res.update({"vimName": vim_id, + "vimId": vim_id, + "tenantId": tenant_id, + "returnCode": 0}) + return mc_res controller_meta["get"] = _get -- cgit 1.2.3-korg