atlas-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kbh...@apache.org
Subject [2/2] incubator-atlas git commit: ATLAS-1287 Subtasks: ATLAS-1288/ATLAS-1289 Integrated V2 API for Lineage, Entity Details, Tag assign to entity, Tags listing, tag create
Date Wed, 14 Dec 2016 05:40:29 GMT
ATLAS-1287 Subtasks: ATLAS-1288/ATLAS-1289 Integrated V2 API for Lineage,Entity Details,Tag assign to entity,Tags listing,tag create


Project: http://git-wip-us.apache.org/repos/asf/incubator-atlas/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-atlas/commit/efc8d09c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-atlas/tree/efc8d09c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-atlas/diff/efc8d09c

Branch: refs/heads/master
Commit: efc8d09c8664f2105b15519d52c79c3b1fb425df
Parents: 3bffc0d
Author: kevalbhatt <kbhatt@apache.org>
Authored: Wed Dec 14 11:09:11 2016 +0530
Committer: kevalbhatt <kbhatt@apache.org>
Committed: Wed Dec 14 11:09:11 2016 +0530

----------------------------------------------------------------------
 .../public/js/collection/VCatalogList.js        |   5 +-
 dashboardv2/public/js/collection/VCommonList.js |   5 +-
 dashboardv2/public/js/collection/VEntityList.js |  36 +-
 .../public/js/collection/VLineageList.js        |  17 +-
 dashboardv2/public/js/collection/VSchemaList.js |   7 +-
 dashboardv2/public/js/collection/VSearchList.js |   7 +-
 dashboardv2/public/js/collection/VTagList.js    |  31 +-
 dashboardv2/public/js/main.js                   |   7 +-
 dashboardv2/public/js/models/VCatalog.js        |   9 +-
 dashboardv2/public/js/models/VCommon.js         |   9 +-
 dashboardv2/public/js/models/VEntity.js         |  21 +-
 dashboardv2/public/js/models/VLineage.js        |   7 +-
 dashboardv2/public/js/models/VSchema.js         |   7 +-
 dashboardv2/public/js/models/VSearch.js         |  11 +-
 dashboardv2/public/js/models/VTag.js            |  17 +-
 dashboardv2/public/js/router/Router.js          |  26 +-
 .../public/js/utils/CommonViewFunction.js       | 196 ++-----
 dashboardv2/public/js/utils/Enums.js            |  51 ++
 dashboardv2/public/js/utils/Globals.js          |  13 +-
 dashboardv2/public/js/utils/UrlLinks.js         | 100 ++++
 .../js/views/audit/AuditTableLayoutView.js      |  14 +-
 .../views/audit/CreateAuditTableLayoutView.js   |   8 +-
 .../views/business_catalog/SideNavLayoutView.js |   4 +-
 .../js/views/business_catalog/TreeLayoutView.js |  15 +-
 .../public/js/views/common/aboutAtlas.js        |   7 +-
 .../views/detail_page/DetailPageLayoutView.js   |  69 ++-
 .../views/entity/EntityDetailTableLayoutView.js |  12 +-
 .../public/js/views/graph/LineageLayoutView.js  | 546 ++++++++-----------
 .../public/js/views/schema/SchemaLayoutView.js  |  10 +-
 .../public/js/views/search/SearchLayoutView.js  |   9 +-
 .../js/views/search/SearchResultLayoutView.js   |  48 +-
 .../public/js/views/tag/CreateTagLayoutView.js  |   9 +-
 .../views/tag/TagAttributeDetailLayoutView.js   | 100 ++--
 .../public/js/views/tag/TagDetailLayoutView.js  |   5 +-
 .../js/views/tag/TagDetailTableLayoutView.js    |   6 +-
 .../public/js/views/tag/TagLayoutView.js        |  57 +-
 .../public/js/views/tag/addTagModalView.js      |  53 +-
 release-log.txt                                 |   1 +
 38 files changed, 794 insertions(+), 761 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/collection/VCatalogList.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/collection/VCatalogList.js b/dashboardv2/public/js/collection/VCatalogList.js
index 90cbfa0..a631de1 100644
--- a/dashboardv2/public/js/collection/VCatalogList.js
+++ b/dashboardv2/public/js/collection/VCatalogList.js
@@ -20,12 +20,13 @@ define(['require',
     'utils/Globals',
     'collection/BaseCollection',
     'models/VCatalog',
-], function(require, Globals, BaseCollection, VCatalog) {
+    'utils/UrlLinks'
+], function(require, Globals, BaseCollection, VCatalog, UrlLinks) {
     'use strict';
     var VCatalogList = BaseCollection.extend(
         //Prototypal attributes
         {
-            url: Globals.baseURL + '/api/atlas/v1/taxonomies',
+            url: UrlLinks.taxonomiesApiUrl(),
 
             model: VCatalog,
 

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/collection/VCommonList.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/collection/VCommonList.js b/dashboardv2/public/js/collection/VCommonList.js
index 9b33b24..87091ca 100644
--- a/dashboardv2/public/js/collection/VCommonList.js
+++ b/dashboardv2/public/js/collection/VCommonList.js
@@ -20,12 +20,13 @@ define(['require',
     'utils/Globals',
     'collection/BaseCollection',
     'models/VCommon',
-], function(require, Globals, BaseCollection, VCommon) {
+    'utils/UrlLinks'
+], function(require, Globals, BaseCollection, VCommon, UrlLinks) {
     'use strict';
     var VCommonList = BaseCollection.extend(
         //Prototypal attributes
         {
-            url: Globals.baseURL + '',
+            url: UrlLinks.baseURL + '',
 
             model: VCommon,
 

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/collection/VEntityList.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/collection/VEntityList.js b/dashboardv2/public/js/collection/VEntityList.js
index 75e6733..bfcbe99 100644
--- a/dashboardv2/public/js/collection/VEntityList.js
+++ b/dashboardv2/public/js/collection/VEntityList.js
@@ -19,20 +19,48 @@
 define(['require',
     'utils/Globals',
     'collection/BaseCollection',
-    'models/VEntity'
-], function(require, Globals, BaseCollection, VEntity) {
+    'models/VEntity',
+    'utils/UrlLinks'
+], function(require, Globals, BaseCollection, VEntity, UrlLinks) {
     'use strict';
     var VEntityList = BaseCollection.extend(
         //Prototypal attributes
         {
-            url: Globals.baseURL + '/api/atlas/entities',
+            url: UrlLinks.entitiesApiUrl(),
 
             model: VEntity,
 
             initialize: function() {
                 this.modelName = 'VEntity';
-                this.modelAttrName = 'definition';
+                this.modelAttrName = '';
                 this.bindErrorEvents();
+            },
+            parseRecords: function(resp, options) {
+                try {
+                    // if (!this.modelAttrName) {
+                    //     throw new Error("this.modelAttrName not defined for " + this);
+                    // }
+                    if (this.modelAttrName && this.modelAttrName.length) {
+                        if (resp[this.modelAttrName]) {
+                            return resp[this.modelAttrName];
+                        } else {
+                            return resp
+                        }
+
+                    } else {
+                        var arr = [];
+                        arr.push({
+                            attributes: resp.attributes,
+                            classifications: resp.classifications,
+                            guid: resp.guid,
+                            typeName: resp.typeName
+                        });
+                        return arr;
+                    }
+
+                } catch (e) {
+                    console.log(e);
+                }
             }
         },
         //Static Class Members

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/collection/VLineageList.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/collection/VLineageList.js b/dashboardv2/public/js/collection/VLineageList.js
index cb18610..a2656df 100644
--- a/dashboardv2/public/js/collection/VLineageList.js
+++ b/dashboardv2/public/js/collection/VLineageList.js
@@ -19,13 +19,14 @@
 define(['require',
     'utils/Globals',
     'collection/BaseCollection',
-    'models/VLineage'
-], function(require, Globals, BaseCollection, VLineage) {
+    'models/VLineage',
+    'utils/UrlLinks'
+], function(require, Globals, BaseCollection, VLineage, UrlLinks) {
     'use strict';
     var VLineageList = BaseCollection.extend(
         //Prototypal attributes
         {
-            url: Globals.baseURL,
+            url: UrlLinks.baseURL,
 
             model: VLineage,
 
@@ -33,6 +34,16 @@ define(['require',
                 this.modelName = 'VLineage';
                 this.modelAttrName = 'results';
                 this.bindErrorEvents();
+            },
+            getLineage: function(id, options) {
+                var url = UrlLinks.lineageApiUrl(id);
+
+                options = _.extend({
+                    contentType: 'application/json',
+                    dataType: 'json'
+                }, options);
+
+                return this.constructor.nonCrudOperation.call(this, url, 'GET', options);
             }
         },
         //Static Class Members

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/collection/VSchemaList.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/collection/VSchemaList.js b/dashboardv2/public/js/collection/VSchemaList.js
index c11a0ba..18ffeda 100644
--- a/dashboardv2/public/js/collection/VSchemaList.js
+++ b/dashboardv2/public/js/collection/VSchemaList.js
@@ -19,13 +19,14 @@
 define(['require',
     'utils/Globals',
     'collection/BaseCollection',
-    'models/VSchema'
-], function(require, Globals, BaseCollection, VSchema) {
+    'models/VSchema',
+    'utils/UrlLinks'
+], function(require, Globals, BaseCollection, VSchema, UrlLinks) {
     'use strict';
     var VSchemaList = BaseCollection.extend(
         //Prototypal attributes
         {
-            url: Globals.baseURL,
+            url: UrlLinks.baseURL,
             model: VSchema,
             initialize: function() {
                 this.modelName = 'VSchema';

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/collection/VSearchList.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/collection/VSearchList.js b/dashboardv2/public/js/collection/VSearchList.js
index bcdecd3..640be40 100644
--- a/dashboardv2/public/js/collection/VSearchList.js
+++ b/dashboardv2/public/js/collection/VSearchList.js
@@ -19,13 +19,14 @@
 define(['require',
     'utils/Globals',
     'collection/BaseCollection',
-    'models/VSearch'
-], function(require, Globals, BaseCollection, VSearch) {
+    'models/VSearch',
+    'utils/UrlLinks'
+], function(require, Globals, BaseCollection, VSearch, UrlLinks) {
     'use strict';
     var VSearchList = BaseCollection.extend(
         //Prototypal attributes
         {
-            url: Globals.baseURL + '/api/atlas/discovery/search',
+            url: UrlLinks.searchApiUrl(),
 
             model: VSearch,
 

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/collection/VTagList.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/collection/VTagList.js b/dashboardv2/public/js/collection/VTagList.js
index 472fc48..92c6436 100644
--- a/dashboardv2/public/js/collection/VTagList.js
+++ b/dashboardv2/public/js/collection/VTagList.js
@@ -19,17 +19,18 @@
 define(['require',
     'utils/Globals',
     'collection/BaseCollection',
-    'models/VTag'
-], function(require, Globals, BaseCollection, VTag) {
+    'models/VTag',
+    'utils/UrlLinks'
+], function(require, Globals, BaseCollection, VTag, UrlLinks) {
     'use strict';
     var VTagList = BaseCollection.extend(
         //Prototypal attributes
         {
-            url: Globals.baseURL + '/api/atlas/types',
+            url: UrlLinks.typesClassicationApiUrl(),
             model: VTag,
             initialize: function() {
                 this.modelName = 'VTag';
-                this.modelAttrName = 'results';
+                this.modelAttrName = 'list';
                 this.bindErrorEvents();
             },
             parseRecords: function(resp, options) {
@@ -37,13 +38,23 @@ define(['require',
                     if (!this.modelAttrName) {
                         throw new Error("this.modelAttrName not defined for " + this);
                     }
-                    var arr = [];
-                    resp[this.modelAttrName].forEach(function(d) {
-                        arr.push({
-                            tags: d
+                    if (this.modelAttrName === "list") {
+                        if (resp[this.modelAttrName]) {
+                            return resp[this.modelAttrName];
+                        } else {
+                            return resp
+                        }
+
+                    } else {
+                        var arr = [];
+                        resp[this.modelAttrName].forEach(function(d) {
+                            arr.push({
+                                tags: d
+                            });
                         });
-                    });
-                    return arr;
+                        return arr;
+                    }
+
                 } catch (e) {
                     console.log(e);
                 }

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/main.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/main.js b/dashboardv2/public/js/main.js
index 2b005a9..772d3d4 100644
--- a/dashboardv2/public/js/main.js
+++ b/dashboardv2/public/js/main.js
@@ -152,14 +152,15 @@ require(['App',
     'router/Router',
     'utils/CommonViewFunction',
     'utils/Globals',
+    'utils/UrlLinks',
     'utils/Overrides',
     'bootstrap',
     'd3',
-    'select2'
-], function(App, Router, CommonViewFunction, Globals) {
+    'select2' 
+], function(App, Router, CommonViewFunction, Globals, UrlLinks) {
     App.appRouter = new Router();
     CommonViewFunction.userDataFetch({
-        url: Globals.baseURL + "/api/atlas/admin/session",
+        url: UrlLinks.sessionApiUrl(),
         callback: function(response) {
             if (response && response.userName) {
                 Globals.userLogedIn.status = true;

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/models/VCatalog.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/models/VCatalog.js b/dashboardv2/public/js/models/VCatalog.js
index 346de51..85160b7 100644
--- a/dashboardv2/public/js/models/VCatalog.js
+++ b/dashboardv2/public/js/models/VCatalog.js
@@ -18,11 +18,12 @@
 
 define(['require',
     'utils/Globals',
-    'models/BaseModel'
-], function(require, Globals, VBaseModel) {
+    'models/BaseModel',
+    'utils/UrlLinks'
+], function(require, Globals, VBaseModel, UrlLinks) {
     'use strict';
     var VCatalog = VBaseModel.extend({
-        urlRoot: Globals.baseURL + '/api/atlas/v1/taxonomies',
+        urlRoot: UrlLinks.taxonomiesApiUrl(),
 
         defaults: {},
 
@@ -38,7 +39,7 @@ define(['require',
             return this.get('name');
         },
         deleteTerm: function(termURL, options) {
-            var url = Globals.baseURL + termURL;
+            var url = UrlLinks.baseURL + termURL;
             options = _.extend({
                 contentType: 'application/json',
                 dataType: 'json'

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/models/VCommon.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/models/VCommon.js b/dashboardv2/public/js/models/VCommon.js
index f744f6c..25462fe 100644
--- a/dashboardv2/public/js/models/VCommon.js
+++ b/dashboardv2/public/js/models/VCommon.js
@@ -18,11 +18,12 @@
 
 define(['require',
     'utils/Globals',
-    'models/BaseModel'
-], function(require, Globals, VBaseModel) {
+    'models/BaseModel',
+    'utils/UrlLinks'
+], function(require, Globals, VBaseModel, UrlLinks) {
     'use strict';
     var VCommon = VBaseModel.extend({
-        urlRoot: Globals.baseURL + '',
+        urlRoot: UrlLinks.baseUrl + '',
 
         defaults: {},
 
@@ -41,7 +42,7 @@ define(['require',
          * Non - CRUD operations
          *************************/
         aboutUs: function(url, options) {
-            var url = Globals.baseURL + url;
+            var url = url;
             options = _.extend({
                 contentType: 'application/json',
                 dataType: 'json'

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/models/VEntity.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/models/VEntity.js b/dashboardv2/public/js/models/VEntity.js
index cd84e9d..4347b62 100644
--- a/dashboardv2/public/js/models/VEntity.js
+++ b/dashboardv2/public/js/models/VEntity.js
@@ -18,12 +18,13 @@
 
 define(['require',
     'utils/Globals',
-    'models/BaseModel'
-], function(require, Globals, VBaseModel) {
+    'models/BaseModel',
+    'utils/UrlLinks'
+], function(require, Globals, VBaseModel, UrlLinks) {
     'use strict';
     var VEntity = VBaseModel.extend({
 
-        urlRoot: Globals.baseURL + '/api/atlas/entities/',
+        urlRoot: UrlLinks.entitiesApiUrl(),
 
         defaults: {},
 
@@ -43,7 +44,7 @@ define(['require',
          *************************/
 
         getEntity: function(token, options) {
-            var url = Globals.baseURL + '/api/atlas/entities/' + token;
+            var url = UrlLinks.entitiesApiUrl(token);
 
             options = _.extend({
                 contentType: 'application/json',
@@ -53,13 +54,23 @@ define(['require',
             return this.constructor.nonCrudOperation.call(this, url, 'GET', options);
         },
         saveEntity: function(token, options) {
-            var url = Globals.baseURL + '/api/atlas/entities/' + token + '/traits';
+            var url = UrlLinks.entitiesTraitsApiUrl(token);
             options = _.extend({
                 contentType: 'application/json',
                 dataType: 'json'
             }, options);
             return this.constructor.nonCrudOperation.call(this, url, 'POST', options);
         },
+        getEntityDef: function(name, options) {
+            var url = UrlLinks.entitiesDefApiUrl(name);
+
+            options = _.extend({
+                contentType: 'application/json',
+                dataType: 'json'
+            }, options);
+
+            return this.constructor.nonCrudOperation.call(this, url, 'GET', options);
+        }
 
     }, {});
     return VEntity;

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/models/VLineage.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/models/VLineage.js b/dashboardv2/public/js/models/VLineage.js
index 7323473..d55bfeb 100644
--- a/dashboardv2/public/js/models/VLineage.js
+++ b/dashboardv2/public/js/models/VLineage.js
@@ -18,12 +18,13 @@
 
 define(['require',
     'utils/Globals',
-    'models/BaseModel'
-], function(require, Globals, VBaseModel) {
+    'models/BaseModel',
+    'utils/UrlLinks'
+], function(require, Globals, VBaseModel, UrlLinks) {
     'use strict';
     var VLineage = VBaseModel.extend({
 
-        urlRoot: Globals.baseURL,
+        urlRoot: UrlLinks.baseURL,
 
         defaults: {},
 

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/models/VSchema.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/models/VSchema.js b/dashboardv2/public/js/models/VSchema.js
index 9d781d7..f7f083c 100644
--- a/dashboardv2/public/js/models/VSchema.js
+++ b/dashboardv2/public/js/models/VSchema.js
@@ -18,11 +18,12 @@
 
 define(['require',
     'utils/Globals',
-    'models/BaseModel'
-], function(require, Globals, VBaseModel) {
+    'models/BaseModel',
+    'utils/UrlLinks'
+], function(require, Globals, VBaseModel, UrlLinks) {
     'use strict';
     var VSchema = VBaseModel.extend({
-        urlRoot: Globals.baseURL,
+        urlRoot: UrlLinks.baseURL,
 
         defaults: {},
 

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/models/VSearch.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/models/VSearch.js b/dashboardv2/public/js/models/VSearch.js
index 13376cc..906b96f 100644
--- a/dashboardv2/public/js/models/VSearch.js
+++ b/dashboardv2/public/js/models/VSearch.js
@@ -18,11 +18,12 @@
 
 define(['require',
     'utils/Globals',
-    'models/BaseModel'
-], function(require, Globals, VBaseModel) {
+    'models/BaseModel',
+    'utils/UrlLinks'
+], function(require, Globals, VBaseModel, UrlLinks) {
     'use strict';
     var VSearch = VBaseModel.extend({
-        urlRoot: Globals.baseURL + '/api/atlas/discovery/search',
+        urlRoot: UrlLinks.searchApiUrl(),
 
         defaults: {},
 
@@ -40,8 +41,8 @@ define(['require',
         /*************************
          * Non - CRUD operations
          *************************/
-        getEntity: function(token, options) {
-            var url = Globals.baseURL + '/api/atlas/entities/' + token;
+        getEntity: function(id, options) {
+            var url = UrlLinks.entitiesApiUrl(id);
 
             options = _.extend({
                 contentType: 'application/json',

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/models/VTag.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/models/VTag.js b/dashboardv2/public/js/models/VTag.js
index 12c36f8..2938572 100644
--- a/dashboardv2/public/js/models/VTag.js
+++ b/dashboardv2/public/js/models/VTag.js
@@ -18,11 +18,12 @@
 
 define(['require',
     'utils/Globals',
-    'models/BaseModel'
-], function(require, Globals, vBaseModel) {
+    'models/BaseModel',
+    'utils/UrlLinks'
+], function(require, Globals, vBaseModel, UrlLinks) {
     'use strict';
     var VTag = vBaseModel.extend({
-        urlRoot: Globals.baseURL + '/api/atlas/types',
+        urlRoot: UrlLinks.typesClassicationApiUrl(),
 
         defaults: {},
 
@@ -41,12 +42,20 @@ define(['require',
          * Non - CRUD operations
          *************************/
         deleteTag: function(guid, name, options) {
-            var url = Globals.baseURL + '/api/atlas/entities/' + guid + '/traits/' + name;
+            var url = UrlLinks.entitiesApiUrl(guid, name);
             options = _.extend({
                 contentType: 'application/json',
                 dataType: 'json'
             }, options);
             return this.constructor.nonCrudOperation.call(this, url, 'DELETE', options);
+        },
+        saveTagAttribute: function(name, options) {
+            var url = UrlLinks.typesClassicationApiUrl(name);
+            options = _.extend({
+                contentType: 'application/json',
+                dataType: 'json'
+            }, options);
+            return this.constructor.nonCrudOperation.call(this, url, 'PUT', options);
         }
     }, {});
     return VTag;

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/router/Router.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/router/Router.js b/dashboardv2/public/js/router/Router.js
index 0841a4c..fa4a08a 100644
--- a/dashboardv2/public/js/router/Router.js
+++ b/dashboardv2/public/js/router/Router.js
@@ -22,8 +22,10 @@ define([
     'backbone',
     'App',
     'utils/Globals',
-    'utils/Utils'
-], function($, _, Backbone, App, Globals, Utils) {
+    'utils/Utils',
+    'utils/UrlLinks',
+    'collection/VTagList'
+], function($, _, Backbone, App, Globals, Utils, UrlLinks, VTagList) {
     var AppRouter = Backbone.Router.extend({
         routes: {
             // Define some URL routes
@@ -46,6 +48,7 @@ define([
             this.globalVent = new Backbone.Wreqr.EventAggregator();
             this.catalogVent = new Backbone.Wreqr.EventAggregator();
             this.tagVent = new Backbone.Wreqr.EventAggregator();
+            this.tagCollection = new VTagList();
         },
         bindCommonEvents: function() {
             var that = this;
@@ -110,7 +113,7 @@ define([
                     this.collection.url = url;
                     App.rNHeader.show(new BusinessCatalogHeader({ 'globalVent': that.globalVent, 'url': url, 'collection': this.collection }));
                     if (!App.rSideNav.currentView) {
-                        App.rSideNav.show(new SideNavLayoutView({ 'globalVent': that.globalVent, 'url': url }));
+                        App.rSideNav.show(new SideNavLayoutView({ 'globalVent': that.globalVent, 'url': url, 'collection': that.tagCollection }));
                     } else {
                         App.rSideNav.currentView.RBusinessCatalogLayoutView.currentView.manualRender("/" + url);
                         App.rSideNav.currentView.selectTab();
@@ -138,17 +141,16 @@ define([
                     this.entityCollection = new VEntityList([], {});
                     App.rNHeader.show(new Header({ 'globalVent': that.globalVent }));
                     if (!App.rSideNav.currentView) {
-                        App.rSideNav.show(new SideNavLayoutView({ 'globalVent': that.globalVent }));
+                        App.rSideNav.show(new SideNavLayoutView({ 'globalVent': that.globalVent, 'collection': that.tagCollection }));
                     } else {
                         App.rSideNav.currentView.selectTab();
                     }
-
                     App.rNContent.show(new DetailPageLayoutView({
                         'globalVent': that.globalVent,
                         'collection': this.entityCollection,
                         'id': id,
                     }));
-                    this.entityCollection.url = "/api/atlas/entities/" + id;
+                    this.entityCollection.url = UrlLinks.entitiesApiUrl(id);
                     this.entityCollection.fetch({ reset: true });
                 });
             }
@@ -165,7 +167,8 @@ define([
                 if (!App.rSideNav.currentView) {
                     App.rSideNav.show(new SideNavLayoutView({
                         'globalVent': that.globalVent,
-                        'tag': tagName
+                        'tag': tagName,
+                        'collection': that.tagCollection
                     }));
                 } else {
 
@@ -176,7 +179,8 @@ define([
                 if (tagName) {
                     App.rNContent.show(new TagDetailLayoutView({
                         'globalVent': that.globalVent,
-                        'tag': tagName
+                        'tag': tagName,
+                        'collection': that.tagCollection
                     }));
                 }
             });
@@ -191,7 +195,8 @@ define([
                 App.rNHeader.show(new Header({ 'globalVent': that.globalVent }));
                 if (!App.rSideNav.currentView) {
                     App.rSideNav.show(new SideNavLayoutView({
-                        'globalVent': that.globalVent
+                        'globalVent': that.globalVent,
+                        'collection': that.tagCollection
                     }));
                 } else {
                     App.rSideNav.currentView.selectTab();
@@ -218,7 +223,8 @@ define([
                 if (!App.rSideNav.currentView) {
                     App.rSideNav.show(new SideNavLayoutView({
                         'globalVent': that.globalVent,
-                        'value': paramObj
+                        'value': paramObj,
+                        'collection': that.tagCollection
                     }));
                 } else {
                     App.rSideNav.currentView.RSearchLayoutView.currentView.manualRender(paramObj);

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/utils/CommonViewFunction.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/utils/CommonViewFunction.js b/dashboardv2/public/js/utils/CommonViewFunction.js
index 67dd5e2..d8cf9b0 100644
--- a/dashboardv2/public/js/utils/CommonViewFunction.js
+++ b/dashboardv2/public/js/utils/CommonViewFunction.js
@@ -16,7 +16,7 @@
  * limitations under the License.
  */
 
-define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Globals'], function(require, Utils, Modal, Messages, Globals) {
+define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Enums'], function(require, Utils, Modal, Messages, Enums) {
     'use strict';
 
     var CommonViewFunction = {};
@@ -80,23 +80,23 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
                     success: function(data) {
                         var value = "",
                             deleteButton = "";
-                        if (data.definition.values.name) {
-                            value = data.definition.values.name;
-                        } else if (data.definition.values.qualifiedName) {
-                            value = data.definition.values.qualifiedName;
-                        } else if (data.definition.typeName) {
-                            value = data.definition.typeName;
+
+                        if (data && data.attributes) {
+                            if (data.attributes.name) {
+                                value = data.attributes.name;
+                            } else if (data.attributes.qualifiedName) {
+                                value = data.attributes.qualifiedName;
+                            } else if (data.typeName) {
+                                value = data.typeName;
+                            }
                         }
                         var id = "";
-                        if (data.definition.id) {
-                            if (_.isObject(data.definition.id) && data.definition.id.id) {
-                                id = data.definition.id.id;
-                                if (Globals.entityStateReadOnly[data.definition.id.state]) {
-                                    deleteButton += '<button title="Deleted" class="btn btn-atlasAction btn-atlas deleteBtn"><i class="fa fa-trash"></i></button>';
-                                }
-                            } else {
-                                id = data.definition.id;
+                        if (data.guid) {
+                            if (Enums.entityStateReadOnly[data.attributes.state]) {
+                                deleteButton += '<button title="Deleted" class="btn btn-atlasAction btn-atlas deleteBtn"><i class="fa fa-trash"></i></button>';
                             }
+                            id = data.guid;
+
                         }
                         if (value.length > 1) {
                             scope.$('td div[data-id="' + id + '"]').html('<a href="#!/detailPage/' + id + '">' + value + '</a>');
@@ -120,47 +120,38 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
         _.keys(valueObject).map(function(key) {
             var keyValue = valueObject[key],
                 valueOfArray = [];
-            if (_.isArray(keyValue)) {
+            if (_.isArray(keyValue) || _.isObject(keyValue)) {
+                if (!_.isArray(keyValue) && _.isObject(keyValue)) {
+                    keyValue = [keyValue];
+                }
                 var subLink = "";
                 for (var i = 0; i < keyValue.length; i++) {
                     var inputOutputField = keyValue[i],
-                        id = undefined,
+                        id = inputOutputField.guid,
                         tempLink = "",
                         readOnly = false;
-                    if (inputOutputField['$id$']) {
-                        inputOutputField.id = inputOutputField['$id$'];
-                    }
-                    if (inputOutputField) {
-                        if (_.isObject(inputOutputField.id)) {
-                            id = inputOutputField.id.id;
-                            if (Globals.entityStateReadOnly[inputOutputField.id.state]) {
-                                readOnly = inputOutputField.id.state
-                            }
-                        } else if (inputOutputField.id) {
-                            id = inputOutputField.id;
-                        } else if (_.isString(inputOutputField) || _.isBoolean(inputOutputField) || _.isNumber(inputOutputField)) {
-                            if (inputOutputField.indexOf("$") == -1) {
-                                valueOfArray.push('<span>' + inputOutputField + '</span>');
-                            }
-                        } else if (_.isObject(inputOutputField)) {
-                            _.each(inputOutputField, function(objValue, objKey) {
-                                var value = objValue;
-                                if (objKey.indexOf("$") == -1) {
-                                    if (_.isObject(value)) {
-                                        value = JSON.stringify(value);
-                                    }
-                                    valueOfArray.push('<span>' + objKey + ':' + value + '</span>');
-                                }
-                            });
+                    if (_.isString(inputOutputField) || _.isBoolean(inputOutputField) || _.isNumber(inputOutputField)) {
+                        if (inputOutputField.indexOf("$") == -1) {
+                            valueOfArray.push('<span>' + inputOutputField + '</span>');
                         }
+                    } else if (_.isObject(inputOutputField) && !inputOutputField.attributes && !id) {
+                        _.each(inputOutputField, function(objValue, objKey) {
+                            var value = objValue;
+                            if (objKey.indexOf("$") == -1) {
+                                if (_.isObject(value)) {
+                                    value = JSON.stringify(value);
+                                }
+                                valueOfArray.push('<span>' + objKey + ':' + value + '</span>');
+                            }
+                        });
                     }
 
-                    if (id) {
-                        if (inputOutputField.values) {
-                            if (inputOutputField.values.name) {
-                                tempLink += '<a href="#!/detailPage/' + id + '">' + inputOutputField.values.name + '</a>'
-                            } else if (inputOutputField.values.qualifiedName) {
-                                tempLink += '<a href="#!/detailPage/' + id + '">' + inputOutputField.values.qualifiedName + '</a>'
+                    if (id && inputOutputField) {
+                        if (inputOutputField.attributes) {
+                            if (inputOutputField.attributes.name) {
+                                tempLink += '<a href="#!/detailPage/' + id + '">' + inputOutputField.attributes.name + '</a>'
+                            } else if (inputOutputField.attributes.qualifiedName) {
+                                tempLink += '<a href="#!/detailPage/' + id + '">' + inputOutputField.attributes.qualifiedName + '</a>'
                             } else if (inputOutputField.typeName) {
                                 tempLink += '<a href="#!/detailPage/' + id + '">' + inputOutputField.typeName + '</a>'
                             } else {
@@ -176,6 +167,7 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
                             tempLink += '<div data-id="' + id + '"></div>';
                         }
                     }
+
                     if (readOnly) {
                         if (!fetch) {
                             tempLink += '<button title="Deleted" class="btn btn-atlasAction btn-atlas deleteBtn"><i class="fa fa-trash"></i></button>';
@@ -201,98 +193,6 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
                 } else {
                     table += '<tr><td>' + key + '</td><td>' + subLink + '</td></tr>';
                 }
-            } else if (_.isObject(keyValue)) {
-                var id = undefined,
-                    tempLink = "",
-                    readOnly = false;
-                if (keyValue['$id$']) {
-                    keyValue.id = keyValue['$id$'];
-                }
-                if (_.isObject(keyValue.id)) {
-                    id = keyValue.id.id;
-                    if (Globals.entityStateReadOnly[keyValue.id.state]) {
-                        readOnly = keyValue.id.state
-                    }
-                } else {
-                    id = keyValue.id;
-                }
-                if (id) {
-                    if (keyValue.values) {
-                        if (keyValue.values.name) {
-                            tempLink += '<a href="#!/detailPage/' + id + '">' + keyValue.values.name + '</a>';
-                        } else if (keyValue.values.qualifiedName) {
-                            tempLink += '<a href="#!/detailPage/' + id + '">' + keyValue.values.qualifiedName + '</a>'
-                        } else if (keyValue.typeName) {
-                            tempLink += '<a href="#!/detailPage/' + id + '">' + keyValue.typeName + '</a>'
-                        } else {
-                            tempLink += '<a href="#!/detailPage/' + id + '">' + id + '</a>';
-                        }
-                    } else if (keyValue.name) {
-                        tempLink += '<a href="#!/detailPage/' + id + '">' + keyValue.name + '</a>';
-                    } else if (keyValue.qualifiedName) {
-                        tempLink += '<a href="#!/detailPage/' + id + '">' + keyValue.qualifiedName + '</a>'
-                    } else {
-                        var fetch = true;
-                        fetchInputOutputValue(id);
-                        tempLink += '<div data-id="' + id + '"></div>';
-                    }
-                    if (readOnly) {
-                        if (!fetch) {
-                            tempLink += '<button title="Deleted" class="btn btn-atlasAction btn-atlas deleteBtn"><i class="fa fa-trash"></i></button>';
-                        }
-
-                        if (searchTable) {
-                            if (!fetch) {
-                                table = '<div class="block readOnlyLink">' + tempLink + '</div>';
-                            } else {
-                                table = tempLink;
-                            }
-                        } else {
-                            if (!fetch) {
-                                table += '<tr><td>' + key + '</td><td><div class="block readOnlyLink">' + tempLink + '</div></td></tr>';
-                            } else {
-                                table += '<tr><td>' + key + '</td><td>' + tempLink + '</td></tr>';
-                            }
-                        }
-                    } else {
-                        if (searchTable) {
-                            table = tempLink;
-                        } else {
-                            table += '<tr><td>' + key + '</td><td>' + tempLink + '</td></tr>';
-                        }
-                    }
-                } else {
-                    var stringArr = [];
-                    _.each(keyValue, function(val, key) {
-                        var value = "";
-                        if (_.isObject(val)) {
-                            value = JSON.stringify(val);
-                        } else {
-                            value = val;
-                        }
-                        var attrName = "<span>" + key + " : " + value + "</span>";
-                        stringArr.push(attrName);
-                    });
-                    var jointValues = stringArr.join(", ");
-                    if (jointValues.length) {
-                        tempLink += '<div>' + jointValues + '</div>';
-                    }
-                    if (readOnly) {
-                        tempLink += '<button title="Deleted" class="btn btn-atlasAction btn-atlas deleteBtn"><i class="fa fa-trash"></i></button>';
-                        if (searchTable) {
-                            table = '<div class="block readOnlyLink">' + tempLink + '</div>';
-                        } else {
-                            table += '<tr><td>' + key + '</td><td><div class="block readOnlyLink">' + tempLink + '</div></td></tr>';
-                        }
-
-                    } else {
-                        if (searchTable) {
-                            table = tempLink;
-                        } else {
-                            table += '<tr><td>' + key + '</td><td>' + tempLink + '</td></tr>';
-                        }
-                    }
-                }
             } else {
                 if (key.indexOf("Time") !== -1 || key == "retention") {
                     if (searchTable) {
@@ -368,7 +268,6 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
                 dropdown: function(classes) {
                     var dropdownClass = 'dropdown';
                     var dropdownMenuClass = 'dropdown-menu popover popoverTerm bottom arrowPosition';
-
                     if (this.options.overflow === 'right') {
                         dropdownMenuClass += ' dropdown-menu-right';
                     }
@@ -386,11 +285,14 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
         }
     }
     CommonViewFunction.termTableBreadcrumbMaker = function(model) {
+        if (!model) {
+            return "";
+        }
         var traits = model.get('$traits$'),
             url = "",
             deleteHtml = "",
             html = "",
-            id = model.get('$id$').id,
+            id = model.get('$id$').id || model.get('$id$'),
             terms = [];
         _.keys(traits).map(function(key) {
             if (traits[key]) {
@@ -398,7 +300,7 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
             }
             if (tagName.term) {
                 terms.push({
-                    deleteHtml: '<a class="pull-left" title="Remove Term"><i class="fa fa-trash" data-id="tagClick" data-type="term" data-assetname="' + model.get("name") + '" data-name="' + tagName.fullName + '" data-guid="' + model.get('$id$').id + '" ></i></a>',
+                    deleteHtml: '<a class="pull-left" title="Remove Term"><i class="fa fa-trash" data-id="tagClick" data-type="term" data-assetname="' + model.get("name") + '" data-name="' + tagName.fullName + '" data-guid="' + (model.get('$id$').id || model.get('$id$')) + '" ></i></a>',
                     url: tagName.fullName.split(".").join("/"),
                     name: tagName.fullName
                 });
@@ -416,7 +318,7 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
             html += '<div><a  href="javascript:void(0)" data-id="showMoreLessTerm" class="inputTag inputTagGreen"><span>Show More </span><i class="fa fa-angle-right"></i></a></div>'
         }
         if (model.get('$id$')) {
-            html += '<div><a href="javascript:void(0)" class="inputAssignTag" data-id="addTerm" data-guid="' + model.get('$id$').id + '"><i class="fa fa-folder-o"></i>' + " " + 'Assign Term</a></div>'
+            html += '<div><a href="javascript:void(0)" class="inputAssignTag" data-id="addTerm" data-guid="' + (model.get('$id$').id || model.get('$id$')) + '"><i class="fa fa-folder-o"></i>' + " " + 'Assign Term</a></div>'
         } else {
             html += '<div><a href="javascript:void(0)" class="inputAssignTag" data-id="addTerm"><i class="fa fa-folder-o"></i>' + " " + 'Assign Term</a></div>'
         }
@@ -439,15 +341,15 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Glob
             var className = "inputTag";
             if (tagName.tag) {
                 if (count >= 1) {
-                    popTag += '<a class="' + className + '" data-id="tagClick"><span class="inputValue">' + tagName.fullName + '</span><i class="fa fa-times" data-id="delete"  data-assetname="' + model.get("name") + '"data-name="' + tagName.fullName + '" data-type="tag" data-guid="' + model.get('$id$').id + '" ></i></a>';
+                    popTag += '<a class="' + className + '" data-id="tagClick"><span class="inputValue">' + tagName.fullName + '</span><i class="fa fa-times" data-id="delete"  data-assetname="' + model.get("name") + '"data-name="' + tagName.fullName + '" data-type="tag" data-guid="' + (model.get('$id$').id || model.get('$id$')) + '" ></i></a>';
                 } else {
-                    atags += '<a class="' + className + '" data-id="tagClick"><span class="inputValue">' + tagName.fullName + '</span><i class="fa fa-times" data-id="delete" data-assetname="' + model.get("name") + '" data-name="' + tagName.fullName + '"  data-type="tag" data-guid="' + model.get('$id$').id + '" ></i></a>';
+                    atags += '<a class="' + className + '" data-id="tagClick"><span class="inputValue">' + tagName.fullName + '</span><i class="fa fa-times" data-id="delete" data-assetname="' + model.get("name") + '" data-name="' + tagName.fullName + '"  data-type="tag" data-guid="' + (model.get('$id$').id || model.get('$id$')) + '" ></i></a>';
                 }
                 ++count;
             }
         });
         if (model.get('$id$')) {
-            addTag += '<a href="javascript:void(0)" data-id="addTag" class="inputTagAdd assignTag" data-guid="' + model.get('$id$').id + '" ><i class="fa fa-plus"></i></a>';
+            addTag += '<a href="javascript:void(0)" data-id="addTag" class="inputTagAdd assignTag" data-guid="' + (model.get('$id$').id || model.get('$id$')) + '" ><i class="fa fa-plus"></i></a>';
         } else {
             addTag += '<a href="javascript:void(0)" data-id="addTag" class="inputTagAdd assignTag"><i style="right:0" class="fa fa-plus"></i></a>';
         }

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/utils/Enums.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/utils/Enums.js b/dashboardv2/public/js/utils/Enums.js
new file mode 100644
index 0000000..4948dcc
--- /dev/null
+++ b/dashboardv2/public/js/utils/Enums.js
@@ -0,0 +1,51 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+define(['require'], function(require) {
+    'use strict';
+
+    var Enums = {};
+
+    Enums.auditAction = {
+        ENTITY_CREATE: "Entity Created",
+        ENTITY_UPDATE: "Entity Updated",
+        ENTITY_DELETE: "Entity Deleted",
+        TAG_ADD: "Tag Added",
+        TAG_DELETE: "Tag Deleted"
+    }
+
+    Enums.entityStateReadOnly = {
+        ACTIVE: false,
+        DELETED: true,
+        STATUS_ACTIVE: false,
+        STATUS_DELETED: true
+    }
+
+    Enums.lineageUrlType = {
+        INPUT: 'inputs',
+        OUTPUT: 'outputs',
+        SCHEMA: 'schema'
+    }
+
+    Enums.searchUrlType = {
+        DSL: 'dsl',
+        FULLTEXT: 'fulltext'
+    }
+
+    return Enums;
+});

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/utils/Globals.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/utils/Globals.js b/dashboardv2/public/js/utils/Globals.js
index 344e0f1..fb95bc6 100644
--- a/dashboardv2/public/js/utils/Globals.js
+++ b/dashboardv2/public/js/utils/Globals.js
@@ -21,7 +21,7 @@ define(['require'], function(require) {
 
     var Globals = {};
 
-    Globals.baseURL = '';
+    //Globals.baseURL = '/api/atlas';
     Globals.settings = {};
     Globals.settings.PAGE_SIZE = 25;
     Globals.saveApplicationState = {
@@ -34,17 +34,6 @@ define(['require'], function(require) {
         },
         detailPageState: {}
     };
-    Globals.auditAction = {
-        ENTITY_CREATE: "Entity Created",
-        ENTITY_UPDATE: "Entity Updated",
-        ENTITY_DELETE: "Entity Deleted",
-        TAG_ADD: "Tag Added",
-        TAG_DELETE: "Tag Deleted"
-    }
-    Globals.entityStateReadOnly = {
-        ACTIVE: false,
-        DELETED: true
-    }
     Globals.userLogedIn = {
         status: false,
         response: {}

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/utils/UrlLinks.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/utils/UrlLinks.js b/dashboardv2/public/js/utils/UrlLinks.js
new file mode 100644
index 0000000..a5288be
--- /dev/null
+++ b/dashboardv2/public/js/utils/UrlLinks.js
@@ -0,0 +1,100 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+define(['require', 'utils/Enums'], function(require, Enums) {
+    'use strict';
+
+    var UrlLinks = {
+        baseUrl: '/api/atlas',
+        baseUrlV2: '/api/atlas/v2',
+        taxonomiesApiUrl: function() {
+            return this.baseUrl + '/v1/taxonomies';
+        },
+        taxonomiesTermsApiUrl: function(name) {
+            return this.baseUrl + '/v1/taxonomies' + '/' + name + '/terms';
+        },
+        entitiesApiUrl: function(guid, name) {
+            var entitiesUrl = this.baseUrlV2 + '/entity/guid';
+            if (guid && name) {
+                return entitiesUrl + '/' + guid + '/classification/' + name;
+            } else if (guid && !name) {
+                return entitiesUrl + '/' + guid;
+            } else {
+                return entitiesUrl;
+            }
+        },
+        entitiesDefApiUrl: function(name) {
+            var entitieDefUrl = this.baseUrlV2 + '/types/entitydef';
+            if (name) {
+                return entitieDefUrl + '/name/' + name;
+            } else {
+                return entitieDefUrl;
+            }
+        },
+        entitiesTraitsApiUrl: function(token) {
+            return this.baseUrlV2 + '/entity/guid/' + token + "/classifications"; //this.entitiesApiUrl();
+        },
+        entityCollectionaudit: function(guid) {
+            return this.baseUrl + '/entities/' + guid + '/audit';
+        },
+        typesClassicationApiUrl: function(name) {
+            var typeUrl = this.baseUrlV2 + '/types/classificationdef'
+            if (name) {
+                return typeUrl + '/name/' + name;
+            } else {
+                return typeUrl;
+            }
+        },
+        typesApiUrl: function() {
+            return this.baseUrlV2 + '/types/typedefs/headers'
+        },
+        lineageApiUrl: function(guid) {
+            var lineageUrl = this.baseUrlV2 + '/lineage';
+            if (guid) {
+                return lineageUrl + '/' + guid;
+            } else {
+                return lineageUrl
+            }
+        },
+        schemaApiUrl: function(guid) {
+            var lineageUrl = this.baseUrl + '/lineage';
+            if (guid) {
+                return lineageUrl + '/' + guid + '/schema'
+            } else {
+                return lineageUrl
+            }
+        },
+        searchApiUrl: function(searchtype) {
+            var searchUrl = this.baseUrl + '/discovery/search';
+            if (searchtype) {
+                return searchUrl + '/' + searchtype;
+            } else {
+                return searchUrl;
+            }
+        },
+        versionApiUrl: function() {
+            return this.baseUrl + '/admin/version';
+        },
+        sessionApiUrl: function() {
+            return this.baseUrl + '/admin/session';
+        }
+
+    };
+
+    return UrlLinks;
+});

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/views/audit/AuditTableLayoutView.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/views/audit/AuditTableLayoutView.js b/dashboardv2/public/js/views/audit/AuditTableLayoutView.js
index acb5d16..2665d4c 100644
--- a/dashboardv2/public/js/views/audit/AuditTableLayoutView.js
+++ b/dashboardv2/public/js/views/audit/AuditTableLayoutView.js
@@ -20,8 +20,9 @@ define(['require',
     'backbone',
     'hbs!tmpl/audit/AuditTableLayoutView_tmpl',
     'collection/VEntityList',
-    'utils/Globals'
-], function(require, Backbone, AuditTableLayoutView_tmpl, VEntityList, Globals) {
+    'utils/Enums',
+    'utils/UrlLinks'
+], function(require, Backbone, AuditTableLayoutView_tmpl, VEntityList, Enums, UrlLinks) {
     'use strict';
 
     var AuditTableLayoutView = Backbone.Marionette.LayoutView.extend(
@@ -60,7 +61,7 @@ define(['require',
                 _.extend(this, _.pick(options, 'globalVent', 'guid'));
                 this.entityCollection = new VEntityList();
                 this.count = 26;
-                this.entityCollection.url = "/api/atlas/entities/" + this.guid + "/audit";
+                this.entityCollection.url = UrlLinks.entityCollectionaudit(this.guid);
                 this.entityCollection.modelAttrName = "events";
                 this.entityModel = new this.entityCollection.model();
                 this.pervOld = [];
@@ -140,6 +141,7 @@ define(['require',
                         if ((that.entityCollection.models.length < that.count && that.currPage == 1) && that.next == that.entityCollection.last().get('eventKey')) {
                             options.next.attr('disabled', true);
                             options.previous.removeAttr("disabled");
+                            //that.renderTableLayoutView();
                         } else {
                             if (that.entityCollection.models.length > 0) {
                                 that.next = that.entityCollection.last().get('eventKey');
@@ -193,8 +195,8 @@ define(['require',
                         sortable: false,
                         formatter: _.extend({}, Backgrid.CellFormatter.prototype, {
                             fromRaw: function(rawValue, model) {
-                                if (Globals.auditAction[rawValue]) {
-                                    return Globals.auditAction[rawValue];
+                                if (Enums.auditAction[rawValue]) {
+                                    return Enums.auditAction[rawValue];
                                 } else {
                                     return rawValue;
                                 }
@@ -208,7 +210,7 @@ define(['require',
                         sortable: false,
                         formatter: _.extend({}, Backgrid.CellFormatter.prototype, {
                             fromRaw: function(rawValue, model) {
-                                return '<div class="label label-success auditDetailBtn" data-id="auditCreate" data-action="' + Globals.auditAction[model.attributes.action] + '" data-modalId="' + model.get('eventKey') + '">Detail</div>';
+                                return '<div class="label label-success auditDetailBtn" data-id="auditCreate" data-action="' + Enums.auditAction[model.attributes.action] + '" data-modalId="' + model.get('eventKey') + '">Detail</div>';
                             }
                         })
                     },

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/views/audit/CreateAuditTableLayoutView.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/views/audit/CreateAuditTableLayoutView.js b/dashboardv2/public/js/views/audit/CreateAuditTableLayoutView.js
index 58d5de8..bc4fbea 100644
--- a/dashboardv2/public/js/views/audit/CreateAuditTableLayoutView.js
+++ b/dashboardv2/public/js/views/audit/CreateAuditTableLayoutView.js
@@ -19,9 +19,9 @@
 define(['require',
     'backbone',
     'hbs!tmpl/audit/CreateAuditTableLayoutView_tmpl',
-    'utils/Globals',
+    'utils/Enums',
     'utils/CommonViewFunction'
-], function(require, Backbone, CreateAuditTableLayoutViewTmpl, Globals, CommonViewFunction) {
+], function(require, Backbone, CreateAuditTableLayoutViewTmpl, Enums, CommonViewFunction) {
     'use strict';
 
     var CreateAuditTableLayoutView = Backbone.Marionette.LayoutView.extend(
@@ -68,7 +68,7 @@ define(['require',
                     var detailsObject = JSON.parse(appendedString.replace("{" + auditData + ":", '{"' + auditData + '":'))[auditData];
                     //Append string for JSON parse
                     var valueObject = detailsObject.values;
-                    if (this.action == Globals.auditAction.TAG_ADD) {
+                    if (this.action == Enums.auditAction.TAG_ADD) {
                         this.ui.auditHeaderValue.html('<th>Tag</th>');
                         this.ui.auditValue.html("<tr><td>" + detailsObject.typeName + "</td></tr>");
                     } else {
@@ -83,7 +83,7 @@ define(['require',
                             this.ui.tableAudit.hide();
                         }
                     }
-                } else if (this.action == Globals.auditAction.TAG_DELETE) {
+                } else if (this.action == Enums.auditAction.TAG_DELETE) {
                     var appendedString = this.entityModel.get('details').split(':');
                     this.ui.auditHeaderValue.html('<th>Tag</th>');
                     this.ui.auditValue.html("<tr><td>" + appendedString[1] + "</td></tr>");

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/views/business_catalog/SideNavLayoutView.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/views/business_catalog/SideNavLayoutView.js b/dashboardv2/public/js/views/business_catalog/SideNavLayoutView.js
index c4cfb33..43bdaeb 100644
--- a/dashboardv2/public/js/views/business_catalog/SideNavLayoutView.js
+++ b/dashboardv2/public/js/views/business_catalog/SideNavLayoutView.js
@@ -66,7 +66,7 @@ define(['require',
             return events;
         },
         initialize: function(options) {
-            _.extend(this, _.pick(options, 'globalVent', 'url', 'value', 'tag', 'selectFirst'));
+            _.extend(this, _.pick(options, 'globalVent', 'url', 'value', 'tag', 'selectFirst','collection'));
             if (Globals.taxonomy) {
                 this.tabClass = "tab col-sm-4";
             } else {
@@ -98,7 +98,7 @@ define(['require',
             require(['views/tag/TagLayoutView'], function(TagLayoutView) {
                 that.RTagLayoutView.show(new TagLayoutView({
                     globalVent: that.globalVent,
-                    searchCollection: that.searchCollection,
+                    collection: that.collection,
                     tag: that.tag
                 }));
             });

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js b/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js
index 5802c92..5b23966 100644
--- a/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js
+++ b/dashboardv2/public/js/views/business_catalog/TreeLayoutView.js
@@ -22,8 +22,9 @@ define(['require',
     'utils/Utils',
     'collection/VCatalogList',
     'utils/CommonViewFunction',
-    'utils/Messages'
-], function(require, Backbone, TreeLayoutView_tmpl, Utils, VCatalogList, CommonViewFunction, Messages) {
+    'utils/Messages',
+    'utils/UrlLinks'
+], function(require, Backbone, TreeLayoutView_tmpl, Utils, VCatalogList, CommonViewFunction, Messages, UrlLinks) {
     'use strict';
 
     var TreeLayoutView = Backbone.Marionette.LayoutView.extend(
@@ -251,7 +252,7 @@ define(['require',
                     if (parentURL) {
                         this.url = parentURL;
                     } else {
-                        this.url = "api/atlas/v1/taxonomies";
+                        this.url = UrlLinks.taxonomiesApiUrl();
                     }
                 }
                 this.showLoader();
@@ -308,7 +309,7 @@ define(['require',
                 var that = this;
                 _.each(this.taxanomy.models, function(model, key) {
                     var name = model.get('name');
-                    that.termCollection.url = "/api/atlas/v1/taxonomies/" + name + "/terms";
+                    that.termCollection.url = UrlLinks.taxonomiesTermsApiUrl(name)
                 });
                 this.termCollection.fetch({ reset: true });
             },
@@ -388,9 +389,9 @@ define(['require',
                         if (name.name) {
                               // data-name="<space>'<tagName>'"  Space is required for DSL search Input 
                             if (that.viewBased) {
-                                parentLi = '<div class="tools"><i class="fa fa-refresh fa-spin-custom taxanomyloader"></i><i class="fa fa-ellipsis-h termPopover"></i></div><i class="fa fa-angle-right toggleArrow" data-id="expandArrow" data-href="' + hrefUrl + '"></i><a href="javascript:void(0)" data-href="' + hrefUrl + '" data-name=" `' + model.get('name') + '`">' + name.name + '</a>';
+                                parentLi = '<div class="tools"><i class="fa fa-refresh fa-spin-custom taxanomyloader"></i><i class="fa fa-ellipsis-h termPopover"></i></div><i class="fa fa-angle-right toggleArrow" data-id="expandArrow" data-href="' + hrefUrl + '"></i><a href="javascript:void(0)" data-href="' + hrefUrl + '" data-name="`' + model.get('name') + '`">' + name.name + '</a>';
                             } else {
-                                parentLi = '<div class="tools"><i class="fa fa-refresh fa-spin-custom taxanomyloader"></i></div><i class="fa fa-angle-right toggleArrow" data-id="expandArrow" data-href="' + hrefUrl + '"></i><a href="javascript:void(0)" data-href="' + hrefUrl + '" data-name=" `' + model.get('name') + '`">' + name.name + '</a>';
+                                parentLi = '<div class="tools"><i class="fa fa-refresh fa-spin-custom taxanomyloader"></i></div><i class="fa fa-angle-right toggleArrow" data-id="expandArrow" data-href="' + hrefUrl + '"></i><a href="javascript:void(0)" data-href="' + hrefUrl + '" data-name="`' + model.get('name') + '`">' + name.name + '</a>';
                             }
                         }
                     });
@@ -613,7 +614,7 @@ define(['require',
                     'modules/Modal'
                 ], function(AddTermLayoutView, Modal) {
                     var view = new AddTermLayoutView({
-                        url: "/api/atlas/v1/taxonomies",
+                        url: UrlLinks.taxonomiesApiUrl(),
                         model: new that.parentCollection.model(),
                         defaultTerm:true
                     });

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/views/common/aboutAtlas.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/views/common/aboutAtlas.js b/dashboardv2/public/js/views/common/aboutAtlas.js
index 558841d..75b009c 100644
--- a/dashboardv2/public/js/views/common/aboutAtlas.js
+++ b/dashboardv2/public/js/views/common/aboutAtlas.js
@@ -19,8 +19,9 @@
 define(['require',
     'backbone',
     'hbs!tmpl/common/aboutAtlas_tmpl',
-    'models/VCommon'
-], function(require, Backbone, aboutAtlasTmpl, VCommon) {
+    'models/VCommon',
+    'utils/UrlLinks'
+], function(require, Backbone, aboutAtlasTmpl, VCommon, UrlLinks) {
     'use strict';
 
     var aboutAtlasView = Backbone.Marionette.LayoutView.extend(
@@ -48,7 +49,7 @@ define(['require',
             },
             onRender: function() {
                 var that = this;
-                var url = "/api/atlas/admin/version";
+                var url = UrlLinks.versionApiUrl();
                 var VCommonModel = new VCommon();
                 VCommonModel.aboutUs(url, {
                     success: function(data) {

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js b/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js
index 4706ba3..b2d2c7b 100644
--- a/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js
+++ b/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js
@@ -24,8 +24,10 @@ define(['require',
     'models/VEntity',
     'utils/CommonViewFunction',
     'utils/Globals',
-    'utils/Messages'
-], function(require, Backbone, DetailPageLayoutViewTmpl, Utils, VTagList, VEntity, CommonViewFunction, Globals, Messages) {
+    'utils/Enums',
+    'utils/Messages',
+    'utils/UrlLinks'
+], function(require, Backbone, DetailPageLayoutViewTmpl, Utils, VTagList, VEntity, CommonViewFunction, Globals, Enums, Messages, UrlLinks) {
     'use strict';
 
     var DetailPageLayoutView = Backbone.Marionette.LayoutView.extend(
@@ -73,15 +75,6 @@ define(['require',
             /** ui events hash */
             events: function() {
                 var events = {};
-                events["click " + this.ui.editButton] = function() {
-                    this.ui.editButton.hide();
-                    this.ui.description.hide();
-                    this.ui.editBox.show();
-                    this.ui.descriptionTextArea.focus();
-                    if (this.descriptionPresent) {
-                        this.ui.descriptionTextArea.val(this.ui.description.text());
-                    }
-                };
                 events["click " + this.ui.tagClick] = function(e) {
                     if (e.target.nodeName.toLocaleLowerCase() != "i") {
                         var scope = $(e.currentTarget);
@@ -89,7 +82,7 @@ define(['require',
                             var url = scope.data('href').split(".").join("/terms/");
                             Globals.saveApplicationState.tabState.stateChanged = false;
                             Utils.setUrl({
-                                url: '#!/taxonomy/detailCatalog/api/atlas/v1/taxonomies/' + url,
+                                url: '#!/taxonomy/detailCatalog' + UrlLinks.taxonomiesApiUrl() + '/' + url,
                                 mergeBrowserUrl: false,
                                 trigger: true
                             });
@@ -124,35 +117,37 @@ define(['require',
                 var that = this;
                 this.listenTo(this.collection, 'reset', function() {
 
-                    var collectionJSON = this.collection.toJSON();
-                    if (collectionJSON[0].id && collectionJSON[0].id.id) {
-                        var tagGuid = collectionJSON[0].id.id;
-                        this.readOnly = Globals.entityStateReadOnly[collectionJSON[0].id.state];
-                    }
-                    if (this.readOnly) {
-                        this.$el.addClass('readOnly');
+                    var collectionJSON = this.collection.first().toJSON();
+                    if (collectionJSON && collectionJSON.guid) {
+                        var tagGuid = collectionJSON.guid;
+                        //this.readOnly = Enums.entityStateReadOnly[collectionJSON[0].id.state];
                     } else {
-                        this.$el.removeClass('readOnly');
+                        var tagGuid = this.id;
                     }
-                    if (collectionJSON && collectionJSON.length) {
-                        if (collectionJSON[0].values) {
-                            if (collectionJSON[0].values.name) {
-                                this.name = collectionJSON[0].values.name;
+                    // if (this.readOnly) {
+                    //     this.$el.addClass('readOnly');
+                    // } else {
+                    //     this.$el.removeClass('readOnly');
+                    // }
+                    if (collectionJSON) {
+                        if (collectionJSON.attributes) {
+                            if (collectionJSON.attributes.name) {
+                                this.name = collectionJSON.attributes.name
                             }
-                            if (!this.name && collectionJSON[0].values.qualifiedName) {
-                                this.name = collectionJSON[0].values.qualifiedName;
+                            if (!this.name && collectionJSON.attributes.qualifiedName) {
+                                this.name = collectionJSON.attributes.qualifiedName;
                             }
-                            if (this.name && collectionJSON[0].typeName) {
-                                this.name = this.name + ' (' + collectionJSON[0].typeName + ')';
+                            if (this.name && collectionJSON.typeName) {
+                                this.name = this.name + ' (' + collectionJSON.typeName + ')';
                             }
-                            if (!this.name && collectionJSON[0].typeName) {
-                                this.name = collectionJSON[0].typeName;
+                            if (!this.name && collectionJSON.typeName) {
+                                this.name = collectionJSON.typeName;
                             }
 
                             if (!this.name && this.id) {
                                 this.name = this.id;
                             }
-                            this.description = collectionJSON[0].values.description;
+                            this.description = collectionJSON.attributes.description;
                             if (this.name) {
                                 this.ui.title.show();
                                 var titleName = '<span>' + this.name + '</span>';
@@ -170,22 +165,24 @@ define(['require',
                                 this.ui.description.hide();
                             }
                         }
-                        if (collectionJSON[0].traits) {
-                            this.addTagToTerms(collectionJSON[0].traits);
+                        if (collectionJSON.classifications) {
+                            this.addTagToTerms(collectionJSON.classifications);
+                        }else{
+                             this.addTagToTerms([]);
                         }
                     }
 
                     this.renderEntityDetailTableLayoutView();
                     this.renderTagTableLayoutView(tagGuid);
-                    this.renderLineageLayoutView(tagGuid);
-                    this.renderSchemaLayoutView(tagGuid);
-                    this.renderAuditTableLayoutView(tagGuid);
                     this.renderTermTableLayoutView(tagGuid);
                 }, this);
             },
             onRender: function() {
                 var that = this;
                 this.ui.editBox.hide();
+                this.renderLineageLayoutView(this.id);
+                this.renderSchemaLayoutView(this.id);
+                this.renderAuditTableLayoutView(this.id);
             },
             fetchCollection: function() {
                 this.collection.fetch({ reset: true });

http://git-wip-us.apache.org/repos/asf/incubator-atlas/blob/efc8d09c/dashboardv2/public/js/views/entity/EntityDetailTableLayoutView.js
----------------------------------------------------------------------
diff --git a/dashboardv2/public/js/views/entity/EntityDetailTableLayoutView.js b/dashboardv2/public/js/views/entity/EntityDetailTableLayoutView.js
index 316411d..4facf53 100644
--- a/dashboardv2/public/js/views/entity/EntityDetailTableLayoutView.js
+++ b/dashboardv2/public/js/views/entity/EntityDetailTableLayoutView.js
@@ -57,12 +57,14 @@ define(['require',
             },
             entityTableGenerate: function() {
                 var that = this,
-                    valueObject = this.collectionObject[0].values,
-                    valueSorted = _.sortBy(valueObject.columns, function(val) {
-                        return val.values.position
+                    attributeObject = this.collection.first().toJSON().attributes;
+                if (attributeObject) {
+                    var valueSorted = _.sortBy(attributeObject.columns, function(val) {
+                        return val.attributes.position
                     });
-                valueObject.columns = valueSorted;
-                var table = CommonViewFunction.propertyTable(valueObject, this);
+                }
+                attributeObject.columns = valueSorted;
+                var table = CommonViewFunction.propertyTable(attributeObject, this);
                 that.ui.detailValue.append(table);
             }
         });


Mime
View raw message