Commit b312eb5f authored by DELARUELLE Myriam's avatar DELARUELLE Myriam
Browse files

Merge branch 'dev'

parents f9952738 76b05d5c
......@@ -93,7 +93,13 @@ class block_mahara_iena extends block_base
// for teachers and students
if (count($result) == 0) {
$this->content->text .= '<button type="button" class="btn btn-block btn-primary iena-btn-big" disabled >'.get_string('acces_group', 'block_mahara_iena', $CFG->mahara_alias).'</button><p class="text-muted">Aucun groupe '.$CFG->mahara_alias.' n\'a encore été créé par l\'enseignant.</p>';
if(!isset($this->content->text)){
$this->content->text='<button type="button" class="btn btn-block btn-primary iena-btn-big" disabled >'.get_string('acces_group', 'block_mahara_iena', $CFG->mahara_alias).'</button><p class="text-muted">Aucun groupe '.$CFG->mahara_alias.' n\'a encore été créé par l\'enseignant.</p>';
}
else{
$this->content->text .= '<button type="button" class="btn btn-block btn-primary iena-btn-big" disabled >'.get_string('acces_group', 'block_mahara_iena', $CFG->mahara_alias).'</button><p class="text-muted">Aucun groupe '.$CFG->mahara_alias.' n\'a encore été créé par l\'enseignant.</p>';
}
}
elseif ($is_mahara_user) {
// check if they are one mahara group per moodle group of juste one group and set link
......
......@@ -5,7 +5,7 @@
* Date: 11/04/18
* Time: 16:23
*/
require_once('lib.php');
require_once($CFG->dirroot.'/blocks/mahara_iena/lib.php');
class block_mahara_iena_connexion
{
......@@ -339,11 +339,10 @@ class block_mahara_iena_connexion
// $mo_user_group_id = $mo_user_groups[0][0];
$mo_user_group_id = $mo_group_id;
$mo_group_name = groups_get_group_name($mo_user_group_id);
$course_name=block_mahara_iena_getCourseName($COURSE->shortname);
$group = new stdClass();
$group->name = get_string('course_group', 'block_mahara_iena') . " " . $course_name . " – " . $mo_group_name;
$course_name=block_mahara_iena_getCourseName($COURSE->shortname);
//$group->name = get_string('course_group', 'block_mahara_iena') . " " . $course_name . " – " . $mo_group_name;
$group->name=$course_name . " – " . $mo_group_name;
$group->description = get_string('course_group', 'block_mahara_iena') . " " . $course_name . " – " . $mo_group_name;
$group->grouptype = 'course';
$group->request = true;
......@@ -356,6 +355,7 @@ class block_mahara_iena_connexion
$group->members = array(
0 => $user
);
$group->editroles="all";
$params = array (
'groups' =>
array (
......
......@@ -76,7 +76,6 @@ if (count($students) == 0) {
));
}
$course_name=block_mahara_iena_getCourseName($COURSE->shortname);
//All params used for mahara_group_create_groups her we can add/change some lines
$params = array (
'groups' =>
......
......@@ -76,7 +76,6 @@ if (count($students) == 0) {
}
$course_name=block_mahara_iena_getCourseName($COURSE->shortname);
array_push($mahara_groups, array(
'name' =>$course_name . " – " . $group->name,
'description' => get_string('course_group', 'block_mahara_iena') . " " . $course_name . " – " . $group->name,
......
......@@ -28,7 +28,7 @@
*/
defined('MOODLE_INTERNAL') || die();
$plugin->version = 2021102500;
$plugin->version = 2022062700;
$plugin->requires = 2014051200;
$plugin->component = 'block_mahara_iena';
$plugin->release = 'v1.0';
......
Markdown is supported
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