MDL-26272 ratings - fix uses breaking after last modinfo changes

This commit is contained in:
Eloy Lafuente (stronk7)
2011-02-04 17:30:51 +01:00
parent 54b7b5993f
commit 195a0848ec
3 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -666,7 +666,7 @@ if ($showactivity) {
require_once($CFG->dirroot.'/rating/lib.php');
if ($data->assessed!=RATING_AGGREGATE_NONE) {
$ratingoptions = new stdclass();
$ratingoptions->context = $cm->context;
$ratingoptions->context = $context;
$ratingoptions->items = $records;
$ratingoptions->aggregate = $data->assessed;//the aggregation method
$ratingoptions->scaleid = $data->scale;
+1 -1
View File
@@ -5318,7 +5318,7 @@ function forum_print_discussion($course, $cm, $forum, $discussion, $post, $mode,
//load ratings
if ($forum->assessed!=RATING_AGGREGATE_NONE) {
$ratingoptions = new stdclass();
$ratingoptions->context = $cm->context;
$ratingoptions->context = $modcontext;
$ratingoptions->items = $posts;
$ratingoptions->aggregate = $forum->assessed;//the aggregation method
$ratingoptions->scaleid = $forum->scale;
+1 -1
View File
@@ -395,7 +395,7 @@ if ($allentries) {
require_once($CFG->dirroot.'/rating/lib.php');
if ($glossary->assessed!=RATING_AGGREGATE_NONE) {
$ratingoptions = new stdclass();
$ratingoptions->context = $cm->context;
$ratingoptions->context = $context;
$ratingoptions->items = $allentries;
$ratingoptions->aggregate = $glossary->assessed;//the aggregation method
$ratingoptions->scaleid = $glossary->scale;