Ver a proveniência

学籍异动插入数据报错

怀来职教中心中职
ndbs há 1 ano
ascendente
cometimento
0130ca0b57
2 ficheiros alterados com 20 adições e 19 eliminações
  1. +7
    -7
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuTransferInfo/ReturnIndex.js
  2. +13
    -12
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuTransferInfo/StuTransferInfoService.cs

+ 7
- 7
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuTransferInfo/ReturnIndex.js Ver ficheiro

@@ -411,9 +411,9 @@ var bootstrap = function ($, learun) {
//{ label: "入学年月", name: "EntranceDate", width: 100, align: "left" },
//{ label: "余额", name: "Balance", width: 100, align: "left" },
{ label: "家庭地址", name: "MailAddress", width: 100, align: "left" },
{ label: "联系电话", name: "mobile", width: 100, align: "left" },
{ label: "户口所在地", name: "FatherUnit", width: 100, align: "left" },
{ label: "档案所在地", name: "MatherUnit", width: 100, align: "left" },
{ label: "联系电话", name: "Mobile", width: 100, align: "left" },
{ label: "户口所在地", name: "ResidencePlace", width: 100, align: "left" },
{ label: "档案所在地", name: "LocationFile", width: 100, align: "left" },
{
label: "操作", name: "Delete", width: 100, align: "center",
formatter: function (callback, cellvalue, row, op, $cell) {
@@ -454,7 +454,7 @@ var bootstrap = function ($, learun) {
{ label: "学号", name: "StuNo", width: 100, align: "left" },
{ label: "姓名", name: "StuName", width: 100, align: "left" },
{
label: "性别", name: "GenderNo", width: 80, align: "left",
label: "性别", name: "Gender", width: 80, align: "left",
formatter: function (cellvalue) {
return cellvalue == true ? "男" : "女";
}
@@ -568,9 +568,9 @@ var bootstrap = function ($, learun) {
//{ label: "入学年月", name: "EntranceDate", width: 100, align: "left" },
//{ label: "余额", name: "Balance", width: 100, align: "left" },
{ label: "家庭地址", name: "MailAddress", width: 100, align: "left" },
{ label: "联系电话", name: "mobile", width: 100, align: "left" },
{ label: "户口所在地", name: "FatherUnit", width: 100, align: "left" },
{ label: "档案所在地", name: "MatherUnit", width: 100, align: "left" },
{ label: "联系电话", name: "Mobile", width: 100, align: "left" },
{ label: "户口所在地", name: "ResidencePlace", width: 100, align: "left" },
{ label: "档案所在地", name: "LocationFile", width: 100, align: "left" },
//{
// label: "五年一贯制", name: "FiveYear", width: 100, align: "left"
// , formatterAsync: function (callback, value, row, op, $cell) {


+ 13
- 12
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuTransferInfo/StuTransferInfoService.cs Ver ficheiro

@@ -449,7 +449,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
foreach (var itemScore in StuScoreHistory)
{
//插入新数据
db.ExecuteBySql(" insert into StuScoreTran select * from StuScore where Scoreid = '" + itemScore.ScoreId + "'");
db.ExecuteBySql(" insert into StuScoreTran select * from StuScore where Scoreid = '" + itemScore.ScoreId + "' and Scoreid not in ('" + itemScore.ScoreId + "')");
//删除旧数据
db.Delete<StuScoreEntity>(x => x.ScoreId == itemScore.ScoreId);
}
@@ -463,7 +463,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
foreach (var entity in StuSelectLessonListHistory)
{
//插入新数据
db.ExecuteBySql("insert into StuSelectLessonListTran select * from StuSelectLessonList where SelectId='" + entity.SelectId + "'");
db.ExecuteBySql("insert into StuSelectLessonListTran select * from StuSelectLessonList where SelectId='" + entity.SelectId + "' and SelectId not in ('" + entity.SelectId + "')");
//删除旧数据
db.Delete<StuSelectLessonListEntity>(x => x.SelectId == entity.SelectId);
}
@@ -477,7 +477,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
foreach (var entity in StuSelectLessonListOfElectiveHistory)
{
//插入新数据
db.ExecuteBySql("insert into StuSelectLessonListOfElectiveTran select * from StuSelectLessonListOfElective where Id='" + entity.Id + "'");
db.ExecuteBySql("insert into StuSelectLessonListOfElectiveTran select * from StuSelectLessonListOfElective where Id='" + entity.Id + "' and Id not in ('" + entity.Id + "')");
//修改旧数据:报名成功时,选课表中报名成功人数字段减一;
if (entity.Status == 2)
{
@@ -496,7 +496,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
foreach (var itemScore in StuScoreNotPassHistory)
{
db.ExecuteBySql(" insert into StuScoreNotPassTran select * from StuScoreNotPass where Scoreid = '" + itemScore.ScoreId + "'");
db.ExecuteBySql(" insert into StuScoreNotPassTran select * from StuScoreNotPass where Scoreid = '" + itemScore.ScoreId + "' and Scoreid not in ('" + itemScore.ScoreId + "')");
//删除旧数据
db.Delete<StuScoreNotPassTranEntity>(x => x.ScoreId == itemScore.ScoreId);
}
@@ -511,7 +511,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
foreach (var itemScore in StuScoreNotPassTwoHistory)
{
//插入数据
db.ExecuteBySql(" insert into StuScoreNotPassTwoTran select * from StuScoreNotPassTwo where Scoreid = '" + itemScore.ScoreId + "'");
db.ExecuteBySql(" insert into StuScoreNotPassTwoTran select * from StuScoreNotPassTwo where Scoreid = '" + itemScore.ScoreId + "' and Scoreid not in ('" + itemScore.ScoreId + "')");
//删除旧数据
db.Delete<StuScoreNotPassTwoTranEntity>(x => x.ScoreId == itemScore.ScoreId);
}
@@ -523,7 +523,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
foreach (var items in ScholarshipHistory)
{
db.ExecuteBySql(" insert into ScholarshipTran select * from ScholarshipAudit where id = '" + items.Id + "'");
db.ExecuteBySql(" insert into ScholarshipTran select * from ScholarshipAudit where id = '" + items.Id + "' and Id not in ('" + items.Id + "')");
// 删除旧数据
db.Delete<ScholarshipxjEntity>(x => x.Id == items.Id);
}
@@ -535,7 +535,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
foreach (var items in AspHistory)
{
db.ExecuteBySql(" insert into APStuHealthRecordsTran select * from APStuHealthRecords where ID = '" + items.ID + "'");
db.ExecuteBySql(" insert into APStuHealthRecordsTran select * from APStuHealthRecords where ID = '" + items.ID + "' and ID not in ('" + items.ID + "')");
// 删除旧数据
db.Delete<APStuHealthRecordsEntity>(x => x.ID == items.ID);
}
@@ -547,7 +547,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
foreach (var items in MSRIntentionHistory)
{
db.ExecuteBySql(" insert into MSRIntentionManagementTran select * from MSRIntentionManagement where ID = '" + items.ID + "'");
db.ExecuteBySql(" insert into MSRIntentionManagementTran select * from MSRIntentionManagement where ID = '" + items.ID + "' and ID not in ('" + items.ID + "')");
// 删除旧数据
db.Delete<MSRIntentionManagementEntity>(x => x.ID == items.ID);
}
@@ -559,7 +559,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
foreach (var items in MSRMilitaryRecordHistory)
{
db.ExecuteBySql(" insert into MSRMilitaryRecordTran select * from MSRMilitaryRecord where ID = '" + items.ID + "'");
db.ExecuteBySql(" insert into MSRMilitaryRecordTran select * from MSRMilitaryRecord where ID = '" + items.ID + "' and ID not in ('" + items.ID + "')");
// 删除旧数据
db.Delete<MSRMilitaryRecordEntity>(x => x.ID == items.ID);
}
@@ -571,7 +571,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
foreach (var items in MSRMilitaryServiceRegistrationHistory)
{
db.ExecuteBySql(" insert into MSRMilitaryServiceRegistrationTran select * from MSRMilitaryServiceRegistration where ID = '" + items.ID + "'");
db.ExecuteBySql(" insert into MSRMilitaryServiceRegistrationTran select * from MSRMilitaryServiceRegistration where ID = '" + items.ID + "' and ID not in ('" + items.ID + "')");
// 删除旧数据
db.Delete<MSRMilitaryRecordEntity>(x => x.ID == items.ID);
}
@@ -583,7 +583,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
foreach (var items in StuEncourgementHistory)
{
db.ExecuteBySql(" insert into StuEncourgementTran select * from StuEncourgement where ID = '" + items.ID + "'");
db.ExecuteBySql(" insert into StuEncourgementTran select * from StuEncourgement where ID = '" + items.ID + "' and ID not in ('" + items.ID + "')");
// 删除旧数据
db.Delete<StuEncourgementEntity>(x => x.ID == items.ID);
}
@@ -595,7 +595,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
foreach (var items in StuPunishmentHistory)
{
db.ExecuteBySql(" insert into StuPunishmentTran select * from StuPunishment where ID = '" + items.Id + "'");
db.ExecuteBySql(" insert into StuPunishmentTran select * from StuPunishment where ID = '" + items.Id + "' and ID not in ('" + items.Id + "')");
// 删除旧数据
db.Delete<StuPunishmentEntity>(x => x.Id == items.Id);
}
@@ -642,6 +642,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
upTrua.Remark = stulist.Remark;
upTrua.ResidencePlace = stulist.FatherUnit;
upTrua.LocationFile = stulist.MatherUnit;
upTrua.MailAddress = stulist.MailAddress;
}
#region 学籍操作
if (upTrua.StuStatus == 0) //如果保留学籍,basic不动;否则删除学籍basic,备份到basictran;


Carregando…
Cancelar
Guardar