Example #1
0
 public void Save(Claim claim)
 {
     using (ISession session = _sessionFactory())
     {
         session.Update(claim);
         session.Flush();
     }
 }
Example #2
0
 public static IRightHandSideExpression Error(this IRightHandSideExpression rhs, Claim claim, string message)
 {
     return rhs.Do(ctx => ctx.Error(claim, message));
 }
Example #3
0
 public void ClaimDenied(Claim claim)
 {
     Log.WarnFormat("Notification, claim denied. ClaimId={0}", claim.Id);
 }
Example #4
0
 private static ClaimStatus Approve(Claim claim)
 {
     return claim.Status = ClaimStatus.Approved;
 }
Example #5
0
 private static ClaimStatus Review(Claim claim)
 {
     return claim.Status = ClaimStatus.Review;
 }
Example #6
0
 private static ClaimStatus Deny(Claim claim)
 {
     return claim.Status = ClaimStatus.Denied;
 }
Example #7
0
 public static void Info(this IContext context, Claim claim, string message)
 {
     InsertAlert(context, 1, claim, message);
 }
Example #8
0
 private static void InsertAlert(IContext context, int severity, Claim claim, string message)
 {
     var alert = new ClaimAlert { Severity = severity, Claim = claim, RuleName = context.Rule.Name, Message = message };
     context.Insert(alert);
 }
Example #9
0
 public static void Error(this IContext context, Claim claim, string message)
 {
     InsertAlert(context, 3, claim, message);
 }
Example #10
0
 public static void Warning(this IContext context, Claim claim, string message)
 {
     InsertAlert(context, 2, claim, message);
 }