Example #1
0
        public JsonResult GetListDistrictByProvinceID(int proid)
        {
            var listDistrict = LocationDAO.GetListDistrictByProvinceID(proid);

            return(Json(new
            {
                items = listDistrict.Select(x => new
                {
                    id = x.id,
                    text = x.name
                })
            }, JsonRequestBehavior.AllowGet));
        }