]> git.mjollnir.org Git - moodle.git/commitdiff
Replacing deprecated print_user_picture()
authorDavid Mudrak <david.mudrak@gmail.com>
Mon, 4 Jan 2010 17:50:13 +0000 (17:50 +0000)
committerDavid Mudrak <david.mudrak@gmail.com>
Mon, 4 Jan 2010 17:50:13 +0000 (17:50 +0000)
mod/workshop/allocation/manual/allocator.php
mod/workshop/allocation/manual/renderer.php

index ff3f691f78a5f247f26cbdc6815d94beed4a151c..2c31d55aec84502a014d19c2e4152f337e0e1c94 100644 (file)
@@ -200,8 +200,6 @@ class workshop_manual_allocator implements workshop_allocator {
                 $peer[$currentuserid]->lastname         = $allocation->authorlastname;
                 $peer[$currentuserid]->picture          = $allocation->authorpicture;
                 $peer[$currentuserid]->imagealt         = $allocation->authorimagealt;
-                $peer[$currentuserid]->avatar           = print_user_picture($peer[$currentuserid],
-                                                                            $this->workshop->course, null, 16, true);
                 $peer[$currentuserid]->submissionid     = $allocation->submissionid;
                 $peer[$currentuserid]->submissiontitle  = $allocation->submissiontitle;
                 $peer[$currentuserid]->submissiongrade  = $allocation->submissiongrade;
index 5178a4c9786f41a7ca7b0f3b243b4953436769fb..f4ca0bb826422084ee797cebe529e163ffcac1d3 100644 (file)
@@ -99,7 +99,7 @@ class moodle_mod_workshop_allocation_manual_renderer extends moodle_renderer_bas
      * @return string HTML code
      */
     protected function participant(stdClass $user) {
-        $o  = print_user_picture($user, $this->page->course->id, null, 35, true);
+        $o  = $this->output->user_picture($user, $this->page->course->id);
         $o .= fullname($user);
         $o .= $this->output->container_start(array('submission'));
         if (is_null($user->submissionid)) {
@@ -144,7 +144,7 @@ class moodle_mod_workshop_allocation_manual_renderer extends moodle_renderer_bas
         $o .= $this->output->output_start_tag('ul', array());
         foreach ($user->reviewedby as $reviewerid => $assessmentid) {
             $o .= $this->output->output_start_tag('li', array());
-            $o .= print_user_picture($peers[$reviewerid], $this->page->course->id, null, 16, true);
+            $o .= $this->output->user_picture($peers[$reviewerid], $this->page->course->id); // todo display smaller
             $o .= fullname($peers[$reviewerid]);
 
             $handler = $this->page->url->out_action(array('mode' => 'del', 'what' => $assessmentid));
@@ -182,7 +182,7 @@ class moodle_mod_workshop_allocation_manual_renderer extends moodle_renderer_bas
         $o .= $this->output->output_start_tag('ul', array());
         foreach ($user->reviewerof as $authorid => $assessmentid) {
             $o .= $this->output->output_start_tag('li', array());
-            $o .= print_user_picture($peers[$authorid], $this->page->course->id, null, 16, true);
+            $o .= $this->output->user_picture($peers[$authorid], $this->page->course->id); // todo display smaller
             $o .= fullname($peers[$authorid]);
 
             // delete