供应商完工

This commit is contained in:
qianhao.xu 2024-07-08 14:01:04 +08:00
parent 9aa166304f
commit 54532cd499
2 changed files with 8 additions and 1 deletions

View File

@ -7,6 +7,10 @@ namespace DOAN.Model.MES.base_.Dto
/// </summary>
public class BaseSupplierQueryDto : PagerInfo
{
public string SupplierNo { get; set; }
public string SupplierName { get; set; }
public int? Type { get; set; }
}
/// <summary>

View File

@ -24,7 +24,10 @@ namespace DOAN.Service.MES.base_
/// <returns></returns>
public PagedInfo<BaseSupplierDto> GetList(BaseSupplierQueryDto parm)
{
var predicate = Expressionable.Create<BaseSupplier>();
var predicate = Expressionable.Create<BaseSupplier>()
.AndIF(!string.IsNullOrEmpty(parm.SupplierNo), it => it.SupplierNo.Contains(parm.SupplierNo))
.AndIF(!string.IsNullOrEmpty(parm.SupplierName), it => it.SupplierName.Contains(parm.SupplierName))
.AndIF(parm.Type > -1, it => it.Type == parm.Type);
var response = Queryable()
.Where(predicate.ToExpression())