Proyectos de Subversion Moodle

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 1441
Línea 49... Línea 49...
49
        }
49
        }
50
        if (!array_key_exists($data, $this->choices)) {
50
        if (!array_key_exists($data, $this->choices)) {
51
            return '';
51
            return '';
52
        }
52
        }
Línea 53... Línea -...
53
 
-
 
54
        // Calling it here without checking if it is ready because we check it below and show it as a controlled case.
-
 
55
        $selectedprocessor = \core_analytics\manager::get_predictions_processor($data, false);
-
 
56
        $isready = $selectedprocessor->is_ready();
-
 
57
        if ($isready !== true) {
-
 
58
            return get_string('errorprocessornotready', 'analytics', $isready);
-
 
59
        }
-
 
60
 
53
 
61
        $currentvalue = get_config('analytics', 'predictionsprocessor');
54
        $currentvalue = get_config('analytics', 'predictionsprocessor');
62
        if (!empty($currentvalue) && $currentvalue != str_replace('\\\\', '\\', $data)) {
55
        if (!empty($currentvalue) && $currentvalue != str_replace('\\\\', '\\', $data)) {
63
            // Clear all models data.
56
            // Clear all models data.
64
            $models = \core_analytics\manager::get_all_models();
57
            $models = \core_analytics\manager::get_all_models();