|
|
|
@ -269,7 +269,8 @@ public class ClientInfoService : ServiceBase, IClientInfoService
|
|
|
|
|
var query = TenantDb.Queryable<InfoClient>()
|
|
|
|
|
.LeftJoin<InfoClientContact>((c, c1) => c.Id == c1.ClientId)
|
|
|
|
|
.LeftJoin<InfoClientContract>((c, c1, c2) => c.Id == c2.ClientId)
|
|
|
|
|
.InnerJoinIF<InfoClientTag>(request.OtherQueryCondition?.ClientTag != null, (c, c1, c2, ct) => c.Id == ct.ClientId);
|
|
|
|
|
.InnerJoinIF<InfoClientTag>(request.OtherQueryCondition?.ClientTag != null, (c, c1, c2, ct) => c.Id == ct.ClientId)
|
|
|
|
|
.GroupByIF(request.OtherQueryCondition != null, (c, c1, c2) => c.Id);
|
|
|
|
|
|
|
|
|
|
if (!string.IsNullOrEmpty(request.OtherQueryCondition?.ContactInfo))
|
|
|
|
|
query = query.Where((c, c1, c2) => c1.Tel.Contains(request.OtherQueryCondition.ContactInfo) ||
|
|
|
|
|