function _Group::load_descriptive_data
Search API
4.x _Group.php | _Group::load_descriptive_data() |
5.x _Group.php | _Group::load_descriptive_data() |
1 call to _Group::load_descriptive_data()
- _Group::load_group in classes/
_Group.php
File
- classes/
_Group.php, line 524
Class
Code
function load_descriptive_data()
{
$cur = null;
static $group_descriptive_data_cache = array();
if (isset($group_descriptive_data_cache [$this->get_db_group_id()])) {
$cur = $group_descriptive_data_cache [$this->get_db_group_id()];
}
else {
$table_name = "groups";
if ($this->bool_use_draft) {
$table_name = "draft_$table_name";
}
// Load information about the group's title, icon, etc.
$res = db_query("SELECT *
FROM `$table_name`
WHERE group_id = ? ", $this->get_db_group_id());
$cur = db_fetch_array($res);
$group_descriptive_data_cache [$this->get_db_group_id()] = $cur;
}
$this->title = trim($cur ["title"]);
$this->icon_filename = trim($cur ["icon_filename"]);
$this->group_name = trim($cur ["group_name"]);
$this->data_entry_comment = trim($cur ["data_entry_comment"]);
$this->priority = trim($cur ["priority"]);
$this->definition = trim($cur ["definition"]);
$this->db_delete_flag = trim($cur ["delete_flag"]);
$this->db_catalog_repeat = trim($cur ["catalog_repeat"]);
$this->catalog_year = trim($cur ["catalog_year"]);
if ($this->group_id == -88)
{
$this->title = "Add an Additional Course";
}
}