summaryrefslogtreecommitdiffstats
path: root/usecaseui-portal
diff options
context:
space:
mode:
authorcyuamber <xuranyjy@chinamobile.com>2019-09-12 14:45:19 +0800
committercyuamber <xuranyjy@chinamobile.com>2019-09-12 14:45:32 +0800
commitffd6d1e39c36a2133d329b975d5fe588bba36d35 (patch)
tree8133d2aa3161fed15e1f137120255b498d4aef48 /usecaseui-portal
parent8fc83809ff5d970b7ecda3e24e4038faa03d950b (diff)
feat: optimize the local API and json data on the onboard page
Change-Id: I7dc02560d381161ce5687e850ce2cf882c579b75 Issue-ID: USECASEUI-307 Signed-off-by: cyuamber <xuranyjy@chinamobile.com>
Diffstat (limited to 'usecaseui-portal')
-rw-r--r--usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deleteNsdPackage.json (renamed from usecaseui-portal/src/app/mock/json/uui-lcm_deleteNsdPackage.json)0
-rw-r--r--usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deletePnfPackage.json (renamed from usecaseui-portal/src/app/mock/json/uui-lcm_deletePnfPackage.json)0
-rw-r--r--usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deleteVnfPackage.json (renamed from usecaseui-portal/src/app/mock/json/uui-lcm_deleteVnfPackage.json)0
-rw-r--r--usecaseui-portal/src/app/mock/routes.js3
-rw-r--r--usecaseui-portal/src/app/mock/server.js4
5 files changed, 6 insertions, 1 deletions
diff --git a/usecaseui-portal/src/app/mock/json/uui-lcm_deleteNsdPackage.json b/usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deleteNsdPackage.json
index 41c06ec5..41c06ec5 100644
--- a/usecaseui-portal/src/app/mock/json/uui-lcm_deleteNsdPackage.json
+++ b/usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deleteNsdPackage.json
diff --git a/usecaseui-portal/src/app/mock/json/uui-lcm_deletePnfPackage.json b/usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deletePnfPackage.json
index 41c06ec5..41c06ec5 100644
--- a/usecaseui-portal/src/app/mock/json/uui-lcm_deletePnfPackage.json
+++ b/usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deletePnfPackage.json
diff --git a/usecaseui-portal/src/app/mock/json/uui-lcm_deleteVnfPackage.json b/usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deleteVnfPackage.json
index 41c06ec5..41c06ec5 100644
--- a/usecaseui-portal/src/app/mock/json/uui-lcm_deleteVnfPackage.json
+++ b/usecaseui-portal/src/app/mock/json/DELETE_uui-lcm_deleteVnfPackage.json
diff --git a/usecaseui-portal/src/app/mock/routes.js b/usecaseui-portal/src/app/mock/routes.js
index 07bbe3c8..29d7c008 100644
--- a/usecaseui-portal/src/app/mock/routes.js
+++ b/usecaseui-portal/src/app/mock/routes.js
@@ -68,6 +68,9 @@ module.exports =
"/vnfpkgm/v1/vnf_packages/:vnfPkgId/package_content": "/nsd_content",
"/nsd/v1/pnf_descriptors/:pnfdInfoId/pnfd_content": "/nsd_content",
"/uui-lcm/jobs/:_jobId": "/uui-lcm_jobs_progress",
+ "/DELETE/uui-lcm/deleteNsdPackage?nsdInfoId:id": "/DELETE_uui-lcm_deleteNsdPackage",
+        "/DELETE/uui-lcm/deleteVnfPackage?vnfPkgId:id": "/DELETE_uui-lcm_deleteVnfPackage",
+        "/DELETE/uui-lcm/deletePnfPackage?pnfdInfoId:id": "/DELETE_uui-lcm_deletePnfPackage",
/////////////////////////
diff --git a/usecaseui-portal/src/app/mock/server.js b/usecaseui-portal/src/app/mock/server.js
index b603523f..eef7df16 100644
--- a/usecaseui-portal/src/app/mock/server.js
+++ b/usecaseui-portal/src/app/mock/server.js
@@ -101,7 +101,9 @@ server.put(`${baseUrl}/*`, (req, res, next) => {
next();
})
server.delete(`${baseUrl}/*`, (req, res, next) => {
- console.log("===delete😑")
+ const prefix = req.url.replace(baseUrl, "");
+ req.url = `${baseUrl}/DELETE${prefix}`;
+ req.method = 'GET';
next();
})