diff --git a/Mohem/src/app/eit/eit-update-list/eit-update-list.component.ts b/Mohem/src/app/eit/eit-update-list/eit-update-list.component.ts index b952ba64..1f896919 100644 --- a/Mohem/src/app/eit/eit-update-list/eit-update-list.component.ts +++ b/Mohem/src/app/eit/eit-update-list/eit-update-list.component.ts @@ -6,6 +6,7 @@ import { CommonService } from 'src/app/hmg-common/services/common/common.service import { EITNotificatonBodyResponse } from '../models/EITNotificationBodyRes'; import { EitService } from '../services/eit.service'; import { TranslatorService } from "src/app/hmg-common/services/translator/translator.service"; +import { MenuResponse } from 'src/app/hmg-common/services/menu/models/menu-response'; @Component({ selector: 'app-eit-update-list', @@ -29,6 +30,15 @@ export class EitUpdateListComponent implements OnInit { constructor(public cs: CommonService, public eitService: EitService, public modalController: ModalController, private ts: TranslatorService) { this.notificationBodyRes = this.cs.sharedService.getSharedData(EITNotificatonBodyResponse.SHARED_DATA, false); let notification = this.cs.sharedService.getSharedData(EITNotificatonBodyResponse.NOT_WORKLIST, false); + ///////// MOE RESUBIT FIX /////////////// + let selMenu: MenuResponse = new MenuResponse(); + selMenu = this.cs.sharedService.getSharedData( + MenuResponse.SHARED_DATA, + false + ); + selMenu.GetMenuEntriesList = notification; + this.cs.sharedService.setSharedData(selMenu, MenuResponse.SHARED_DATA); + this.itemKey = notification.ITEM_KEY; this.notificationId = notification.NOTIFICATION_ID; this.functionName = notification.FUNCTION_NAME; diff --git a/Mohem/src/app/hmg-common/services/common/common.service.ts b/Mohem/src/app/hmg-common/services/common/common.service.ts index c2af3db0..63946a6c 100644 --- a/Mohem/src/app/hmg-common/services/common/common.service.ts +++ b/Mohem/src/app/hmg-common/services/common/common.service.ts @@ -1525,7 +1525,10 @@ export class CommonService { node = list[i]; if (node.PARENT_MENU_NAME !== '') { // this node is child // if you have dangling branches check that map[node.parentId] exists - list[map[node.PARENT_MENU_NAME]].children.push(node); + try { + list[map[node.PARENT_MENU_NAME]].children.push(node); + } catch {} + } else { roots.push(node); // this node itself is parent }