示例#1
0
 public IQueryable <AcmeCertificate> AcmeCertQuery()
 {
     return(AcmeCertificates
            .Include(x => x.Key)
            .Include(x => x.AcmeAccount)
            .ThenInclude(x => x.Key));
 }
示例#2
0
 public IQueryable <AcmeCertOrderContainer> AcmeCertOrderQuery()
 {
     return(AcmeCertificates
            .Include(x => x.AcmeOrders)
            .ThenInclude(x => x.DomainCertificate)
            .Select(x => new AcmeCertOrderContainer
     {
         LatestValidAcmeOrder = x.AcmeOrders
                                .OrderByDescending(y => y.DateCreated)
                                .FirstOrDefault(y => y.Status == AcmeOrderStatus.Completed)
     }));
 }