[Monitor Dashboard | Trunk]: Fix a bug when no category exists

git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-monitor-portal/trunk/monitor_dashboard@58908 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
Konstantinos Triantafyllou 2020-06-12 14:46:23 +00:00
parent 09b8683328
commit 2da590e0fc
1 changed files with 7 additions and 3 deletions

View File

@ -125,9 +125,13 @@ export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterV
this.filterCharts(); this.filterCharts();
this.filterNumbers(); this.filterNumbers();
} }
this.preview = '/' + this.stakeholder.alias + '/' + this.stakeholder.topics[this.topicIndex].alias + this.preview = '/' + this.stakeholder.alias + '/' + this.stakeholder.topics[this.topicIndex].alias;
'/' + this.stakeholder.topics[this.topicIndex].categories[this.categoryIndex].alias + if(this.stakeholder.topics[this.topicIndex].categories[this.categoryIndex]) {
'/' + this.stakeholder.topics[this.topicIndex].categories[this.categoryIndex].subCategories[this.subcategoryIndex].alias; this.preview += '/' + this.stakeholder.topics[this.topicIndex].categories[this.categoryIndex].alias;
if(this.stakeholder.topics[this.topicIndex].categories[this.categoryIndex].subCategories[this.subcategoryIndex]) {
this.preview += '/' + this.stakeholder.topics[this.topicIndex].categories[this.categoryIndex].subCategories[this.subcategoryIndex].alias;
}
}
} }
initReorder() { initReorder() {