Commit 234b3005 by kevalbhatt

ATLAS-2130 : Call made to fetch tables of a database doesn't have exlcudeDeletedEntities parameter

parent 6426e9df
......@@ -160,6 +160,7 @@ define([
'collection/VEntityList'
], function(Header, DetailPageLayoutView, SideNavLayoutView, VEntityList) {
this.entityCollection = new VEntityList([], {});
var paramObj = Utils.getUrlState.getQueryParams();
App.rNHeader.show(new Header());
if (!App.rSideNav.currentView) {
App.rSideNav.show(new SideNavLayoutView(
......@@ -171,6 +172,7 @@ define([
App.rNContent.show(new DetailPageLayoutView(_.extend({
'collection': this.entityCollection,
'id': id,
'value': paramObj
}, that.preFetchedCollectionLists, that.sharedObj)));
this.entityCollection.url = UrlLinks.entitiesApiUrl(id);
this.entityCollection.fetch({ reset: true });
......
......@@ -106,7 +106,7 @@ define(['require',
* @constructs
*/
initialize: function(options) {
_.extend(this, _.pick(options, 'collection', 'id', 'entityDefCollection', 'typeHeaders', 'enumDefCollection', 'classificationDefCollection'));
_.extend(this, _.pick(options, 'value', 'collection', 'id', 'entityDefCollection', 'typeHeaders', 'enumDefCollection', 'classificationDefCollection'));
this.bindEvents();
},
bindEvents: function() {
......@@ -200,7 +200,8 @@ define(['require',
this.renderProfileLayoutView(_.extend({}, obj, {
entityDetail: collectionJSON.attributes,
profileData: collectionJSON.attributes.profileData,
typeName: collectionJSON.typeName
typeName: collectionJSON.typeName,
value: that.value
}));
}
......
......@@ -57,7 +57,7 @@ define(['require',
* @constructs
*/
initialize: function(options) {
_.extend(this, _.pick(options, 'profileData', 'guid', 'typeName', 'entityDetail', 'typeHeaders', 'entityDefCollection', 'enumDefCollection', 'classificationDefCollection'));
_.extend(this, _.pick(options, 'profileData', 'guid', 'value', 'typeName', 'entityDetail', 'typeHeaders', 'entityDefCollection', 'enumDefCollection', 'classificationDefCollection'));
if (this.typeName === "hive_db") {
this.profileData = { attributes: true };
}
......@@ -73,16 +73,15 @@ define(['require',
this.renderProfileColumnLayoutView();
}
}
},
renderSearchResultLayoutView: function() {
var that = this;
require(['views/search/SearchResultLayoutView'], function(SearchResultLayoutView) {
var value = {
var value = _.extend({}, that.value, {
'guid': that.guid,
'searchType': 'relationship',
'profileDBView': true
};
});
that.RProfileTableOrColumnLayoutView.show(new SearchResultLayoutView({
'value': value,
'typeHeaders': that.typeHeaders,
......
......@@ -406,7 +406,7 @@ define(['require',
}
if (isPostMethod) {
that.searchCollection.referredEntities = dataOrCollection.rnoRecordFoeferredEntities;
that.searchCollection.reset(dataOrCollection.entities);
that.searchCollection.reset(dataOrCollection.entities, { silent: true });
}
/*Next button check.
......@@ -480,6 +480,9 @@ define(['require',
} else {
apiObj.data = null;
this.searchCollection.filterObj = null;
if (this.value.profileDBView) {
_.extend(this.searchCollection.queryParams, { 'excludeDeletedEntities': (this.value && this.value.includeDE ? false : true) });
}
Globals.searchApiCallRef = this.searchCollection.fetch(apiObj);
}
} else {
......@@ -490,6 +493,9 @@ define(['require',
Globals.searchApiCallRef = this.searchCollection.getBasicRearchResult(apiObj);
} else {
apiObj.data = null;
if (this.value.profileDBView) {
_.extend(this.searchCollection.queryParams, { 'excludeDeletedEntities': (this.value && this.value.includeDE ? false : true) });
}
Globals.searchApiCallRef = this.searchCollection.fetch(apiObj);
}
}
......
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