internal static bool HasPermission(FunctionalityEnum funcEnum, bool checkLicenseAlso) { //return true; bool returnValue = false; //if (CurrentBitplateUser.GetSuperUserType() == SuperUserTypeEnum.Developers) //{ // return true; //} //in sommige gevallen is er geen licentie, maar moet dashboard & siteconfig wel beschikbaar zijn, //namelijk om de licentiecode te zetten. //dan kan er dus geen check zijn op licentie (deze check zit wel in alle subpagina's) if (checkLicenseAlso) { if (CurrentLicense != null && CurrentBitplateUser != null) { returnValue = (CurrentLicense.HasPermission(funcEnum) && CurrentBitplateUser.HasPermission(funcEnum)); } } else { returnValue = CurrentBitplateUser.HasPermission(funcEnum); } return(returnValue); //return true; }
public static bool HasPermission(FunctionalityEnum funcEnum, bool checkLicenseAlso) { bool returnValue = false; returnValue = CurrentUser.HasPermission(funcEnum); return(returnValue); }
//private List<int> _allPermissions; public bool HasPermission(FunctionalityEnum func) { bool returnvalue = false; //if (_allPermissions == null) //{ // fillAllPermissions(); //} foreach (FunctionalityEnum permission in Permissions) { if (permission == func) { returnvalue = true; break; } } return(returnvalue); }
public bool HasPermission(FunctionalityEnum func) { if (!IsValid) { return(false); } bool returnvalue = false; foreach (FunctionalityEnum permission in _functionNumbers) { if (permission == func) { returnvalue = true; break; } } return(returnvalue); }
public bool HasPermission(FunctionalityEnum func) { bool returnvalue = false; if (this.GetUserType() == UserTypeEnum.Developers || this.GetUserType() == UserTypeEnum.SiteAdmins) { returnvalue = true; } else { foreach (int number in GetAllPermissions()) { if (number == (int)func) { returnvalue = true; break; } } } return(returnvalue); }
internal static bool HasPermission(FunctionalityEnum funcEnum) { return(HasPermission(funcEnum, true)); }
public bool HasPermission(FunctionalityEnum func) { return(true); }