Hi,
is there any generic way to get the role which is required for some particular action?
In Detail my problem is, that I have e.g. 2 roles "User" and "Admin" and an action with the following:
[Authorize(Roles = "Admin")] public class AdministrationController...
If the user is not logged in, he gets the login screen. That's ok. When a user with the role "Admin" logs in, all works fine. But if a user with the role "user" logs in, he will be continiously displayed the login screen, besides he has succesfully logged in, but of course not the required role.
So it would be good if the login display could display to him a hint, telling that he is already logged in, but he has not the required rights to see this page. And additionally it may display the required role(s).
Thanks, Michael