Browse Source

招生 注册专业逆推专业部

临城职教中职
ndbs 3 years ago
parent
commit
d80c5710c0
1 changed files with 8 additions and 1 deletions
  1. +8
    -1
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuVolunteer/StuVolunteerService.cs

+ 8
- 1
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuVolunteer/StuVolunteerService.cs View File

@@ -755,13 +755,20 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
try
{
string DeptNo = "";
var CdMajorList = this.BaseRepository("CollegeMIS").FindEntity<CdMajorEntity>(x => x.CheckMark == true && x.MajorNo == MajorNo);
if (CdMajorList != null)
{
DeptNo = CdMajorList.DeptNo;
}

var Majorinfo = this.BaseRepository("CollegeMIS").FindEntity<CdMajorEntity>(x => x.MajorNo == MajorNo);
if (Majorinfo != null)
{
var arr = keyValue.Split(',').ToList();
foreach (var id in arr)
{
string sql = $"update StuVolunteer set MajorNo = '{MajorNo}',ClassNo = '', MajorStatus = 0 ,ClassStatus = 0 where ID='{id}' and (StuNo is null or len(StuNo)=0); update StuVolunteer set MajorNo='{MajorNo}', ClassNo = '', MajorStatus =0,ClassStatus=0 where ID='{id}' and (StuNo is not null or len(StuNo)>0)";
string sql = $"update StuVolunteer set MajorNo = '{MajorNo}',ClassNo = '',DeptNo = '{DeptNo}', MajorStatus = 0 ,ClassStatus = 0 where ID='{id}' and (StuNo is null or len(StuNo)=0); update StuVolunteer set MajorNo='{MajorNo}', ClassNo = '',DeptNo = '{DeptNo}', MajorStatus =0,ClassStatus=0 where ID='{id}' and (StuNo is not null or len(StuNo)>0)";
this.BaseRepository("CollegeMIS").ExecuteBySql(sql);
}
}


Loading…
Cancel
Save