Commit 2f766f5c by kevalbhatt

ATLAS-3943: UI: Show Import/Export operations in administration audit.

parent 24bb6b08
...@@ -137,6 +137,10 @@ ...@@ -137,6 +137,10 @@
overflow: auto; overflow: auto;
} }
.admin-details .attributeResultContainer {
float: left;
}
.tab-pane { .tab-pane {
.business-metadata-attr-page { .business-metadata-attr-page {
position: absolute; position: absolute;
......
...@@ -481,6 +481,10 @@ div.columnmanager-dropdown-container { ...@@ -481,6 +481,10 @@ div.columnmanager-dropdown-container {
font-size: large; font-size: large;
font-weight: bold; font-weight: bold;
} }
.noToggle {
color: $gray;
}
} }
.backgrid-internal-table { .backgrid-internal-table {
......
...@@ -44,7 +44,15 @@ define(["require", "backbone"], function(require) { ...@@ -44,7 +44,15 @@ define(["require", "backbone"], function(require) {
BUSINESS_ATTRIBUTE_DELETE: "Business Attribute(s) Deleted", BUSINESS_ATTRIBUTE_DELETE: "Business Attribute(s) Deleted",
TYPE_DEF_UPDATE: "Type Updated", TYPE_DEF_UPDATE: "Type Updated",
TYPE_DEF_CREATE: "Type Created", TYPE_DEF_CREATE: "Type Created",
TYPE_DEF_DELETE: "Type Deleted" TYPE_DEF_DELETE: "Type Deleted",
IMPORT: "Import",
EXPORT: "Export"
}
Enums.serverAudits = {
SERVER_START: "Server Start",
SERVER_STOP: "Server End",
SERVER_STATE_ACTIVE: "Server State Active",
SERVER_STATE_PASSIVE: "Server Statae Passive"
} }
Enums.category = { Enums.category = {
...@@ -58,7 +66,9 @@ define(["require", "backbone"], function(require) { ...@@ -58,7 +66,9 @@ define(["require", "backbone"], function(require) {
MAP: "Map", MAP: "Map",
RELATIONSHIP: "Relationship", RELATIONSHIP: "Relationship",
BUSINESS_METADATA: "Business Metadata", BUSINESS_METADATA: "Business Metadata",
PURGE: "Purge Entities" PURGE: "Purge Entities",
IMPORT: "Import Entities",
EXPORT: "Export Entities"
} }
Enums.entityStateReadOnly = { Enums.entityStateReadOnly = {
...@@ -261,7 +271,7 @@ define(["require", "backbone"], function(require) { ...@@ -261,7 +271,7 @@ define(["require", "backbone"], function(require) {
"This Month": "THIS_MONTH", "This Month": "THIS_MONTH",
"Last Month": "LAST_MONTH", "Last Month": "LAST_MONTH",
"This Quarter": "THIS_QUARTER", "This Quarter": "THIS_QUARTER",
"Last Quarter":"LAST_QUARTER", "Last Quarter": "LAST_QUARTER",
"This Year": "THIS_YEAR", "This Year": "THIS_YEAR",
"Last Year": "LAST_YEAR", "Last Year": "LAST_YEAR",
"Last 3 Months": "LAST_3_MONTHS", "Last 3 Months": "LAST_3_MONTHS",
......
...@@ -211,8 +211,12 @@ define(['require', 'utils/Utils', 'lossless-json', 'marionette', 'backgrid', 'as ...@@ -211,8 +211,12 @@ define(['require', 'utils/Utils', 'lossless-json', 'marionette', 'backgrid', 'as
render: function() { render: function() {
/* follow along with the original render really... */ /* follow along with the original render really... */
this.$el.empty(); this.$el.empty();
var isExpand = true;
if (this.column.get('isExpandVisible')) {
isExpand = this.column.get('isExpandVisible')(this.$el, this.model);
}
this.$toggleEl = $(this.toggle).addClass(this.toggleClass).addClass(this.toggleCollapsedClass); this.$toggleEl = $(this.toggle).addClass(this.toggleClass).addClass(this.toggleCollapsedClass);
this.$toggleEl = isExpand ? this.$toggleEl : this.$toggleEl.addClass("noToggle");
this.$el.append(this.$toggleEl); this.$el.append(this.$toggleEl);
...@@ -224,6 +228,10 @@ define(['require', 'utils/Utils', 'lossless-json', 'marionette', 'backgrid', 'as ...@@ -224,6 +228,10 @@ define(['require', 'utils/Utils', 'lossless-json', 'marionette', 'backgrid', 'as
setToggle: function() { setToggle: function() {
var detailsRow = this.$el.data('details'); var detailsRow = this.$el.data('details');
var toggle = this.$toggleEl; var toggle = this.$toggleEl;
/* if there's details data is not there/undefined and $toggleEl having noToggle class, no need to expand */
if (!detailsRow && this.$toggleEl.hasClass('noToggle')) {
return false;
}
/* if there's details data already stored, then we'll remove it */ /* if there's details data already stored, then we'll remove it */
if (detailsRow) { if (detailsRow) {
......
...@@ -192,7 +192,6 @@ define(['require', ...@@ -192,7 +192,6 @@ define(['require',
require([ require([
'views/audit/CreateAuditTableLayoutView', 'views/audit/CreateAuditTableLayoutView',
], function(CreateAuditTableLayoutView) { ], function(CreateAuditTableLayoutView) {
that.action = model.get('action'); that.action = model.get('action');
// $(el.target).attr('disabled', true); // $(el.target).attr('disabled', true);
var eventModel = that.entityCollection.fullCollection.findWhere({ 'eventKey': model.get('eventKey') }).toJSON(), var eventModel = that.entityCollection.fullCollection.findWhere({ 'eventKey': model.get('eventKey') }).toJSON(),
......
...@@ -137,6 +137,10 @@ ...@@ -137,6 +137,10 @@
overflow: auto; overflow: auto;
} }
.admin-details .attributeResultContainer {
float: left;
}
.tab-pane { .tab-pane {
.business-metadata-attr-page { .business-metadata-attr-page {
position: absolute; position: absolute;
......
...@@ -485,6 +485,10 @@ div.columnmanager-dropdown-container { ...@@ -485,6 +485,10 @@ div.columnmanager-dropdown-container {
font-size: large; font-size: large;
font-weight: bold; font-weight: bold;
} }
.noToggle {
color: $gray;
}
} }
.backgrid-internal-table { .backgrid-internal-table {
......
...@@ -44,7 +44,15 @@ define(["require", "backbone"], function(require) { ...@@ -44,7 +44,15 @@ define(["require", "backbone"], function(require) {
BUSINESS_ATTRIBUTE_DELETE: "Business Attribute(s) Deleted", BUSINESS_ATTRIBUTE_DELETE: "Business Attribute(s) Deleted",
TYPE_DEF_UPDATE: "Type Updated", TYPE_DEF_UPDATE: "Type Updated",
TYPE_DEF_CREATE: "Type Created", TYPE_DEF_CREATE: "Type Created",
TYPE_DEF_DELETE: "Type Deleted" TYPE_DEF_DELETE: "Type Deleted",
IMPORT: "Import",
EXPORT: "Export"
}
Enums.serverAudits = {
SERVER_START: "Server Start",
SERVER_STOP: "Server End",
SERVER_STATE_ACTIVE: "Server State Active",
SERVER_STATE_PASSIVE: "Server Statae Passive"
} }
Enums.category = { Enums.category = {
...@@ -58,7 +66,9 @@ define(["require", "backbone"], function(require) { ...@@ -58,7 +66,9 @@ define(["require", "backbone"], function(require) {
MAP: "Map", MAP: "Map",
RELATIONSHIP: "Relationship", RELATIONSHIP: "Relationship",
BUSINESS_METADATA: "Business Metadata", BUSINESS_METADATA: "Business Metadata",
PURGE: "Purge Entities" PURGE: "Purge Entities",
IMPORT: "Import Entities",
EXPORT: "Export Entities"
} }
Enums.entityStateReadOnly = { Enums.entityStateReadOnly = {
...@@ -261,7 +271,7 @@ define(["require", "backbone"], function(require) { ...@@ -261,7 +271,7 @@ define(["require", "backbone"], function(require) {
"This Month": "THIS_MONTH", "This Month": "THIS_MONTH",
"Last Month": "LAST_MONTH", "Last Month": "LAST_MONTH",
"This Quarter": "THIS_QUARTER", "This Quarter": "THIS_QUARTER",
"Last Quarter":"LAST_QUARTER", "Last Quarter": "LAST_QUARTER",
"This Year": "THIS_YEAR", "This Year": "THIS_YEAR",
"Last Year": "LAST_YEAR", "Last Year": "LAST_YEAR",
"Last 3 Months": "LAST_3_MONTHS", "Last 3 Months": "LAST_3_MONTHS",
......
...@@ -211,8 +211,12 @@ define(['require', 'utils/Utils', 'lossless-json', 'marionette', 'backgrid', 'as ...@@ -211,8 +211,12 @@ define(['require', 'utils/Utils', 'lossless-json', 'marionette', 'backgrid', 'as
render: function() { render: function() {
/* follow along with the original render really... */ /* follow along with the original render really... */
this.$el.empty(); this.$el.empty();
var isExpand = true;
if (this.column.get('isExpandVisible')) {
isExpand = this.column.get('isExpandVisible')(this.$el, this.model);
}
this.$toggleEl = $(this.toggle).addClass(this.toggleClass).addClass(this.toggleCollapsedClass); this.$toggleEl = $(this.toggle).addClass(this.toggleClass).addClass(this.toggleCollapsedClass);
this.$toggleEl = isExpand ? this.$toggleEl : this.$toggleEl.addClass("noToggle");
this.$el.append(this.$toggleEl); this.$el.append(this.$toggleEl);
...@@ -224,6 +228,10 @@ define(['require', 'utils/Utils', 'lossless-json', 'marionette', 'backgrid', 'as ...@@ -224,6 +228,10 @@ define(['require', 'utils/Utils', 'lossless-json', 'marionette', 'backgrid', 'as
setToggle: function() { setToggle: function() {
var detailsRow = this.$el.data('details'); var detailsRow = this.$el.data('details');
var toggle = this.$toggleEl; var toggle = this.$toggleEl;
/* if there's details data is not there/undefined and $toggleEl having noToggle class, no need to expand */
if (!detailsRow && this.$toggleEl.hasClass('noToggle')) {
return false;
}
/* if there's details data already stored, then we'll remove it */ /* if there's details data already stored, then we'll remove it */
if (detailsRow) { if (detailsRow) {
......
...@@ -192,7 +192,6 @@ define(['require', ...@@ -192,7 +192,6 @@ define(['require',
require([ require([
'views/audit/CreateAuditTableLayoutView', 'views/audit/CreateAuditTableLayoutView',
], function(CreateAuditTableLayoutView) { ], function(CreateAuditTableLayoutView) {
that.action = model.get('action'); that.action = model.get('action');
// $(el.target).attr('disabled', true); // $(el.target).attr('disabled', true);
var eventModel = that.entityCollection.fullCollection.findWhere({ 'eventKey': model.get('eventKey') }).toJSON(), var eventModel = that.entityCollection.fullCollection.findWhere({ 'eventKey': model.get('eventKey') }).toJSON(),
......
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