Proyectos de Subversion Moodle

Rev

Rev 118 | Rev 122 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 118 Rev 121
Línea 33... Línea 33...
33
        $this->title = get_string('pluginname', 'block_comments');
33
        $this->title = get_string('pluginname', 'block_comments');
34
    }
34
    }
Línea 35... Línea 35...
35
 
35
 
36
    function specialization()
36
    function specialization()
37
    {
37
    {
38
        global $CFG, $DB;
-
 
39
        if (empty($this->config)) {
-
 
40
            $this->instance->defaultregion = 'below-content';
-
 
41
            $this->instance->region = 'below-content';
-
 
42
            $DB->update_record('block_instances', $this->instance);
-
 
43
 
-
 
44
            $this->title = 'Students comments';
-
 
45
        } else {
-
 
46
            $this->title = get_string('pluginname', 'block_comments');
-
 
47
        }
38
        comment::init()
Línea 48... Línea 39...
48
    }
39
    }
49
 
40
 
-
 
41
    function applicable_formats()
50
    function applicable_formats()
42
    {
-
 
43
        return [
51
    {
44
            'course-view' => true,
Línea 52... Línea 45...
52
        return array('all' => true);
45
        ];
53
    }
46
    }
54
 
47