summaryrefslogtreecommitdiffstats
path: root/usecaseui-portal/src/app/mock/server.js
diff options
context:
space:
mode:
Diffstat (limited to 'usecaseui-portal/src/app/mock/server.js')
-rw-r--r--usecaseui-portal/src/app/mock/server.js17
1 files changed, 16 insertions, 1 deletions
diff --git a/usecaseui-portal/src/app/mock/server.js b/usecaseui-portal/src/app/mock/server.js
index 3c49777d..63e6167c 100644
--- a/usecaseui-portal/src/app/mock/server.js
+++ b/usecaseui-portal/src/app/mock/server.js
@@ -20,7 +20,7 @@ const middlewares = jsonServer.defaults();
const customersRouters = require('./routes');
const baseUrl = "/usecaseui-server/v1";
const nsmfBaseUrl = "/uui-slicing/nsmf";
-const csmfBaseUrl = "/usecaseui/csmf";
+const csmfBaseUrl = "/uui-slicing/csmf";
// Set default middlewares (logger, static, cors and no-cache)
server.use(middlewares);
@@ -119,6 +119,21 @@ server.delete(`${nsmfBaseUrl}/*`, (req, res, next) => {
req.url = '/DELETE'+req.url;
next();
})
+server.put(`${csmfBaseUrl}/*`, (req, res, next) => {
+ req.method = 'GET';
+ req.url = '/PUT'+req.url;
+ next();
+})
+server.post(`${csmfBaseUrl}/*`, (req, res, next) => {
+ req.method = 'GET';
+ req.url = '/POST'+req.url;
+ next();
+})
+server.delete(`${csmfBaseUrl}/*`, (req, res, next) => {
+ req.method = 'GET';
+ req.url = '/DELETE'+req.url;
+ next();
+})
server.listen(3002, () => {
console.log('Mock Server is successfully running on port 3002 😁')