Skip to content
Snippets Groups Projects
Commit f45516fe authored by PavelBegunkov's avatar PavelBegunkov
Browse files

result

parent 97070e55
Branches
Tags
No related merge requests found
......@@ -247,6 +247,8 @@ class Controller_Teacher_Rating extends Controller_UserEnvi {
$rateHandled[$i_g]['Students'][$i_s]['Rates'][$i_r]['Rate'] = $r['Rate'];
}
$rateHandled[$i_g]['Students'][$i_s]['RateResult'] += $examRate;
$total = $db->GetStudentRate($row['ID'], $id);
$rateHandled[$i_g]['Students'][$i_s]['RateSemesterResult'] = $total - $rateHandled[$i_g]['Students'][$i_s]['RateResult'];
}
......
......@@ -43,5 +43,11 @@ class Model_Teacher_Rating extends Model
$sql = "SELECT `SetStudentRate`('$teacherID', '$studentID', '$submoduleID', '$rate') AS `Num`;";
return DB::query(Database::SELECT, $sql)->execute();
}
public function GetStudentRate($studentID, $disciplineID)
{
$sql = "SELECT `GetRateForDisc`('$studentID', '$disciplineID') AS `Num`;";
return DB::query(Database::SELECT, $sql)->execute();
}
}
......@@ -30,6 +30,7 @@
{{ headerRate[i].ModuleTitle }}
</td>
{% endfor %}
<td class="subject" rowspan="3">Итог за семестр</td>
<td class="subject" rowspan="3">Итог</td>
</tr>
<tr class="RatingTableSubmodulesHead">
......@@ -76,7 +77,8 @@
<input type="text" value="{{ student.Rates[i].Rate }}">
</td>
{% endfor %}
<td class="row_{{ row }} col_{{ i + 1 }} RateResult">{{ student.RateResult }}</td>
<td class="row_{{ row }} col_{{ i + 1 }}">{{ student.RateSemesterResult }}</td>
<td class="row_{{ row }} col_{{ i + 2 }} RateResult">{{ student.RateResult }}</td>
</tr>
{% endfor %}
{% endfor %}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment