质控主表模糊查询

This commit is contained in:
quowingwang 2025-12-01 17:24:01 +08:00
parent a5d74f3665
commit 0a0b163339
2 changed files with 15 additions and 2 deletions

View File

@ -6,7 +6,9 @@ namespace RIZO.Model.Mes.Dto.ProductionPreparation
/// </summary>
public class QualityControlQueryDto : PagerInfo
{
public string QcCode { get; set; }
public string LineCode { get; set; }
public string CheckType { get; set; }
public string CheckDate { get; set; }
}
/// <summary>

View File

@ -145,7 +145,18 @@ namespace RIZO.Service.Mes
private static Expressionable<QualityControl> QueryExp(QualityControlQueryDto parm)
{
var predicate = Expressionable.Create<QualityControl>();
if (!string.IsNullOrWhiteSpace(parm.LineCode))
{
predicate.And(it => it.LineCode.Contains(parm.LineCode));
}
if (!string.IsNullOrWhiteSpace(parm.CheckDate))
{
predicate.And(it => it.CheckDate.Contains(parm.CheckDate));
}
if (!string.IsNullOrWhiteSpace(parm.CheckType))
{
predicate.And(it => it.CheckType.Contains(parm.CheckType));
}
return predicate;
}