Exemplo n.º 1
0
        public JsonResult Fuzzies(string id)
        {
            IPartService ps    = new PartService(Settings.Default.db);
            List <Part>  parts = ps.FuzzyById(id);

            List <PartViewModel> pvs = new List <PartViewModel> ();

            foreach (var part in parts)
            {
                pvs.Add(new PartViewModel()
                {
                    partNr = part.partNr
                });
            }
            return(Json(pvs, JsonRequestBehavior.AllowGet));
        }