public async Task <ActionResult> getinfo() { var json = new StreamReader(Request.Body).ReadToEnd(); var data = JsonConvert.DeserializeObject <List <DictionaryEntity> >(json); var _posts = await DictionaryBLL.LoadItems(_context, data[0]); return(Ok(new { posts = _posts[0] })); }
public async Task <ActionResult> load() { var json = new StreamReader(Request.Body).ReadToEnd(); var data = JsonConvert.DeserializeObject <DictionaryEntity>(json); var _posts = await DictionaryBLL.LoadItems(_context, data);; var _records = 0; if (data.id == 0) { _records = await DictionaryBLL.Count(_context, data); } return(Ok(new { posts = _posts, records = _records })); }