Currently, it requires writing a controller for both WinForms and Web interfaces using two different approaches. Refer to the Remove Clear Button for Required Field ticket for more details.
Usability - Make it possible to hide Clear Action via the application model
Answers approved by DevExpress Support
We have implemented the functionality described in this ticket. It will be included in our next update(s).
Please check back and leave a comment to this response to let us know whether or not this solution addresses your concerns.
We decided to provide a separate IModelCommonMemberViewItem.AllowClear option, which can be set via the Model Editor for the IModelMember, IModelPropertyEditor or IModelColumn nodes. Also, the capability to clear the lookup editor's value will now be provided as part of the LookupPropertyEditor itself. So, the LookupWindowController will be marked as obsolete.
- v13.2.6Download Official Update
- v13.2.5Download Official Update
Hi,
I think the feature isn't implemented as it should be. In the "additional information" you're writing AllowClear should also be available in the IModelMember nodes. At the moment it isn't useable for us. Because if we set this property in the ViewItem nodes, they are gone if the user customizes the layout (remove ViewItems, add ViewItems). Furthermore I think this property should be available in the platform independent model, too.
@Kim: Thank you for your feedback. The AllowClear property can still be set via the XAFML of a platform-agnostic module, but this capability is currently available only through editing the XAFML file manually in the text editor:
XML<Class Name="MainDemo.Module.BusinessObjects.Contact" >
<OwnMembers>
<Member Name="Manager" AllowClear="False" />
</OwnMembers>
</Class>
The AllowClear property is not visible for the BOModel | Class | Member node in the Model Editor by default (this is controlled by the LookupViewItemOnlyCalculator) class through the ModelBrowsable attribute. We will see to improving this behavior in the future and for now you can use the solution I described.
Hi Dennis,
ok I see. While waiting for your improvements, your suggestion will be fine for us.
Thanks!
In this category, there are many more. You see people here asking and doing the same over and over:
- Remove New Button from Nested ListView Toolbars via Application Model.
- Remove Delete Button from Nested ListView Toolbars via Application Model.
- Remove whole Toolbar from nested listview via Application Model.
- Disallow open detailview from listview via Application Model.
- Show Navigator for Grid via application model.
- Add global setting to remove SUM=COUNT= etc from summaries in grids.
Just got these from going over my own model extensions and IMO most of these features are a bad idea and counter productive.
Raoul.
hey Raoul, so what exactly is your perspective, as this seems hard to discern if you want the augmentations or not. I have brought up countless times that an outside ombudsman who works with real-life clients with xaf would be invaluable to showing where all the simple logic use-cases are missing in xaf.