Commit 983789a9f5e6906cb0e7344f6efcf52b0335f1c7
1 parent
f36f89e3
registration
Showing
1 changed file
with
8 additions
and
0 deletions
Show diff stats
app/library/App/Model/User.php
@@ -24,4 +24,12 @@ class User extends \App\Mvc\DateTrackingModel | @@ -24,4 +24,12 @@ class User extends \App\Mvc\DateTrackingModel | ||
24 | 'password' => 'password' | 24 | 'password' => 'password' |
25 | ]; | 25 | ]; |
26 | } | 26 | } |
27 | + | ||
28 | + public function initialize() | ||
29 | + { | ||
30 | + $this->hasMany('id', Project::class, 'user_id', [ | ||
31 | + 'alias' => 'Projects', | ||
32 | + ]); | ||
33 | + } | ||
34 | + | ||
27 | } | 35 | } |