source: src/FinkiChattery/FinkiChattery.Persistence/Repositories/Implementations/StudentRepo.cs@ 7146ebb

dev
Last change on this file since 7146ebb was 7146ebb, checked in by Стојков Марко <mst@…>, 3 years ago

Ask question endpoint

  • Property mode set to 100644
File size: 569 bytes
Line 
1using FinkiChattery.Persistence.Context;
2using FinkiChattery.Persistence.Models;
3using Microsoft.EntityFrameworkCore;
4using System.Threading.Tasks;
5
6namespace FinkiChattery.Persistence.Repositories
7{
8 public class StudentRepo : Repository<Student>, IStudentRepo
9 {
10 public StudentRepo(ApplicationDbContext dbContext) : base(dbContext)
11 {
12 }
13
14 public async Task<Student> GetStudent(long applicationUserFk)
15 {
16 return await DbSet.FirstOrDefaultAsync(x => x.ApplicationUserFk == applicationUserFk);
17 }
18 }
19}
Note: See TracBrowser for help on using the repository browser.