|
|
@@ -266,7 +266,7 @@ on k.Assessment=e.Assessment |
|
|
|
/// </summary> |
|
|
|
/// <param name="Assessed"></param> |
|
|
|
/// <param name="Status">1 提交,2通过,3未通过</param> |
|
|
|
public void UpdateStatusForZP(string Assessed, int Status) |
|
|
|
public void UpdateStatusForZP(string Id, int Status) |
|
|
|
{ |
|
|
|
var db = this.BaseRepository("CollegeMIS"); |
|
|
|
try |
|
|
@@ -276,21 +276,21 @@ on k.Assessment=e.Assessment |
|
|
|
{ |
|
|
|
//提交 修改主表自评分值 |
|
|
|
string updSql = $@" update DT_EvaluationDataMain set ScoreZP=( |
|
|
|
select MAX(Score) from DT_EvaluationData where Assessed = '{Assessed}' and ScoreType = 1 |
|
|
|
select SUM(Score) from DT_EvaluationData where MainId = '{Id}' and ScoreType = 1 |
|
|
|
) |
|
|
|
where BeAssessed = '{Assessed}'"; |
|
|
|
where Id = '{Id}'"; |
|
|
|
|
|
|
|
db.ExecuteBySql(updSql); |
|
|
|
} |
|
|
|
else if (Status == 3) |
|
|
|
{ |
|
|
|
//审核未通过 修改主表 自评分值为NULL |
|
|
|
string updSql = $@" update DT_EvaluationDataMain set ScoreZP=NULL where BeAssessed = '{Assessed}'"; |
|
|
|
string updSql = $@" update DT_EvaluationDataMain set ScoreZP=NULL where Id = '{Id}'"; |
|
|
|
db.ExecuteBySql(updSql); |
|
|
|
Status = 0; |
|
|
|
} |
|
|
|
string sql = |
|
|
|
$"update DT_EvaluationData set Status='{Status}' where ScoreType=1 and Assessed='{Assessed}'"; |
|
|
|
$"update DT_EvaluationData set Status='{Status}' where ScoreType=1 and MainId = '{Id}'"; |
|
|
|
db.ExecuteBySql(sql); |
|
|
|
|
|
|
|
db.Commit(); |
|
|
|