From b53db5c7bffa4ba52263de38a8e34c682e1d2c1a Mon Sep 17 00:00:00 2001
From: hardstylewyl <827778732@qq.com>
Date: Wed, 26 Feb 2025 09:46:27 +0800
Subject: [PATCH] =?UTF-8?q?fix:=E4=BF=AE=E5=A4=8D=E6=9F=A5=E8=AF=A2?=
=?UTF-8?q?=E6=9D=A1=E4=BB=B6=E7=9A=84=E5=8F=AF=E7=A9=BA=E7=B1=BB=E5=9E=8B?=
=?UTF-8?q?=E4=BD=BF=E7=94=A8=E9=94=99=E8=AF=AF?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Dtos/TrackContents/GetPageTrackContentVO.cs | 2 +-
.../Repositories/TrackContentRepository.cs | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/SJZY.Track.Domain/Dtos/TrackContents/GetPageTrackContentVO.cs b/src/SJZY.Track.Domain/Dtos/TrackContents/GetPageTrackContentVO.cs
index 2c9ef883..81a9ee9e 100644
--- a/src/SJZY.Track.Domain/Dtos/TrackContents/GetPageTrackContentVO.cs
+++ b/src/SJZY.Track.Domain/Dtos/TrackContents/GetPageTrackContentVO.cs
@@ -15,7 +15,7 @@ public class GetPageTrackContentVO : PageInfoInput
///
/// 轨迹状态id
///
- public int TrackStatusId { get; set; }
+ public int? TrackStatusId { get; set; }
///
/// 选中的轨迹内容id
diff --git a/src/SJZY.Track.Repository/Repositories/TrackContentRepository.cs b/src/SJZY.Track.Repository/Repositories/TrackContentRepository.cs
index 34dd608e..143777e6 100644
--- a/src/SJZY.Track.Repository/Repositories/TrackContentRepository.cs
+++ b/src/SJZY.Track.Repository/Repositories/TrackContentRepository.cs
@@ -58,7 +58,7 @@ public class TrackContentRepository : BasicRepository, ITrac
.WhereIF(!input.Keywords.IsNullOrWhiteSpace(),
(a, b, d, e, f) => a.Code.Contains(input.Keywords) || a.Content.Contains(input.Keywords)
|| a.EnContent.Contains(input.Keywords))
- .WhereIF(input.TrackStatusId > 0, (a, b, d, e, f) => a.TrackStatusId == input.TrackStatusId)
+ .WhereIF(input.TrackStatusId.HasValue && input.TrackStatusId > 0, (a, b, d, e, f) => a.TrackStatusId == input.TrackStatusId)
.OrderByIF(input.SelectIds.IsNullOrEmpty(), (a, b, d, e, f) => a.CreateTime, OrderByType.Desc)
.OrderByIF(!input.SelectIds.IsNullOrEmpty(),
(a, b, d, e, f) => SqlFunc.IIF(input.SelectIds.Contains(a.Id), SqlFunc.DateAdd(SqlFunc.GetDate(), 1),