/// <summary>
        /// LJ 20160105
        /// Set class properties coming from Result Model
        /// </summary>
        /// <typeparam name="T"></typeparam>
        /// <param name="model"></param>
        /// <returns></returns>
        public static T ModelToObject <T>(this jDataRow model) where T : class
        {
            var k = Activator.CreateInstance <T>();

            foreach (var j in typeof(T).GetProperties())
            {
                SetObjectProperty <T>(k, j.Name, model[j.Name]);
            }
            return(k);
        }
 public static string ToJson(this jDataRow model, bool format = false)
 {
     return(Newtonsoft.Json.JsonConvert.SerializeObject(model, format ? Formatting.Indented : Formatting.None));
 }