15 lines
414 B
C#
15 lines
414 B
C#
using Ardalis.Specification;
|
|
using BeReadyBackend.Models;
|
|
|
|
namespace BeReadyBackend.Specifications.Users;
|
|
|
|
public class GetProofOrChallengeByUserIdSpec : SingleResultSpecification<User>
|
|
{
|
|
public GetProofOrChallengeByUserIdSpec(int userId)
|
|
{
|
|
Query
|
|
.Include(x => x.UserRandomChallenges!)
|
|
.ThenInclude(x => x.RandomChallenge)
|
|
.Where(x => x.Id == userId);
|
|
}
|
|
} |