Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- * @param int advisors id
- * @return array
- * @final
- */
- final public function getClients($advisors = null) {
- $fluent = $this->db->select('id')
- ->select("CONCAT_WS(' ', titul, prijmeni, jmeno) AS klient")
- ->select("IFNULL(klient, nazevSpolecnosti) as klient")
- ->select("CONCAT_WS(' ', id, klient) as klient")
- ->from(self::clientsTable);
- if($advisors != null) {
- $fluent->where('poradce = %i', $advisors);
- }
- return $fluent->OrderBy('zalozen DESC')->fetchPairs('id', 'klient');
- }
Advertisement
Add Comment
Please, Sign In to add comment