I have two different activity
modules
, the first is a standard Moodle
module and the second is developed by me.
In each of them we have
mod/moodlemodule/rb_sources/rb_source_moodlemodule_presence.php
mod/newmodule/rb_sources/rb_source_newmodule_presence.php
Each one of them has the following standard functions(the code is shortened):
protected function define_columnoptions() {
global $DB;
$usernamefieldscreator = totara_get_all_user_name_fields_join('creator');
$usernamefieldsbooked = totara_get_all_user_name_fields_join('bookedby');
$columnoptions = array(
new rb_column_option(
protected function define_filteroptions() {
$filteroptions = array(
new rb_filter_option(
public function rb_filter_position_types_list() {
global $CFG, $POSITION_TYPES;
include_once($CFG->dirroot.'/totara/hierarchy/prefix/position/lib.php');
return $POSITION_TYPES;
}
protected function define_contentoptions() {
$contentoptions = array(
new rb_content_option(
protected function define_paramoptions() {
$paramoptions = array(
new rb_param_option(
protected function define_defaultcolumns() {
$defaultcolumns = array(
array(
protected function define_requiredcolumns() {
$requiredcolumns = array();
$requiredcolumns[] = new rb_column(
protected function define_defaultfilters() {
$defaultfilters = array(
array(
They can be found in every report file of the activity modules and they deliver the same data (as they are standards in almost every other module):
name
startdate
finishdate
address
coursename
Is it possible to add the data from the both reports in one single report and display it? And how to structure the code inside the new rb_source file?