This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
One of the huge benefits I like of the Enterprise Library Validation Application Block is the PropertyProxyValidator that extends the validation on the entities to the client-side without the need for repeating validation both at the client and the server when dealing with ASP.NET Webforms. The PropertyProxyValidator allows one to avoid handcoding of the same validation rules, keeping things nice and DRY. We need a similar solution to this with LightSpeed that transparently ( easily ) extends the attributes and/or custom validation on the entities ( or DTO's ) onto the ASP.NET Webforms and MVC Forms for client-side validation using jQuery ( preferably ) and ASP.NET AJAX. This may or may not be an issue, but in the MVC world, frameworks like xVal allow one to write a provider for this. This is all and good except that one needs an easy and good performing way to read validators per property on an entity that doesn't have the overhead of a lot of reflection. Personally, I would rather you guys come up with a solution just for LightSpeed and not rely on a 3rd party, like xVal. I would love something for the MVC Framework. It might be as simple as extension methods to HtmlHelper to emit jQuery using some convention. In general, however, I am wondering if you need to open up the discoverability of the validators and their values on an Entity to allow for good performance and easibility of creating such adaptors for working with other frameworks, like xVal, and creating HtmlHelper Extensions that will attempt to emit javascript, etc? I mentioned a similar request to the Community Code Forum on MVC Extensions, but I think the discoverability of validators is really key and broader than just MVC: http://www.mindscape.co.nz/forums/Thread.aspx?ThreadID=1796 Regards, Dave
|
|
|
Just replied to the other post and then discovered this one ;) We can certainly look at making the validators more open so you can derive the metadata from them. Ill put it on our backlog for 3.0 - assuming its no big hassle (and Im thinking it wont be) we should be able to port this back into the 2.2 branch so you can test it out via the nightlies in the interim.
Jeremy |
|