public virtual JsonResult AvailableActivityTypes() { var activityTypes = _feedService .GetAllSettings() .Where(s => !s.ExcludeFromAvailableActivityTypes) .Select(s => (Id: s.Type.ToInt(), Name: s.Type.ToString())) .Select(a => new { a.Id, a.Name }) .OrderBy(el => el.Id); return(Json(activityTypes, JsonRequestBehavior.AllowGet)); }