public List <KeyValuePair <ModuleType, string> > GetDeletable() { // Get the Identity Context var identity = _userQueryService.GetIdentityContext(); // Relevant Module Types var dataEntryModules = ModuleTypeInfo.ReportModules; // return modules where we have the delete right in at least one agency. return(dataEntryModules .Where(identity.Permissions.DataEntryDeleteGranted) .Select(t => new KeyValuePair <ModuleType, string>(t, t.GetDescription())) .ToList()); }
public IdentityContext GetIdentityContext() { return(_userQrySvc.GetIdentityContext()); }
public void LogPolicyViolation() { var identity = _userQrySvc.GetIdentityContext(); Audit.Add(new AuditEntry(identity.IdentityId, identity.GivenName, AuditCategory.Administration, PasswordAudit.UnsuccessfulPasswordChangeAuditFormat)); }