Merge branch 'MDL-59459_Increase_file_indexing_coverage' of https://github.com/mattporritt/moodle

This commit is contained in:
Dan Poltawski 2017-09-11 14:01:40 +01:00
commit 743c937dae
33 changed files with 765 additions and 68 deletions

View file

@ -35,7 +35,6 @@ defined('MOODLE_INTERNAL') || die();
*/
class activity extends \core_search\base_activity {
/**
* Returns the document associated with this activity.
*
@ -74,4 +73,25 @@ class activity extends \core_search\base_activity {
return $doc;
}
/**
* Returns true if this area uses file indexing.
*
* @return bool
*/
public function uses_file_indexing() {
return true;
}
/**
* Return the context info required to index files for
* this search area.
*
* @return array
*/
public function get_search_fileareas() {
$fileareas = array('intro', 'content'); // Fileareas.
return $fileareas;
}
}