Пример #1
0
 private static int GetSpecialsQuantity(CalculateTrolleyTotalCommand.RequestTrolley.TrolleyProductQuantity productQuantity, CalculateTrolleyTotalCommand.RequestTrolley.TrolleySpecial sps)
 {
     try
     {
         return(sps.Quantities.FirstOrDefault(x => x.Name == productQuantity.Name).Quantity);
     }
     catch
     {
         return(0);
     }
 }
Пример #2
0
 private static bool SpecialsIncorrectlySetup(CalculateTrolleyTotalCommand.RequestTrolley.TrolleySpecial sps)
 {
     return(sps == null || sps.Total <= 0);
 }