|
updateReport() {
let reportCollection: string[] = [];
let reeportList: string[] = [];
if (localStorage.pivotviewReports && localStorage.pivotviewReports !== '') {
reportCollection = JSON.parse(localStorage.pivotviewReports);
}
reportCollection.map(function(item: any): void {
reeportList.push(item.reportName);
});
// Here you can refresh the report list by feeding updated datsource fetched from your DB.
var reportListObj = (document.querySelector(
'#' + this.pivotObj.element.id + '_reportlist'
) as any).ej2_instances;
if (reportListObj) {
reportListObj[0].dataSource = reeportList;
reportListObj[0].value = (this.pivotObj.toolbarModule as any).currentReport;
}
}
|