Exemple #1
0
        public static T AsCSharpObject <T>(this ActionResult result)
        {
            var response     = result.AsHttpResponseMessage();
            var sResponse    = response.Content.ReadAsStringAsync().Result;
            var jsonResponse = JsonConvert.DeserializeObject <Dictionary <string, object> >(sResponse);

            return(JsonConvert.DeserializeObject <T>(jsonResponse["data"].ToString()));
        }