...
|
...
|
@@ -53,7 +53,9 @@ class StudyScoreLog extends Model |
|
|
Db::startTrans();
|
|
|
try {
|
|
|
//得分加入学生表中
|
|
|
$study->allowField(true)->save(['earn_score'=>$stu['earn_score'] + $sum_score],['unique'=>$unique]);
|
|
|
$study->allowField(true)->save(['earn_score'=>$stu['earn_score'] + $sum_score],['id'=>$stu['id']]);
|
|
|
//得分加入战队表
|
|
|
$teams->allowField(true)->save(['score'=>$team['score'] + $sum_score],['id'=>$team['id']]);
|
|
|
//得分写入学生分数记录
|
|
|
$data = [
|
|
|
'item_id' => $id,
|
...
|
...
|
|