Hi, I’m trying to figure out how I can load a list of user id and usernames from Joomla’s default database. So far, using this forum and the documentations, I wrote some custom code and modified some of the source code to try to get it working…
Here’s my scheduler_include.html code for the lightbox form.
...
scheduler.config.lightbox.sections=[
{
name: "tech",
type:"select",
map_to: "tech_id",
options: scheduler.serverList("tech"),
focus: true
},
...
]
And then here are the relevant dhtmlxSchedulerConfigurator.php code for loading server-side data.
public function getEventsRec($usergroups) {
...
$this->scheduler->event->attach("beforeRender", Array($this, "posts_table_builder"));
$this->scheduler->event->attach("beforeRender", grab_users()); // my custom code
...
}
private function grab_users() { // this is at the bottom of dhtmlxSchedulerConfigurator.php script
$techList = new OptionsConnector($this->connection);
$techList->render_table("hvh_users", "id", "id,username");
$this->scheduler->set_options("tech", $techList);
}
So far I can’t get my “Tech” select menu to output a list of Joomla’s registered users. Any idea how I can get it working?