Пример #1
0
 public override void HandleRequest(IHolidayFormRequest request)
 {
     if (RandomBool.Get())
     {
         Console.WriteLine("Manager: Yes, I'm accepting.");
         request.SetAcceptByManager();
         base.HandleRequest(request);
     }
     else
     {
         Console.WriteLine("Manager: Sorry... I can not accept your request because we have a lot to work in...");
     }
 }
Пример #2
0
 public override void HandleRequest(IHolidayFormRequest request)
 {
     if (RandomBool.Get())
     {
         Console.WriteLine("HR: Yes, we are accepting.");
         request.SetAcceptByHR();
         base.HandleRequest(request);
     }
     else
     {
         Console.WriteLine("HR: Sorry, you have already used up your entire period for holiday.");
     }
 }
Пример #3
0
 public override void HandleRequest(IHolidayFormRequest request)
 {
     if (RandomBool.Get())
     {
         Console.WriteLine("ReplacingPerson: Yes, of course!");
         request.SetAcceptByReplacingPerson();
         base.HandleRequest(request);
     }
     else
     {
         Console.WriteLine("ReplacingPerson: Sorry Man... I can not replace you then...");
     }
 }