public void ProcessAction(ApplicationStartAction eventObject) { var result = new NavigationItemViewModel(); this.eventBroker.Publish(new ApplicationLoadedEvent(0, 2, "Loading catalogs..."), Topics.UI); var catalogs = this.catalogRepository.FindAll(); Mapper.CreateMap<SupplierCatalog, CatalogItemViewModel>(); result.Catalogs = Mapper.Map<IList<SupplierCatalog>, CatalogItemViewModel[]>(catalogs); this.eventBroker.Publish(new ApplicationLoadedEvent(1, 2, "Loading deals..."), Topics.UI); var deals = this.dealRepository.FindAll(); Mapper.CreateMap<Deal, DealItemViewModel>(); Mapper.CreateMap<Project, ProjectItemViewModel>(); result.Deals = Mapper.Map<IList<Deal>, DealItemViewModel[]>(deals); this.eventBroker.Publish(new ApplicationLoadedEvent(2, 2, "Application loaded"), Topics.UI); this.navigationView.Display(result); this.navigationView.ShowView(); }
public void ProcessAction(ApplicationStartAction eventObject) { this.dealView.HideView(); }