Example #1
0
        public bool IsWarehouseReceptionAllowed(WarehouseHistoryRecord warehouseInOutItem)
        {
            ReceptionStrategy receptionStrategy = null;

            if (warehouseInOutItem.ProductTypeId != null)
            {
                receptionStrategy = new ProductTypeReceptionStrategy();
            }


            if (warehouseInOutItem.FilmTypeId != null)
            {
                receptionStrategy = new FilmTypeReceptionStrategy();
            }

            return(receptionStrategy?.Compute(warehouseInOutItem, this.InOutHistory.ToList()) ?? true);
        }
Example #2
0
 public bool IsWarehouseInOutHistoryValid(WarehouseHistoryRecord warehouseInOutItem)
 {
     return(warehouseInOutItem.ProductTypeId == null || warehouseInOutItem.FilmType == null);
 }
Example #3
0
 public void Add(WarehouseHistoryRecord warehouseItem)
 {
     InOutHistory.Add(warehouseItem);
 }