Hi all,
My identity class has a property that is not readonly, ¿Is that allowed?
During login process the UI will set that property because it means the office where the user is logging in.
I can easily work with that not readonly property in the identity class but the problem is when I try to update the identity property in the principal class because the identity property of the principal class is readonly.
How can I set/update the office property in the Csla.ApplicationContext.User?
Thanks in advance,
Lazaro Manuel
I would do this by sending the office as part of the criteria for the login process. So when the identity is created as part of the authentication process, you can set the office property and it can still be read-only.
Thanks Rocky for your response.
I can not do it that way because the login process has two steps:
-giving username and password fr validate them
-once the usr is validated then select the office
So I think the officeId can not be part of the criteria. I thougt in writing an update public method for the principal class.
I will pass an identiy parameter to that method. So I can take the identity and modify the officeId and then pass it to my own update method of the principal.
That method will just call the setprincipal method with that updated identity.
What do you think about that?
Thanks in advance.
Lazaro Manuel
Copyright (c) Marimer LLC