Advertisement
yambroskin

Untitled

Aug 4th, 2017
140
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.95 KB | None | 0 0
  1. /// <summary>
  2. /// CheckRequestLimit
  3. /// </summary>
  4. /// <param name="context">Контекст процесса</param>
  5. /// <param name="GatewayVar"></param>
  6. public virtual bool CheckRequestLimit (Context context, object GatewayVar)
  7. {
  8. context.LimitPSB.UpdateAmounts();
  9.  
  10. Console.WriteLine((context.LimitPSB.Validity > DateTime.Now).ToString());
  11. Console.WriteLine(((context.LimitPSB.ListOfRequests.Contains(context.RequestBG) && context.LimitPSB.Balance >=0)||context.RequestBG.AmountOfGuarantee < context.LimitPSB.Balance).ToString());
  12. Console.WriteLine(((context.RequestBG.ActionEndDate < context.LimitPSB.Validity)).ToString());
  13.  
  14. return context.LimitPSB.Validity > DateTime.Now
  15. && ((context.LimitPSB.ListOfRequests.Contains(context.RequestBG) && context.LimitPSB.Balance >=0)||context.RequestBG.AmountOfGuarantee < context.LimitPSB.Balance)
  16. && context.RequestBG.ActionEndDate < context.LimitPSB.Validity;
  17.  
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement