Commit f1071310 by kevalbhatt Committed by nixonrodrigues

ATLAS-3127: UI : On Load Graph zoom buttons (+/-) is visible on top of relationship Table.

parent c477a6f6
......@@ -104,6 +104,12 @@
}
}
.invisible {
.node circle {
transition: all 0s;
}
}
.edgePath {
.path {
cursor: pointer;
......
......@@ -16,6 +16,14 @@
* limitations under the License.
*/
tr.empty {
td {
display: table-cell;
text-align: center;
}
}
.stat-table {
tbody,
......
......@@ -75,14 +75,14 @@ define([
var that = this;
$('body').on('click', 'a.show-stat', function() {
require([
'views/common/Statistics',
'views/site/Statistics',
], function(Statistics) {
new Statistics();
});
});
$('body').on('click', 'li.aboutAtlas', function() {
require([
'views/common/AboutAtlas',
'views/site/AboutAtlas',
], function(AboutAtlas) {
new AboutAtlas();
});
......
......@@ -14,7 +14,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
-->
<!-- <div class="graph-toolbar clearfix"></div> -->
<div class="graph-button-group form-group clearfix">
<div class="btn-group pull-left">
<span class="pull-left">Graph</span>
......@@ -46,14 +45,6 @@
</div>
</div>
</div>
<!-- <div class="relationship-details">
<span data-id="close" style="margin: 7px;position: absolute;right: 0" class="btn btn-action btn-sm fltr-togler"><i class="fa fa-close"></i></span>
<h4 class="title"><span data-id="typeName"></span></h4>
<div class="col-md-12">
<input data-id="searchNode" class="form-control form-group" placeholder="Search Entities" />
<ul data-id="entityList" class="entity-list"></ul>
</div>
</div> -->
</div>
<div>
<table class="table table-quickMenu" data-id="relationshipDetailTable">
......
......@@ -272,7 +272,7 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Enum
}
});
return table;
return table && table.length > 0 ? table : '<tr class="empty"><td colspan="22"><span>No Record found!</span></td></tr>';
}
CommonViewFunction.tagForTable = function(obj) {
var traits = obj.classifications,
......@@ -324,7 +324,7 @@ define(['require', 'utils/Utils', 'modules/Modal', 'utils/Messages', 'utils/Enum
terms.map(function(term) {
var className = "btn btn-action btn-sm btn-blue btn-icon",
deleteIcon = '<i class="fa fa-times" data-id="delete" data-assetname="' + entityName + '"data-name="' + term.displayText + '" data-type="term" data-guid="' + obj.guid + '" data-termGuid="' + term.termGuid + '" ></i>',
termString = '<a class="' + className + '" data-id="termClick"><span title="' + term.displayText + '">' + term.displayText + '</span>' + deleteIcon + '</a>';
termString = '<a class="' + className + '" data-id="termClick"><span title="' + _.escape(term.displayText) + '">' + _.escape(term.displayText) + '</span>' + deleteIcon + '</a>';
if (count >= 1) {
popTerm += termString;
} else {
......
......@@ -416,7 +416,7 @@ define(['require',
termData = "";
_.each(data, function(val) {
if (val.relationshipStatus == "ACTIVE") {
termData += '<span class="btn btn-action btn-sm btn-icon btn-blue" title=' + val.displayText + ' data-id="termClick"><span>' + val.displayText + '</span><i class="fa fa-close" data-id="deleteTerm" data-guid="' + val.guid + '" data-type="term" title="Remove Term"></i></span>';
termData += '<span class="btn btn-action btn-sm btn-icon btn-blue" title=' + _.escape(val.displayText) + ' data-id="termClick"><span>' + _.escape(val.displayText) + '</span><i class="fa fa-close" data-id="deleteTerm" data-guid="' + val.guid + '" data-type="term" title="Remove Term"></i></span>';
}
});
this.ui.termList.find("span.btn").remove();
......
......@@ -96,6 +96,7 @@ define(['require',
return { nodes: nodes, links: links };
},
onRender: function() {
this.ui.zoomControl.hide();
this.$el.addClass('auto-height');
},
onShow: function(argument) {
......@@ -103,8 +104,8 @@ define(['require',
this.noRelationship();
} else {
this.createGraph(this.graphData);
this.createTable();
}
this.createTable();
},
noRelationship: function() {
this.$('svg').html('<text x="50%" y="50%" alignment-baseline="middle" text-anchor="middle">No relationship data found</text>');
......
......@@ -85,8 +85,8 @@ define(['require',
getObjDef: function(attrObj, rules) {
var obj = {
id: attrObj.name,
label: attrObj.name.capitalize() + " (" + attrObj.typeName + ")",
type: attrObj.typeName
label: _.escape(attrObj.name.capitalize() + " (" + attrObj.typeName + ")"),
type: _.escape(attrObj.typeName)
};
if (obj.type === "date") {
obj['plugin'] = 'daterangepicker';
......@@ -158,7 +158,7 @@ define(['require',
filters: filters,
select_placeholder: '--Select Attribute--',
allow_empty: true,
conditions: ['AND','OR'],
conditions: ['AND', 'OR'],
allow_groups: true,
allow_empty: true,
operators: [
......
......@@ -128,7 +128,7 @@ define(['require',
obj.name = selectedEl.find('a').text();
obj.guid = selectedEl.data('id');
if (selectedEl && selectedEl.length) {
notifyObj['text'] = Messages.search.favoriteSearch.save + " <b>" + obj.name + "</b> ?";
notifyObj['text'] = Messages.search.favoriteSearch.save + " <b>" + _.escape(obj.name) + "</b> ?";
Utils.notifyConfirm(notifyObj);
} else {
Utils.notifyInfo({
......@@ -176,7 +176,7 @@ define(['require',
var notifyObj = {
modal: true,
html: true,
text: Messages.conformation.deleteMessage + "<b>" + options.model.get('name') + "</b>" + " ?",
text: Messages.conformation.deleteMessage + "<b>" + _.escape(options.model.get('name')) + "</b>" + " ?",
ok: function(argument) {
that.onDeleteNotifyOk(options);
},
......
......@@ -18,7 +18,7 @@
define(['require',
'backbone',
'hbs!tmpl/common/AboutAtlas_tmpl',
'hbs!tmpl/site/AboutAtlas_tmpl',
'modules/Modal',
'models/VCommon',
'utils/UrlLinks',
......
......@@ -18,7 +18,7 @@
define(['require',
'backbone',
'hbs!tmpl/common/Statistics_tmpl',
'hbs!tmpl/site/Statistics_tmpl',
'modules/Modal',
'models/VCommon',
'utils/UrlLinks',
......
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