mirror of
https://github.com/RaspbianFrance/raspisms.git
synced 2025-06-06 06:46:25 +02:00
Transfer few methods from model database to propers tables models
This commit is contained in:
parent
f1170c82ea
commit
155cace466
6 changed files with 33 additions and 93 deletions
|
@ -58,6 +58,19 @@ namespace models;
|
|||
|
||||
return isset($contacts[0]) ? $contacts[0] : false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get contacts of a particular group
|
||||
*
|
||||
* @param int $id_group : Id of the group we want contacts for
|
||||
* @return array
|
||||
*/
|
||||
public function get_by_group($id_group)
|
||||
{
|
||||
$contacts = $this->_select('contact', ['id_group' => $id_group]);
|
||||
return $contacts;
|
||||
}
|
||||
|
||||
/**
|
||||
* Retourne une liste de contactes sous forme d'un tableau.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue