Esempio n. 1
0
        public DateTimeOffset OrderItem(string code, int quantity, DateTimeOffset requiredDate)
        {
            var data = new SupplyData();

            if (!data.TryDepleteStock(code, quantity))
            {
                throw new Exception("Item unavailable");
            }

            return(requiredDate);
        }