Example #1
0
    echo html_writer::start_tag('form', array('action' => '.', 'method' => 'get'));
    echo html_writer::start_tag('div');
    echo html_writer::empty_tag('input', array('type' => 'hidden', 'id' => 'completion_dynamic_change', 'name' => 'completion_dynamic_change', 'value' => '0'));
    echo html_writer::end_tag('div');
    echo html_writer::end_tag('form');
}
// Course wrapper start.
echo html_writer::start_tag('div', array('class' => 'course-content'));
// make sure that section 0 exists (this function will create one if it is missing)
course_create_sections_if_missing($course, 0);
// get information about course modules and existing module types
// format.php in course formats may rely on presence of these variables
$modinfo = get_fast_modinfo($course);
$modnames = get_module_types_names();
$modnamesplural = get_module_types_names(true);
$modnamesused = $modinfo->get_used_module_names();
$mods = $modinfo->get_cms();
$sections = $modinfo->get_section_info_all();
// CAUTION, hacky fundamental variable defintion to follow!
// Note that because of the way course fromats are constructed though
// inclusion we pass parameters around this way..
$displaysection = $section;
// Include the actual course format.
require $CFG->dirroot . '/course/format/' . $course->format . '/format.php';
// Content wrapper end.
echo html_writer::end_tag('div');
// Include course AJAX
include_course_ajax($course, $modnamesused);
echo $OUTPUT->footer();
echo $OUTPUT->box(checkAlerts($USER->id, getGroupID($USER->id)));
Example #2
0
$formatoptions->noclean = true;
$formatoptions->overflowdiv = true;
$formatoptions->context = $context;
$members = array();
$tasks = array();
$members = getGroupMembers($currentgroup);
//Get group members of the group, ID's and last access
$tasks = getGroupsTasks($currentgroup);
$history = getGroupChatHistory($currentgroup);
//Get Group chat history
$html = "";
// Initiate blank HTML to create the screen.
//Alert Section - When loading the module, check for any alerts for the user/group
if ($currentgroup != 0) {
    //make sure a student belongs to a group
    $html .= checkAlerts($USER->id, $currentgroup);
}
//Draw the screen
//Left side is the project side, Start with listing all the tasks
$html .= "<table border=1 width=80%><tr><td style='vertical-align:top;'><table><tr><td><u>List of Tasks</u><br /><br /><a href='task_edit.php?cmid=" . $id . "'>+ NEW TASK</a><br /><br />";
foreach ($tasks as $task) {
    $name = getStudentName($task->members);
    //Get users assigned to the task
    //If the task is complete, display a checkmark
    if ($task->progress == 100) {
        $html .= "<img src='pix/Check_mark.png'' width='12px' height='12px' />";
    }
    //Display the task name, link and edit
    $html .= " Task: <a href='task_view.php?cmid=" . $id . "&id=" . $id . "&t=" . $task->id . "'>" . $task->name . "</a> <a href='task_edit.php?cmid=" . $id . "&id=" . $id . "&t=" . $task->id . "'><img src='pix/settings.png'' width='12px' height='12px' /></a><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;For: ";
    //Find and display all the users assigned to the task
    $name_size = count($name);
Example #3
0
    echo html_writer::empty_tag('input', array('type' => 'hidden', 'id' => 'completion_dynamic_change', 'name' => 'completion_dynamic_change', 'value' => '0'));
    echo html_writer::end_tag('div');
    echo html_writer::end_tag('form');
}
// Course wrapper start.
echo html_writer::start_tag('div', array('class' => 'course-content'));
// make sure that section 0 exists (this function will create one if it is missing)
course_create_sections_if_missing($course, 0);
// get information about course modules and existing module types
// format.php in course formats may rely on presence of these variables
$modinfo = get_fast_modinfo($course);
$modnames = get_module_types_names();
$modnamesplural = get_module_types_names(true);
$modnamesused = $modinfo->get_used_module_names();
$mods = $modinfo->get_cms();
$sections = $modinfo->get_section_info_all();
// CAUTION, hacky fundamental variable defintion to follow!
// Note that because of the way course fromats are constructed though
// inclusion we pass parameters around this way..
$displaysection = $section;
// Include the actual course format.
require $CFG->dirroot . '/course/format/' . $course->format . '/format.php';
// Content wrapper end.
echo html_writer::end_tag('div');
// Include course AJAX
include_course_ajax($course, $modnamesused);
echo $OUTPUT->footer();
$groupid = getGroupID($USER->id);
if (isset($groupid[$USER->id]->groupid)) {
    echo $OUTPUT->box(checkAlerts($USER->id, $groupid[$USER->id]->groupid));
}