equal
deleted
inserted
replaced
5 * |
5 * |
6 */ |
6 */ |
7 |
7 |
8 namespace bfw\mvc\model\dokumentation; |
8 namespace bfw\mvc\model\dokumentation; |
9 |
9 |
10 use bfw\core\Entity; |
|
11 use bfw\core\Model; |
10 use bfw\core\Model; |
12 use bfw\entities\TGroup; |
|
13 use bfw\entities\TUser; |
|
14 |
11 |
15 class DataModel extends Model { |
12 class DataModel extends Model { |
16 |
13 |
17 private $user; |
|
18 private $group; |
|
19 |
|
20 /** |
|
21 * Model constructor. |
|
22 */ |
|
23 public function __construct() { |
|
24 $this->user = new TUser(); |
|
25 $this->group = new TGroup(); |
|
26 } |
|
27 |
|
28 /** |
|
29 * @return Entity[] |
|
30 */ |
|
31 public function getUsers() { |
|
32 return $this->user->findAll(); |
|
33 } |
|
34 |
|
35 /** |
|
36 * @return Entity[] |
|
37 */ |
|
38 public function getGroups() { |
|
39 return $this->group->findAll(); |
|
40 } |
|
41 |
|
42 } |
14 } |