Skip to content
Snippets Groups Projects
Commit 5106ae7f authored by Peter Rotich's avatar Peter Rotich
Browse files

Add routine to get departments 'managed' by the staff

parent 71bb0003
Branches
Tags
No related merge requests found
...@@ -214,6 +214,13 @@ class Staff { ...@@ -214,6 +214,13 @@ class Staff {
function getDepts() { function getDepts() {
return $this->getDepartments(); return $this->getDepartments();
} }
function getManagedDepartments() {
return ($depts=Dept::getDepartments(
array('manager' => $this->getId())
))?array_keys($depts):array();
}
function getGroupId() { function getGroupId() {
return $this->ht['group_id']; return $this->ht['group_id'];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment