public IHttpActionResult Get(string id) { var result = serv.getColumns(id); // TODO Use Automapper to return column deserialized return(Json(new { data = result })); }
public ActionResult Get(string tableName) { Enum.TryParse <ValidTableNames>(tableName, out var unused); // validate that we've only received a table name var result = serv.getColumns(tableName); return(new JsonResult(new { data = result })); }