This is my model class
public partial class TLog
{
[Key]
public int idLog { get; set; }
public string description { get; set; }
public System.DateTime insertDate { get; set; }
}
And this is my query method:
public static List<TLog> GetAllLogs()
{
var query = from log in dataContext.Log
select log;
return query.ToList();
}
The JSON returned is
[
{
"$id": "1",
"idLog": 1,
"description": "Log1",
"insertDate": "2015-06-13T17:32:02.053"
},
{
"$id": "2",
"idLog": 2,
"description": "Log2",
"insertDate": "2015-06-13T17:52:39.637"
}
]
How can I avoid that $id in the returned JSON as I already have my idLog?