diff --git a/Tiobon.Core.Services/Ghre/Ghre_StudyRecordServices.cs b/Tiobon.Core.Services/Ghre/Ghre_StudyRecordServices.cs index 1c728dc3..100accd0 100644 --- a/Tiobon.Core.Services/Ghre/Ghre_StudyRecordServices.cs +++ b/Tiobon.Core.Services/Ghre/Ghre_StudyRecordServices.cs @@ -51,12 +51,12 @@ public class Ghre_StudyRecordServices : BaseServices().Where(x => x.DataPrivType == "Priv" && x.MenuNo == filter.menuName).AnyAsync()) { var staffIds = await GetUserStaffPrivIds((int)App.User.ID); if (staffIds.Any()) - conditions = $" WHERE StaffId IN ({string.Join(",", staffIds.Select(id => "'" + id + "'"))})"; + conditions = $" WHERE BeginTime IS NOT NULL AND StaffId IN ({string.Join(",", staffIds.Select(id => "'" + id + "'"))})"; } if (IsEnable == true) @@ -136,7 +136,7 @@ public class Ghre_StudyRecordServices : BaseServices().FirstAsync(x => x.CourseId == entity.CourseId); entity.CourseSnapId = snap?.Id; - entity.CourseType = "ManualInsert"; + if (entity.CourseType.IsNullOrEmpty()) + entity.CourseType = "ManualInsert"; var result = await base.Add(entity); var id = SnowFlakeSingle.Instance.NextId(); @@ -700,9 +701,10 @@ public class Ghre_StudyRecordServices : BaseServices