This is an automated email from the ASF dual-hosted git repository.
kbhatt pushed a commit to branch branch-2.0
in repository https://gitbox.apache.org/repos/asf/atlas.git
The following commit(s) were added to refs/heads/branch-2.0 by this push:
new 65f1a2b ATLAS-3904: Regression: Glossary term deatils page not able
to render the classfication tab #2
65f1a2b is described below
commit 65f1a2bc82779d1371f1cdffb8399893a36c9e7d
Author: kevalbhatt <[email protected]>
AuthorDate: Mon Aug 3 16:28:00 2020 +0530
ATLAS-3904: Regression: Glossary term deatils page not able to render the
classfication tab #2
(cherry picked from commit ce2ba123a2b9ce43503d5e101400b93fa5b6267e)
---
.../public/js/views/detail_page/DetailPageLayoutView.js | 15 +++++++++++----
.../public/js/views/detail_page/DetailPageLayoutView.js | 15 +++++++++++----
2 files changed, 22 insertions(+), 8 deletions(-)
diff --git a/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js
b/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js
index 7f8d849..4df3562 100644
--- a/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js
+++ b/dashboardv2/public/js/views/detail_page/DetailPageLayoutView.js
@@ -381,19 +381,26 @@ define(['require',
this.$('.fontLoader-relative').addClass('show'); // to show
tab loader
},
manualRender: function(options) {
- if (this.id !== options.id) {
+ if (options) {
+ var oldId = this.id;
_.extend(this, _.pick(options, 'value', 'id'));
- this.collection.url = UrlLinks.entitiesApiUrl({ guid:
this.id, minExtInfo: true });
- this.fetchCollection();
+ if (this.id !== oldId) {
+ this.collection.url = UrlLinks.entitiesApiUrl({ guid:
this.id, minExtInfo: true });
+ this.fetchCollection();
+ }
+ this.updateTab();
}
},
- onShow: function() {
+ updateTab: function() {
if (this.value && this.value.tabActive) {
this.$('.nav.nav-tabs').find('[role="' +
this.value.tabActive +
'"]').addClass('active').siblings().removeClass('active');
this.$('.tab-content').find('[role="' +
this.value.tabActive +
'"]').addClass('active').siblings().removeClass('active');
$("html, body").animate({ scrollTop:
(this.$('.tab-content').offset().top + 1200) }, 1000);
}
},
+ onShow: function() {
+ this.updateTab();
+ },
onDestroy: function() {
if (!Utils.getUrlState.isDetailPage()) {
$('body').removeClass("detail-page");
diff --git a/dashboardv3/public/js/views/detail_page/DetailPageLayoutView.js
b/dashboardv3/public/js/views/detail_page/DetailPageLayoutView.js
index 2a95974..7e140b8 100644
--- a/dashboardv3/public/js/views/detail_page/DetailPageLayoutView.js
+++ b/dashboardv3/public/js/views/detail_page/DetailPageLayoutView.js
@@ -385,19 +385,26 @@ define(['require',
this.$('.fontLoader-relative').addClass('show'); // to show
tab loader
},
manualRender: function(options) {
- if (this.id !== options.id) {
+ if (options) {
+ var oldId = this.id;
_.extend(this, _.pick(options, 'value', 'id'));
- this.collection.url = UrlLinks.entitiesApiUrl({ guid:
this.id, minExtInfo: true });
- this.fetchCollection();
+ if (this.id !== oldId) {
+ this.collection.url = UrlLinks.entitiesApiUrl({ guid:
this.id, minExtInfo: true });
+ this.fetchCollection();
+ }
+ this.updateTab();
}
},
- onShow: function() {
+ updateTab: function() {
if (this.value && this.value.tabActive) {
this.$('.nav.nav-tabs').find('[role="' +
this.value.tabActive +
'"]').addClass('active').siblings().removeClass('active');
this.$('.tab-content').find('[role="' +
this.value.tabActive +
'"]').addClass('active').siblings().removeClass('active');
$("html, body").animate({ scrollTop:
(this.$('.tab-content').offset().top + 1200) }, 1000);
}
},
+ onShow: function() {
+ this.updateTab();
+ },
onDestroy: function() {
if (!Utils.getUrlState.isDetailPage()) {
$('body').removeClass("detail-page");