* [story#74954] fix bug for gitlab project.
This commit is contained in:
@@ -690,7 +690,7 @@ class gitlab extends control
|
||||
$groups = $this->gitlab->apiGetGroups($gitlabID, 'name_asc', 'maintainer');
|
||||
foreach($groups as $group) $groupIDList[] = $group->id;
|
||||
|
||||
foreach($result['projects'] as $key => $project)
|
||||
foreach($result['projects'] as $project)
|
||||
{
|
||||
$project->adminer = (bool)$this->app->user->admin;
|
||||
if(!$project->adminer and isset($project->owner) and $project->owner->id == $openID) $project->adminer = true;
|
||||
|
||||
@@ -639,6 +639,7 @@ class gitlabModel extends model
|
||||
|
||||
$this->app->loadClass('pager', true);
|
||||
$pager = pager::init($recTotal, $recPerPage, $pager->pageID);
|
||||
if(empty($recTotal)) return array('pager' => $pager, 'projects' => array());
|
||||
|
||||
return array('pager' => $pager, 'projects' => json_decode($result['body']));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user