diff --git a/module/repo/config/dtable.php b/module/repo/config/dtable.php index 1ccab26d30..c8b1e3ab82 100644 --- a/module/repo/config/dtable.php +++ b/module/repo/config/dtable.php @@ -45,7 +45,11 @@ $config->repo->dtable->fieldList['actions']['name'] = 'actions'; $config->repo->dtable->fieldList['actions']['title'] = $lang->actions; $config->repo->dtable->fieldList['actions']['type'] = 'actions'; $config->repo->dtable->fieldList['actions']['width'] = '132'; -$config->repo->dtable->fieldList['actions']['menu'] = array('execJob', 'reportView', 'edit', 'delete'); +$config->repo->dtable->fieldList['actions']['menu'] = array('visit', 'execJob', 'reportView', 'edit', 'delete'); + +$config->repo->dtable->fieldList['actions']['list']['visit']['icon'] = 'menu-my'; +$config->repo->dtable->fieldList['actions']['list']['visit']['hint'] = $lang->repo->visit; +$config->repo->dtable->fieldList['actions']['list']['visit']['target'] = '_blank'; $config->repo->dtable->fieldList['actions']['list']['edit']['icon'] = 'edit'; $config->repo->dtable->fieldList['actions']['list']['edit']['hint'] = $lang->repo->edit; diff --git a/module/repo/ui/maintain.html.php b/module/repo/ui/maintain.html.php index 1507b5277a..01553a32c3 100644 --- a/module/repo/ui/maintain.html.php +++ b/module/repo/ui/maintain.html.php @@ -50,9 +50,25 @@ foreach($repoList as $repo) $config->repo->dtable->fieldList['name']['link'] = $this->createLink('repo', 'browse', "repoID={id}&branchID=&objectID={$objectID}"); $config->repo->dtable->fieldList['actions']['list']['edit']['url'] = $this->createLink('repo', 'edit', "repoID={id}&objectID={$objectID}"); +if(empty($config->repo->maintain->hideRepoPath)) +{ + unset($config->repo->dtable->fieldList['path']); + $config->repo->dtable->fieldList['product']['width'] = '0.2'; + $config->repo->dtable->fieldList['scm']['width'] = '0.2'; + $config->repo->dtable->fieldList['lastSubmit']['width'] = '0.2'; +} + $repos = initTableData($repoList, $config->repo->dtable->fieldList, $this->repo); $queryMenuLink = createLink('repo', 'maintain', "objectID=$objectID&orderBy=&recTotal={$pager->recTotal}&pageID={$pager->pageID}&type=bySearch¶m={queryID}"); +/* Process data which the function initTableData() not provided. */ +foreach($repos as $repo) +{ + /* Set the url and check status for visiting the repo. */ + $repo->actions[0]['disabled'] = strpos($repo->path, 'http') === false; + $repo->actions[0]['url'] = $repo->path; +} + \zin\featureBar ( set::current('all'),