Merge remote-tracking branch 'refs/remotes/origin/S04轨迹预警' into test
This commit is contained in:
commit
28a4b6879d
@ -44,21 +44,21 @@ public class TrackStatusRepository : BasicRepository<TrackStatusEntity>, ITrackS
|
|||||||
.LeftJoin<VSystemEntity>((a, b) => a.SubSystemId == b.Id && b.IsDeleted == false)
|
.LeftJoin<VSystemEntity>((a, b) => a.SubSystemId == b.Id && b.IsDeleted == false)
|
||||||
.LeftJoin<VUserEntity>((a, b, c) => a.CreateUserId == c.Id && c.IsDeleted == false)
|
.LeftJoin<VUserEntity>((a, b, c) => a.CreateUserId == c.Id && c.IsDeleted == false)
|
||||||
.LeftJoin<VUserEntity>((a, b, c, d) => a.UpdateUserId == d.Id && d.IsDeleted == false)
|
.LeftJoin<VUserEntity>((a, b, c, d) => a.UpdateUserId == d.Id && d.IsDeleted == false)
|
||||||
|
.InnerJoin<TrackNodeEntity>((a, b, c, d,e) => a.Node==e.Id&&a.SubSystemId==e.SubSystemId)
|
||||||
.WhereIF(input.SubSystemId > 0, (a, b, c, d) => a.SubSystemId == input.SubSystemId)
|
.WhereIF(input.SubSystemId > 0, (a, b, c, d) => a.SubSystemId == input.SubSystemId)
|
||||||
.WhereIF(!input.Keywords.IsNullOrWhiteSpace(),
|
.WhereIF(!input.Keywords.IsNullOrWhiteSpace(),
|
||||||
(a, b, c, d) => a.Status.Contains(input.Keywords) || a.EnStatus.Contains(input.Keywords) ||
|
(a, b, c, d) => a.Status.Contains(input.Keywords) || a.EnStatus.Contains(input.Keywords) ||
|
||||||
a.Code.Contains(input.Keywords))
|
a.Code.Contains(input.Keywords))
|
||||||
.OrderByIF(input.SelectIds.IsNullOrEmpty(), (a, b, c, d) => a.CreateTime, OrderByType.Desc)
|
.OrderByIF(input.SelectIds.IsNullOrEmpty(), (a, b, c, d) => a.CreateTime, OrderByType.Desc)
|
||||||
.OrderByIF(!input.SelectIds.IsNullOrEmpty(), (a, b, c, d) => SqlFunc.IIF(input.SelectIds.Contains(a.Id), SqlFunc.DateAdd(SqlFunc.GetDate(), 1), a.CreateTime), OrderByType.Desc)
|
.OrderByIF(!input.SelectIds.IsNullOrEmpty(), (a, b, c, d) => SqlFunc.IIF(input.SelectIds.Contains(a.Id), SqlFunc.DateAdd(SqlFunc.GetDate(), 1), a.CreateTime), OrderByType.Desc)
|
||||||
.Select((a, b, c, d) => new GetTrackStatusListVO
|
.Select((a, b, c, d,e) => new GetTrackStatusListVO
|
||||||
{
|
{
|
||||||
Id = a.Id,
|
Id = a.Id,
|
||||||
Code = a.Code,
|
Code = a.Code,
|
||||||
EntrackStatus = a.EnStatus,
|
EntrackStatus = a.EnStatus,
|
||||||
TrackStatus = a.Status,
|
TrackStatus = a.Status,
|
||||||
NodeId = a.Node,
|
NodeId = a.Node,
|
||||||
Node = SqlFunc.IF(a.Node == 1).Return("揽收").ElseIF(a.Node == 2).Return("清关").ElseIF(a.Node == 3)
|
Node = e.NodeName!,
|
||||||
.Return("干线").ElseIF(a.Node == 4).Return("派送").ElseIF(a.Node == 5).Return("其他").End(""),
|
|
||||||
CreateTime = a.CreateTime,
|
CreateTime = a.CreateTime,
|
||||||
CreateUser = c.Name,
|
CreateUser = c.Name,
|
||||||
UpdateTime = a.UpdateTime,
|
UpdateTime = a.UpdateTime,
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user