Beispiel #1
0
        public IHttpActionResult GetItem()
        {
            var item   = _dataGetter.GetChains();
            var result = Json(item.Select(i => i.Name).ToList());

            return(result);
            //return Ok(item);
        }
Beispiel #2
0
        /*---------------------------------*/

        private List <string> GetChainsNames()
        {
            var chainsList = _dataGetter.GetChains();
            var names      = new List <string>();

            foreach (var c in chainsList)
            {
                names.Add(c.Name);
            }

            return(names);
        }