Commit 63a0be26 by kevalbhatt Committed by Madhan Neethiraj

ATLAS-2699: updated UI to use V2 audit API

parent 9044e037
...@@ -25,12 +25,12 @@ define(['require'], function(require) { ...@@ -25,12 +25,12 @@ define(['require'], function(require) {
ENTITY_CREATE: "Entity Created", ENTITY_CREATE: "Entity Created",
ENTITY_UPDATE: "Entity Updated", ENTITY_UPDATE: "Entity Updated",
ENTITY_DELETE: "Entity Deleted", ENTITY_DELETE: "Entity Deleted",
TAG_ADD: "Classification Added", CLASSIFICATION_ADD: "Classification Added",
TAG_DELETE: "Classification Deleted", CLASSIFICATION_DELETE: "Classification Deleted",
TAG_UPDATE: "Classification Updated", CLASSIFICATION_UPDATE: "Classification Updated",
PROPAGATED_TAG_ADD: "Propagated Classification Added", PROPAGATED_CLASSIFICATION_ADD: "Propagated Classification Added",
PROPAGATED_TAG_DELETE: "Propagated Classification Deleted", PROPAGATED_CLASSIFICATION_DELETE: "Propagated Classification Deleted",
PROPAGATED_TAG_UPDATE: "Propagated Classification Updated", PROPAGATED_CLASSIFICATION_UPDATE: "Propagated Classification Updated",
ENTITY_IMPORT_CREATE: "Entity Created by import", ENTITY_IMPORT_CREATE: "Entity Created by import",
ENTITY_IMPORT_UPDATE: "Entity Updated by import", ENTITY_IMPORT_UPDATE: "Entity Updated by import",
ENTITY_IMPORT_DELETE: "Entity Deleted by import" ENTITY_IMPORT_DELETE: "Entity Deleted by import"
......
...@@ -67,7 +67,7 @@ define(['require', 'utils/Enums', 'utils/Utils', 'underscore'], function(require ...@@ -67,7 +67,7 @@ define(['require', 'utils/Enums', 'utils/Utils', 'underscore'], function(require
} }
}, },
entityCollectionaudit: function(guid) { entityCollectionaudit: function(guid) {
return this.baseUrl + '/entities/' + guid + '/audit'; return this.baseUrlV2 + '/entity/' + guid + '/audit';
}, },
classicationApiUrl: function(name, guid) { classicationApiUrl: function(name, guid) {
var typeUrl = this.typedefsUrl(); var typeUrl = this.typedefsUrl();
......
...@@ -79,12 +79,11 @@ define(['require', ...@@ -79,12 +79,11 @@ define(['require',
var name = _.escape(parseDetailsObject[0]); var name = _.escape(parseDetailsObject[0]);
} }
} }
var values = parseDetailsObject.values;
var name = ((name ? name : this.entityName)); var name = ((name ? name : this.entityName));
this.ui.name.text(name); this.ui.name.text(name);
if (parseDetailsObject && parseDetailsObject.values) { if (parseDetailsObject) {
this.ui.auditHeaderValue.html('<th>Key</th><th>New Value</th>'); this.ui.auditHeaderValue.html('<th>Key</th><th>New Value</th>');
table = CommonViewFunction.propertyTable({ scope: this, valueObject: values, attributeDefs: this.attributeDefs, extractJSON: { extractKey: 'value' } }); table = CommonViewFunction.propertyTable({ scope: this, valueObject: parseDetailsObject, attributeDefs: this.attributeDefs, extractJSON: { extractKey: 'value' } });
if (table.length) { if (table.length) {
this.ui.noData.hide(); this.ui.noData.hide();
this.ui.tableAudit.show(); this.ui.tableAudit.show();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment