summaryrefslogtreecommitdiffstats
path: root/src/utils/Routes.js
diff options
context:
space:
mode:
authorARULNA <arul.nambi@amdocs.com>2017-06-02 16:27:25 -0400
committerARULNA <arul.nambi@amdocs.com>2017-06-02 16:33:14 -0400
commitca007e933bcd9f63aa77801656ed9dd4142c432c (patch)
treece97ed9df8c4fe48a524f0dc1365ad28acef7c46 /src/utils/Routes.js
parent42b788b852f0604748828e9e325e4a0f01152c75 (diff)
Initial coomit for AAI-UI(sparky-fe)
Change-Id: I9f8482824a52bac431c100939899e760c0fa4fdb Signed-off-by: ARULNA <arul.nambi@amdocs.com>
Diffstat (limited to 'src/utils/Routes.js')
-rw-r--r--src/utils/Routes.js15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/utils/Routes.js b/src/utils/Routes.js
new file mode 100644
index 0000000..a404dea
--- /dev/null
+++ b/src/utils/Routes.js
@@ -0,0 +1,15 @@
+
+export function changeUrlAddress(pathObj, historyObj) {
+ let toGo = '/' +
+ pathObj.route +
+ '/' +
+ pathObj.hashId;
+ historyObj.push(toGo, {lastRoute: pathObj.route});
+}
+
+export function buildRouteObj(routePath, routeHash) {
+ return {
+ route: routePath,
+ hashId: routeHash
+ };
+}