diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTran/StuScoreNotPassTranEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTran/StuScoreNotPassTranEntity.cs index cc7d28441..0be14f394 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTran/StuScoreNotPassTranEntity.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTran/StuScoreNotPassTranEntity.cs @@ -19,7 +19,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// /// [Column("SCOREID")] - public string ScoreId { get; set; } + public int? ScoreId { get; set; } /// /// NoticeBookNo /// @@ -321,7 +321,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// 编辑调用 /// /// - public void Modify(string keyValue) + public void Modify(int? keyValue) { this.ScoreId = keyValue; } diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTran/StuScoreNotPassTranService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTran/StuScoreNotPassTranService.cs index b1fb81016..1c69e289f 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTran/StuScoreNotPassTranService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTran/StuScoreNotPassTranService.cs @@ -25,7 +25,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// public StuScoreNotPassTranService() { - fieldSql=@" + fieldSql = @" t.ScoreId, t.NoticeBookNo, t.StuNo, @@ -86,7 +86,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// /// 条件参数 /// - public IEnumerable GetList( string queryJson ) + public IEnumerable GetList(string queryJson) { try { @@ -179,7 +179,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration { try { - this.BaseRepository("CollegeMIS").Delete(t=>t.ScoreId == keyValue); + this.BaseRepository("CollegeMIS").Delete(t => t.ScoreId == Convert.ToInt32(keyValue)); } catch (Exception ex) { @@ -205,7 +205,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration { if (!string.IsNullOrEmpty(keyValue)) { - entity.Modify(keyValue); + entity.Modify(Convert.ToInt32(keyValue)); this.BaseRepository("CollegeMIS").Update(entity); } else diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTwoTran/StuScoreNotPassTwoTranEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTwoTran/StuScoreNotPassTwoTranEntity.cs index d56da719f..3af0c9014 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTwoTran/StuScoreNotPassTwoTranEntity.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTwoTran/StuScoreNotPassTwoTranEntity.cs @@ -11,7 +11,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// 日 期:2023-02-10 10:52 /// 描 述:学籍异动成绩二次补考纪录 /// - public class StuScoreNotPassTwoTranEntity + public class StuScoreNotPassTwoTranEntity { #region 实体成员 /// @@ -19,7 +19,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// /// [Column("SCOREID")] - public string ScoreId { get; set; } + public int? ScoreId { get; set; } /// /// NoticeBookNo /// @@ -316,13 +316,13 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// public void Create() { - this.ScoreId = Guid.NewGuid().ToString(); + } /// /// 编辑调用 /// /// - public void Modify(string keyValue) + public void Modify(int? keyValue) { this.ScoreId = keyValue; } diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTwoTran/StuScoreNotPassTwoTranService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTwoTran/StuScoreNotPassTwoTranService.cs index 5a3b5c1c6..49bb84b9d 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTwoTran/StuScoreNotPassTwoTranService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreNotPassTwoTran/StuScoreNotPassTwoTranService.cs @@ -25,7 +25,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// public StuScoreNotPassTwoTranService() { - fieldSql=@" + fieldSql = @" t.ScoreId, t.NoticeBookNo, t.StuNo, @@ -86,7 +86,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// /// 条件参数 /// - public IEnumerable GetList( string queryJson ) + public IEnumerable GetList(string queryJson) { try { @@ -179,7 +179,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration { try { - this.BaseRepository("CollegeMIS").Delete(t=>t.ScoreId == keyValue); + this.BaseRepository("CollegeMIS").Delete(t => t.ScoreId == Convert.ToInt32(keyValue)); } catch (Exception ex) { @@ -205,7 +205,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration { if (!string.IsNullOrEmpty(keyValue)) { - entity.Modify(keyValue); + entity.Modify(Convert.ToInt32(keyValue)); this.BaseRepository("CollegeMIS").Update(entity); } else diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreTran/StuScoreTranEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreTran/StuScoreTranEntity.cs index f3956b6d8..abfda9907 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreTran/StuScoreTranEntity.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreTran/StuScoreTranEntity.cs @@ -19,7 +19,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// /// [Column("SCOREID")] - public string ScoreId { get; set; } + public int? ScoreId { get; set; } /// /// NoticeBookNo /// @@ -333,7 +333,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// 编辑调用 /// /// - public void Modify(string keyValue) + public void Modify(int? keyValue) { this.ScoreId = keyValue; } diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreTran/StuScoreTranService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreTran/StuScoreTranService.cs index 46e4de4c5..32d9d089d 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreTran/StuScoreTranService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuScoreTran/StuScoreTranService.cs @@ -181,7 +181,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration { try { - this.BaseRepository("CollegeMIS").Delete(t => t.ScoreId == keyValue); + this.BaseRepository("CollegeMIS").Delete(t => t.ScoreId == Convert.ToInt32(keyValue)); } catch (Exception ex) { @@ -205,9 +205,9 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration { try { - if (!string.IsNullOrEmpty(keyValue.ToString())) + if (!string.IsNullOrEmpty(keyValue)) { - entity.Modify(keyValue); + entity.Modify(Convert.ToInt32(keyValue)); this.BaseRepository("CollegeMIS").Update(entity); } else diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuTransferInfo/StuTransferInfoService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuTransferInfo/StuTransferInfoService.cs index bc7845b44..a27b7efa5 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuTransferInfo/StuTransferInfoService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuTransferInfo/StuTransferInfoService.cs @@ -457,15 +457,52 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration #endregion #region 成绩(StuScore,新-写入,旧-删除;) - + var StuScoreHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo + && x.DeptNo == InsertStuTran.DeptNo && x.MajorNo == InsertStuTran.MajorNo + && x.ClassNo == InsertStuTran.ClassNo && x.F_SchoolId == InsertStuTran.F_SchoolId); + if (StuScoreHistory != null) + { + foreach (var itemScore in StuScoreHistory) + { + //插入新数据 + db.ExecuteBySql(" insert into StuScoreTran select * from StuScore where Scoreid = '" + itemScore.ScoreId + "'"); + //删除旧数据 + db.Delete(x => x.ScoreId == itemScore.ScoreId); + } + } #endregion #region 课表(StuSelectLessonList,新-写入,旧-删除;) #endregion #region 选修课表(StuSelectLessonListOfElective,新-写入,旧-删除;OpenLessonPlanOfElective,旧-修改已报名的学生数量字段;) #endregion #region 补考成绩(StuScoreNotPass,新-写入,旧-删除;) + var StuScoreNotPassHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo + && x.DeptNo == InsertStuTran.DeptNo && x.MajorNo == InsertStuTran.MajorNo + && x.ClassNo == InsertStuTran.ClassNo && x.F_SchoolId == InsertStuTran.F_SchoolId); + if (StuScoreNotPassHistory != null) + { + foreach (var itemScore in StuScoreNotPassHistory) + { + db.ExecuteBySql(" insert into StuScoreNotPassTran select * from StuScoreNotPass where Scoreid = '" + itemScore.ScoreId + "'"); + //删除旧数据 + db.Delete(x => x.ScoreId == itemScore.ScoreId); + } + } #endregion #region 二次补考(StuScoreNotPassTwo,新-写入,旧-删除;) + var StuScoreNotPassTwoHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo + && x.DeptNo == InsertStuTran.DeptNo && x.MajorNo == InsertStuTran.MajorNo + && x.ClassNo == InsertStuTran.ClassNo && x.F_SchoolId == InsertStuTran.F_SchoolId); + if (StuScoreNotPassTwoHistory != null) + { + foreach (var itemScore in StuScoreNotPassTwoHistory) + { + //插入数据 + db.ExecuteBySql(" insert into StuScoreNotPassTwoTran select * from StuScoreNotPassTwo where Scoreid = '" + itemScore.ScoreId + "'"); + //删除旧数据 + db.Delete(x => x.ScoreId == itemScore.ScoreId); + } + } #endregion #region 助学金奖学金(ScholarshipAudit,新-写入,旧-删除;) #endregion @@ -505,7 +542,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration #region 课表(StuSelectLessonList,旧-写入新班级课表数据;) #endregion } - else if(upTrua.AnomalousType == "02" || upTrua.AnomalousType == "05" || upTrua.AnomalousType == "06") + else if (upTrua.AnomalousType == "02" || upTrua.AnomalousType == "05" || upTrua.AnomalousType == "06") { #region 学籍操作 if (upTrua.StuStatus == 1) //如果是保留学籍 修改学籍 否则删除学籍