예제 #1
0
 public async Task <TEntity> FindByIdAsync(int id)
 {
     return(await _context.FindAsync <TEntity>(id));
 }
예제 #2
0
 public async Task <T> FindById(int id)
 {
     using var context = new BlogAppContext();
     return(await context.FindAsync <T>(id));
 }