|
@@ -164,6 +164,13 @@ namespace Hotline.Api.Controllers
|
|
|
{
|
|
|
var (total, items) = await _db.Queryable<XingtangWhitePhone>()
|
|
|
.WhereIF(!string.IsNullOrEmpty(dto.Keyword), p => p.Phone.Contains(dto.Keyword))
|
|
|
+ .Select(p => new WhitePhoneListDto
|
|
|
+ {
|
|
|
+ Id = p.Id,
|
|
|
+ StartPhone = p.Phone,
|
|
|
+ ValidDateTime = p.ValidDateTime,
|
|
|
+ Enabled = p.Enabled
|
|
|
+ })
|
|
|
.ToPagedListAsync(dto, HttpContext.RequestAborted);
|
|
|
|
|
|
return new PagedDto<WhitePhoneListDto>(total, _mapper.Map<IReadOnlyList<WhitePhoneListDto>>(items));
|