|
|
|
@ -94,6 +94,20 @@ namespace Myshipping.Application
|
|
|
|
|
: cacheList.Where(x => x.Scope == scope).ToList();
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 分页获取全部或指定范围类型的标签列表
|
|
|
|
|
/// </summary>
|
|
|
|
|
[HttpPost("/BookingLabel/PageList")]
|
|
|
|
|
public async Task<SqlSugarPagedList<BookingLabelBaseDto>> PageList(BookingLabelPageListInput input)
|
|
|
|
|
{
|
|
|
|
|
var list = await _rep.AsQueryable()
|
|
|
|
|
.WhereIF(!string.IsNullOrEmpty(input.Name), x => x.Name.Contains(input.Name))
|
|
|
|
|
.WhereIF(input.Scope != null, x => x.Scope == input.Scope)
|
|
|
|
|
.ToPagedListAsync(input.PageNo, input.PageSize);
|
|
|
|
|
|
|
|
|
|
var result = list.Adapt<SqlSugarPagedList<BookingLabelBaseDto>>();
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 新增或修改标签信息
|
|
|
|
|