Skip to content

ModelViewInheritance

Apostolis Bekiaris edited this page Jul 26, 2019 · 29 revisions

GitHub issues GitHub close issues

About

The ModuleViewInheritance module replaces the generator layer of a view by composing multiple unrelated view model differences.

Installation

  1. First you need the nuget package so issue this command to the VS Nuget package console

    Install-Package Xpand.XAF.Modules.ModelViewInheritance.

    The above only references the dependencies and nexts steps are mandatory.

  2. Ways to Register a Module or simply add the next call to your module constructor

    RequiredModuleTypes.Add(typeof(Xpand.XAF.Modules.ModelViewInheritanceModule));

Versioning

The module is not bound to DevExpress versioning, which means you can use the latest version with your old DevExpress projects Read more.

The module follows the Nuget Version Basics.

Dependencies

.NetFramework:

DevExpress.ExpressApp Any
Moq 4.12.0
System.ValueTuple 4.5.0
Xpand.VersionConverter 1.0.34

Issues-Debugging-Troubleshooting

To Step in the source code you need to enable Source Server support in your Visual Studio/Tools/Options/Debugging/Enable Source Server Support. See also How to boost your DevExpress Debugging Experience.

If the package is installed in a way that you do not have access to uninstall it, then you can unload it with the next call when XafApplication.SetupComplete.

((Xpand.XAF.Modules.ModelViewInheritanceModule) Application.Modules.FindModule(typeof(Xpand.XAF.Modules.ModelViewInheritanceModule))).Unload();

Details

The module extends the model views nodes with the IModelObjectViewMergedDifferences interface to allow model view differences composition.

image

Tests

The module is tested on Azure for each build with these tests

Examples

Bellow are a few examples of how we use the module in eXpandFramework.

image

to derive a version with Remember Me support as below:

image

The next WorldCreatormodified version of PersistentMemberInfo:

image

is used to derive a version for the PersistentCoreTypeMemberInfo like:

image

and in addition one for the PersistentCollectionMemberInfo

image

You can’t perform that action at this time.