|
|
@@ -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<ScholarshipxjEntity>(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<ScholarshipxjEntity>(x => x.Id == items.Id); |
|
|
|
} |
|
|
|
} |
|
|
|
#endregion |
|
|
|
#region 学生心理健康档案(APStuHealthRecords,新-写入,旧-删除;) |
|
|
|
var AspHistory = db.FindList<APStuHealthRecordsEntity>(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<APStuHealthRecordsEntity>(x => x.ID == items.ID); |
|
|
|
} |
|
|
|
} |
|
|
|
#endregion |
|
|
|
#region 兵役一(MSRIntentionManagement,新-写入,旧-删除;) |
|
|
|
var MSRIntentionHistory = db.FindList<MSRIntentionManagementEntity>(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<MSRIntentionManagementEntity>(x => x.ID == items.ID); |
|
|
|
} |
|
|
|
} |
|
|
|
#endregion |
|
|
|
#region 兵役二(MSRMilitaryRecord,新-写入,旧-删除;) |
|
|
|
var MSRMilitaryRecordHistory = db.FindList<MSRMilitaryRecordEntity>(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<MSRMilitaryRecordEntity>(x => x.ID == items.ID); |
|
|
|
} |
|
|
|
} |
|
|
|
#endregion |
|
|
|
#region 兵役三(MSRMilitaryServiceRegistration,新-写入,旧-删除;) |
|
|
|
var MSRMilitaryServiceRegistrationHistory = db.FindList<MSRMilitaryServiceRegistrationEntity>(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<MSRMilitaryRecordEntity>(x => x.ID == items.ID); |
|
|
|
} |
|
|
|
} |
|
|
|
#endregion |
|
|
|
#region 奖励(StuEncourgement,新-写入,旧-删除;) |
|
|
|
var StuEncourgementHistory = db.FindList<StuEncourgementEntity>(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<StuEncourgementEntity>(x => x.ID == items.ID); |
|
|
|
} |
|
|
|
} |
|
|
|
#endregion |
|
|
|
#region 处分(StuPunishment,新-写入,旧-删除;) |
|
|
|
var StuPunishmentHistory = db.FindList<StuPunishmentEntity>(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<StuPunishmentEntity>(x => x.Id == items.Id); |
|
|
|
} |
|
|
|
} |
|
|
|
#endregion |
|
|
|
|
|
|
|
if (upTrua.AnomalousType == "01" || upTrua.AnomalousType == "07" || upTrua.AnomalousType == "08") |
|
|
|