public HttpResponseMessage Get(string id) { try { var result = context.Get(id); return(Request.CreateResponse(HttpStatusCode.OK, result)); } catch (Exception e) { return(Request.CreateErrorResponse(HttpStatusCode.BadRequest, e.Message)); } }
public SingleResult <SYS_Role> GetSYS_Role([FromODataUri] string key, ODataQueryOptions <SYS_Role> queryOptions) { return(SingleResult.Create(db.Get(key))); }
/// <summary> /// </summary> /// <param name="rolesId"></param> /// <returns></returns> public Sys_Roles Get(int rolesId) { return(_roleDB.Get(rolesId)); }