From 677bdd33a7c2e91a36b43ee7e6f82c5fecb764a8 Mon Sep 17 00:00:00 2001 From: ndbs Date: Tue, 14 Feb 2023 16:07:58 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AD=A6=E7=B1=8D=E7=A7=BB=E5=8A=A8=E5=AE=A1?= =?UTF-8?q?=E6=A0=B8=20[=E6=88=90=E7=BB=A9,=E8=A1=A5=E8=80=83=E6=88=90?= =?UTF-8?q?=E7=BB=A9.=E4=BA=8C=E6=AC=A1=E8=A1=A5=E8=80=83,=E5=8A=A9/?= =?UTF-8?q?=E5=A5=96=E5=AD=A6=E9=87=91,=E5=85=B5=E5=BD=B9,=E5=BF=83?= =?UTF-8?q?=E9=87=8C=E9=A2=84=E7=BA=A6,=E5=A4=84=E5=88=86,=E5=A5=96?= =?UTF-8?q?=E5=8A=B1]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../StuTransferInfo/StuTransferInfoService.cs | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+) 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 a27b7efa5..d5a2b95a2 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 @@ -1,5 +1,6 @@ using Dapper; using Learun.Application.Organization; +using Learun.Application.TwoDevelopment.LogisticsManagement; using Learun.DataBase.Repository; using Learun.Util; using System; @@ -505,18 +506,89 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } #endregion #region 助学金奖学金(ScholarshipAudit,新-写入,旧-删除;) + var ScholarshipHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo); + if (ScholarshipHistory != null) + { + foreach (var items in ScholarshipHistory) + { + db.ExecuteBySql(" insert into ScholarshipTran select * from ScholarshipAudit where IsType = 1 and State =1 and id = '" + items.Id + "'"); + db.ExecuteBySql(" insert into ScholarshipTran select * from ScholarshipAudit where IsType = 0 and id = '" + items.Id + "'"); + // 删除旧数据 + db.Delete(x => x.Id == items.Id); + } + } #endregion #region 学生心理健康档案(APStuHealthRecords,新-写入,旧-删除;) + var AspHistory = db.FindList(x => x.Stuno == InsertStuTran.StuNo); + if (AspHistory != null) + { + foreach (var items in AspHistory) + { + db.ExecuteBySql(" insert into APStuHealthRecordsTran select * from APStuHealthRecords where ID = " + items.ID + "'"); + // 删除旧数据 + db.Delete(x => x.ID == items.ID); + } + } #endregion #region 兵役一(MSRIntentionManagement,新-写入,旧-删除;) + var MSRIntentionHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo); + if (MSRIntentionHistory != null) + { + foreach (var items in MSRIntentionHistory) + { + db.ExecuteBySql(" insert into MSRIntentionManagementTran select * from MSRIntentionManagement where ID = " + items.ID + "'"); + // 删除旧数据 + db.Delete(x => x.ID == items.ID); + } + } #endregion #region 兵役二(MSRMilitaryRecord,新-写入,旧-删除;) + var MSRMilitaryRecordHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo); + if (MSRMilitaryRecordHistory != null) + { + foreach (var items in MSRMilitaryRecordHistory) + { + db.ExecuteBySql(" insert into MSRMilitaryRecordTran select * from MSRMilitaryRecord where ID = " + items.ID + "'"); + // 删除旧数据 + db.Delete(x => x.ID == items.ID); + } + } #endregion #region 兵役三(MSRMilitaryServiceRegistration,新-写入,旧-删除;) + var MSRMilitaryServiceRegistrationHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo); + if (MSRMilitaryServiceRegistrationHistory != null) + { + foreach (var items in MSRMilitaryServiceRegistrationHistory) + { + db.ExecuteBySql(" insert into MSRMilitaryServiceRegistrationTran select * from MSRMilitaryServiceRegistration where ID = " + items.ID + "'"); + // 删除旧数据 + db.Delete(x => x.ID == items.ID); + } + } #endregion #region 奖励(StuEncourgement,新-写入,旧-删除;) + var StuEncourgementHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo); + if (StuEncourgementHistory != null) + { + foreach (var items in StuEncourgementHistory) + { + db.ExecuteBySql(" insert into StuEncourgementTran select * from StuEncourgement where ID = " + items.ID + "'"); + // 删除旧数据 + db.Delete(x => x.ID == items.ID); + } + } #endregion #region 处分(StuPunishment,新-写入,旧-删除;) + var StuPunishmentHistory = db.FindList(x => x.StuNo == InsertStuTran.StuNo); + if (StuPunishmentHistory != null) + { + foreach (var items in StuPunishmentHistory) + { + db.ExecuteBySql(" insert into StuPunishmentTran select * from StuPunishment where ID = " + items.Id + "'"); + // 删除旧数据 + db.Delete(x => x.Id == items.Id); + } + } #endregion if (upTrua.AnomalousType == "01" || upTrua.AnomalousType == "07" || upTrua.AnomalousType == "08")