I have a VM (CompanyViewModel.cs) which is derived from BaseViewModel. I want to use the DataForm to display a CompanyViewModel but when I do it the properties of BaseViewModel are also displayed (RegisteredViews, GoToVisualState, EventAggregator,
Router and Logger). What would be the best way to fix this?
I could modify BaseViewModel and add [Display(AutoGenerateField=false)] to each property but that adds a dependency on System.ComponentModel.DataAnnotations to Jounce.Core and also puts me out of step with any Jounce releases.
Is there some way to use the MetadataType attribute together with a specific metadata class to hide the BaseViewModel properties from the DataForm?
I could create another class, CompanyDisplayViewModel, and put all the editable fields in there and just have an instance of that class within CompanyViewModel. This is doable but doesn't feel like the right approach.
I'm hoping that there is some way to tell DataAnnotations to ignore properties of a base class.
I realise that this is not, strictly, a Jounce problem but thought someone may have run in to this issue when using Jounce in the past.