I have an ICompany business object which contains a list of each of IStores and IOffices. The auto generated UI shows a Company containing tabs for the Stores and Offices lists, as required. I want another tab, which containing a MapControl which displays the Stores and Offices.
To that end, in DemoApp.Module.Win I have:
- created CompanyDashboardDetailView, which contains a MapControl.
- added a tab to ICompanyDetailView containing a CompanyDashboardViewItem (via MapDashboardViewItem)
- created MapDashboardViewController which attaches to CompanyDashboardDetailViews
- added code in that controller which adds the image tile layers, and attempts to add the offices/stores to the map
The problem is that I do not have access to the Company object - View.CurrentObject is null - see InitialiseMap() in MapDashboardViewController.
To begin with, I am not sure about the approach I have taken in 1-3, ieL whether I should be using a DashboardView.
Most importantly, how can I get access to the Company object and thus the Office and Store lists it contains?
Thanks