Example #1
0
 public static function projList($user)
 {
     $lists = array();
     // matched project
     $matched = Model\Project::ofmatched($user->skills);
     if (!empty($matched)) {
         $lists['matched_projects'] = Listing::get($matched);
     }
     // mis proyectos
     $projects = Model\Project::ofmine($user->id);
     if (!empty($projects)) {
         $lists['my_projects'] = Listing::get($projects);
     }
     // proyectos que cofinancio
     $invested = Model\User::invested($user->id, false);
     if (!empty($invested)) {
         $lists['invest_on'] = Listing::get($invested);
     }
     return $lists;
 }