If you want the same UI as in the screenshot below:
implement a few code lines in YourSolutionName.Module/Module.cs file, as follows:
using DevExpress.ExpressApp.ModelEditor;
using DevExpress.ExpressApp.Validation;
using DevExpress.ExpressApp.Model;
namespace MainDemo.Module {
public sealed partial class MainDemoModule : ModuleBase {
public MainDemoModule() {
InitializeComponent();
ModelEditorGroupingHelper.Instance.RegisterNodeGroupPathDelegate(
typeof(IModelValidationRules), node => DefaultGroupPathCalculator("TargetType.Name", node));
}
public string[] DefaultGroupPathCalculator(string propertyName, IModelNode modelNode) {
string groupName = "";
object propertyValue = ModelEditorGroupingHelper.Instance.GetPropertyValue(propertyName, modelNode);
if(propertyValue != null) {
groupName = propertyValue.ToString();
}
return ModelEditorGroupingHelper.Instance.SplitGroupPath(groupName, modelNode);
}
//...
}
}
This is just one example of the Model Editor nodes grouping customizations that you can achieve with the ModelEditorGroupingHelper API.
I remember our loyal customer Mario Blataric doing magic using this helper for his specific project needs (multi-level grouping of Actions by Controllers and their namespaces/functional blocks). If you have similar needs in your project, feel free to contact our support team so we can help you make your life easier.
implement a few code lines in YourSolutionName.Module/Module.cs file, as follows:
using DevExpress.ExpressApp.ModelEditor;
using DevExpress.ExpressApp.Validation;
using DevExpress.ExpressApp.Model;
namespace MainDemo.Module {
public sealed partial class MainDemoModule : ModuleBase {
public MainDemoModule() {
InitializeComponent();
ModelEditorGroupingHelper.Instance.RegisterNodeGroupPathDelegate(
typeof(IModelValidationRules), node => DefaultGroupPathCalculator("TargetType.Name", node));
}
public string[] DefaultGroupPathCalculator(string propertyName, IModelNode modelNode) {
string groupName = "";
object propertyValue = ModelEditorGroupingHelper.Instance.GetPropertyValue(propertyName, modelNode);
if(propertyValue != null) {
groupName = propertyValue.ToString();
}
return ModelEditorGroupingHelper.Instance.SplitGroupPath(groupName, modelNode);
}
//...
}
}
This is just one example of the Model Editor nodes grouping customizations that you can achieve with the ModelEditorGroupingHelper API.
I remember our loyal customer Mario Blataric doing magic using this helper for his specific project needs (multi-level grouping of Actions by Controllers and their namespaces/functional blocks). If you have similar needs in your project, feel free to contact our support team so we can help you make your life easier.
The SC ticket can't be viewed
ReplyDeleteTicket is private ;)
ReplyDeleteThx
Noxe
Thanks for your feedback, Guys. I've fixed that, sorry.
ReplyDeletethis one is nice.
ReplyDeleteLooks like a candidate for functionality "out of the box".
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteIgnore my last Q - spotted the answer in the documentation.
ReplyDeleteThanks for your feedback, Chris
DeleteThis comment has been removed by the author.
Deleteextremely helpful
ReplyDeleteThanks for your input, Udo!
Delete