optimize
wet 2 years ago
parent 683f16e44a
commit 01a66bb134

@ -8958,9 +8958,9 @@
关键字 关键字
</summary> </summary>
</member> </member>
<member name="P:Myshipping.Core.Service.NameQueryDto.ENName"> <member name="P:Myshipping.Core.Service.NameQueryDto.Name">
<summary> <summary>
英文名 英文名/中文名
</summary> </summary>
</member> </member>
<member name="P:Myshipping.Core.Service.NameQueryDto.Limit"> <member name="P:Myshipping.Core.Service.NameQueryDto.Limit">

@ -1585,7 +1585,9 @@ public class CommonDBService : ICommonDBService, IDynamicApiController, ITransie
var queryList = list var queryList = list
.WhereIF(!string.IsNullOrEmpty(input.Name),x=> x.EnName.Contains(input.Name, System.StringComparison.CurrentCultureIgnoreCase) .WhereIF(!string.IsNullOrEmpty(input.Name),x=> x.EnName.Contains(input.Name, System.StringComparison.CurrentCultureIgnoreCase)
|| x.CnName.Contains(input.Name, System.StringComparison.CurrentCultureIgnoreCase) ) .WhereIF(!string.IsNullOrEmpty(input.KeyWord), || x.Code.Contains(input.Name, System.StringComparison.CurrentCultureIgnoreCase)|| x.CnName.Contains(input.Name, System.StringComparison.CurrentCultureIgnoreCase)
)
.WhereIF(!string.IsNullOrEmpty(input.KeyWord),
x => (!string.IsNullOrWhiteSpace(x.Code) && x.Code.Contains(input.KeyWord, System.StringComparison.CurrentCultureIgnoreCase)) x => (!string.IsNullOrWhiteSpace(x.Code) && x.Code.Contains(input.KeyWord, System.StringComparison.CurrentCultureIgnoreCase))
|| (!string.IsNullOrWhiteSpace(x.EnName) && x.EnName.Contains(input.KeyWord, System.StringComparison.CurrentCultureIgnoreCase)) || (!string.IsNullOrWhiteSpace(x.EnName) && x.EnName.Contains(input.KeyWord, System.StringComparison.CurrentCultureIgnoreCase))
|| (!string.IsNullOrWhiteSpace(x.CnName) && x.CnName.Contains(input.KeyWord, System.StringComparison.CurrentCultureIgnoreCase)) || (!string.IsNullOrWhiteSpace(x.CnName) && x.CnName.Contains(input.KeyWord, System.StringComparison.CurrentCultureIgnoreCase))

Loading…
Cancel
Save