From 4be09d79a03105cd3671fde5dacbf04cd551e7cb Mon Sep 17 00:00:00 2001
From: gaofei1985 <181547018@qq.com>
Date: Fri, 10 Apr 2026 15:23:09 +0800
Subject: [PATCH] 1
---
SGGL/BLL/API/APIPersonService.cs | 14 +++++++-------
SGGL/WebAPI/Controllers/PersonController.cs | 4 ++--
2 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/SGGL/BLL/API/APIPersonService.cs b/SGGL/BLL/API/APIPersonService.cs
index 68923901..79cf2841 100644
--- a/SGGL/BLL/API/APIPersonService.cs
+++ b/SGGL/BLL/API/APIPersonService.cs
@@ -560,7 +560,7 @@ namespace BLL
/// 培训岗位ID
/// 培训类型ID
///
- public static List getTrainingPersonListByTrainTypeId(string projectId, string unitIds, string workPostIds, string trainTypeId, string name, string startDate, string endDate)
+ public static List getTrainingPersonListByTrainTypeId(string projectId, string unitIds, string workPostIds, string trainTypeId, string name, string startDate, string endDate, string isRepeat)
{
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
{
@@ -620,7 +620,11 @@ namespace BLL
}
List getTrainPersonList = new List();
var getTrainType = TrainTypeService.GetTrainTypeById(trainTypeId);
- if (getTrainType != null && (!getTrainType.IsRepeat.HasValue || getTrainType.IsRepeat == false))
+ if ((getTrainType != null && (!getTrainType.IsRepeat.HasValue || getTrainType.IsRepeat == true)) || isRepeat == "1")
+ {
+ return getPersons.ToList();
+ }
+ else
{
foreach (var item in getPersons)
{
@@ -642,10 +646,6 @@ namespace BLL
}
return getTrainPersonList;
}
- else
- {
- return getPersons.ToList();
- }
}
}
@@ -1610,7 +1610,7 @@ namespace BLL
{
z.PlanName,
z.PlanDate,
- CheckResultName = x.TestScores >=60 ? "合格" : "不合格",
+ CheckResultName = x.TestScores >= 60 ? "合格" : "不合格",
z.TestPlanId,
};
if (getDataLists.Count() > 0)
diff --git a/SGGL/WebAPI/Controllers/PersonController.cs b/SGGL/WebAPI/Controllers/PersonController.cs
index d692597a..4f7df4df 100644
--- a/SGGL/WebAPI/Controllers/PersonController.cs
+++ b/SGGL/WebAPI/Controllers/PersonController.cs
@@ -383,12 +383,12 @@ namespace WebAPI.Controllers
/// 培训类型ID(可为空)
/// 分页
///
- public Model.ResponeData getTrainingPersonListByTrainTypeId(string projectId, string unitIds, string workPostIds, string trainTypeId, int pageIndex, string startDate, string endDate)
+ public Model.ResponeData getTrainingPersonListByTrainTypeId(string projectId, string unitIds, string workPostIds, string trainTypeId, int pageIndex, string startDate, string endDate, string isRepeat)
{
var responeData = new Model.ResponeData();
try
{
- var getDataList = APIPersonService.getTrainingPersonListByTrainTypeId(projectId, unitIds, workPostIds, trainTypeId, null, startDate, endDate).OrderBy(x => x.UnitName).ThenBy(x => x.ProjectName).ToList();
+ var getDataList = APIPersonService.getTrainingPersonListByTrainTypeId(projectId, unitIds, workPostIds, trainTypeId, null, startDate, endDate, isRepeat).OrderBy(x => x.UnitName).ThenBy(x => x.ProjectName).ToList();
int pageCount = getDataList.Count;
if (pageCount > 0 && pageIndex > 0)
{