function _DegreePlan::__construct
Search API
4.x _DegreePlan.php | _DegreePlan::__construct($degree_id = "", DatabaseHandler $db = NULL, $bool_load_minimal = false, $array_significant_courses = false, $bool_use_draft = false) |
5.x _DegreePlan.php | _DegreePlan::__construct($degree_id = "", DatabaseHandler $db = NULL, $bool_load_minimal = FALSE, $array_significant_courses = FALSE, $bool_use_draft = FALSE) |
File
- classes/
_DegreePlan.php, line 36
Class
Code
function __construct($degree_id = "", DatabaseHandler $db = NULL, $bool_load_minimal = false, $array_significant_courses = false, $bool_use_draft = false)
{
$this->list_semesters = new ObjList();
$this->list_groups = new GroupList();
$this->bool_use_draft = $bool_use_draft;
// Always override if the global variable is set.
if ($GLOBALS ["fp_advising"]["bool_use_draft"] == true) {
$this->bool_use_draft = true;
}
$this->db = $db;
if ($db == NULL)
{
$this->db = get_global_database_handler();
}
$this->student_array_significant_courses = $array_significant_courses;
if ($degree_id != "")
{
$this->degree_id = $degree_id;
$this->load_descriptive_data();
if (!$bool_load_minimal)
{
$this->load_degree_plan();
}
// Add the "Add a Course" semester to the semester list.
$this->add_semester_courses_added();
}
}