Repository: atlas Updated Branches: refs/heads/branch-0.8 356160505 -> 4850ece40
ATLAS-2194 : In Basic Search for Tag if any columns are removed then UI throws exception Signed-off-by: Madhan Neethiraj <[email protected]> (cherry picked from commit e406603a1612eb09806ee1a643032baff465f1bc) Project: http://git-wip-us.apache.org/repos/asf/atlas/repo Commit: http://git-wip-us.apache.org/repos/asf/atlas/commit/017c4121 Tree: http://git-wip-us.apache.org/repos/asf/atlas/tree/017c4121 Diff: http://git-wip-us.apache.org/repos/asf/atlas/diff/017c4121 Branch: refs/heads/branch-0.8 Commit: 017c412100563439bab05a576305f5927057525b Parents: 3561605 Author: kevalbhatt <[email protected]> Authored: Mon Oct 9 19:27:48 2017 +0530 Committer: Madhan Neethiraj <[email protected]> Committed: Mon Oct 9 09:52:07 2017 -0700 ---------------------------------------------------------------------- dashboardv2/public/js/views/search/SearchResultLayoutView.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/atlas/blob/017c4121/dashboardv2/public/js/views/search/SearchResultLayoutView.js ---------------------------------------------------------------------- diff --git a/dashboardv2/public/js/views/search/SearchResultLayoutView.js b/dashboardv2/public/js/views/search/SearchResultLayoutView.js index dda0f6f..7dd84b6 100644 --- a/dashboardv2/public/js/views/search/SearchResultLayoutView.js +++ b/dashboardv2/public/js/views/search/SearchResultLayoutView.js @@ -240,10 +240,10 @@ define(['require', } } this.triggerUrl(); - if (excludeDefaultColumn.length > this.searchCollection.filterObj.attributes.length) { + var attributes = this.searchCollection.filterObj.attributes; + if (excludeDefaultColumn && attributes && excludeDefaultColumn.length > attributes.length) { this.fetchCollection(this.value); } - } }, this); this.listenTo(this.searchVent, "search:refresh", function(model, response) { @@ -452,7 +452,7 @@ define(['require', that.ui.activePage.text(that.activePage); that.renderTableLayoutView(); - if (value && !value.profileDBView) { + if (Utils.getUrlState.isSearchTab() && value && !value.profileDBView) { var searchString = 'Results for: <span class="filterQuery">' + CommonViewFunction.generateQueryOfFilter(that.value) + "</span>"; if (Globals.entityCreate && Globals.entityTypeConfList && Utils.getUrlState.isSearchTab()) { searchString += "<p>If you do not find the entity in search result below then you can" + '<a href="javascript:void(0)" data-id="createEntity"> create new entity</a></p>';
