whereLambda.where(c=>(companyName!=null)&&c.CompanyName.Contains(companyName)).where(c=>(!String.IsNullOrEmpty(regNumber))&&c.RegID.Contains(regNumber))差不多是这样