Beispiel #1
0
        public IHttpActionResult GetSupplies()
        {
            var helper = new SuppliesHelper();
            var result = helper.GetSupplies();

            if (result == null)
            {
                return(NotFound());
            }

            return(Ok(result));
        }
Beispiel #2
0
        public IHttpActionResult GetSupply(int id)
        {
            var helper = new SuppliesHelper();
            var result = helper.GetSupply(id);

            //Supply supply = db.Supplies.Find(id);
            if (result == null)
            {
                return(NotFound());
            }

            return(Ok(result));
        }