> I have one question, however. I have an authentication-status shared > partial view that lives in my layout, and contains a form that posts > to my home-controller. However, it's possible that this sign-in form > could be rendered on a controller other than home. So how best to > furnish it with a typeof(UserAuthenticationDto) so that validation can > happen for it - in a Filter? That gets me to thinking it might be a > fun thing to introduce a TypesNeededForValidationFigurerOuterFilter > ( ;-) ) that will look at the action being performed, and figure out > whether it needs to put a DTO-type into the PropertyBag, and which > type it needs to be - I suppose this might be facilitated by an > Attribute on the action that takes a type as argument....? How does > that sound?
I've hacked this by having strong typed dictionary adapter interfaces that all inherit IBaseViewModel (my base holder for view properties), then using a dedicated method to create the dictionary adapter that check if the type is IBaseViewModel then populate the required properties. This isn't free of shortcommings, but it fits the purpose for me. What you are describing with filters and action attributes seems interesting but I haven't had time to investigate such solution. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Castle Project Users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/castle-project-users?hl=en -~----------~----~----~----~------~----~------~--~---
