* code for bug #58034.

This commit is contained in:
wangyidong
2022-06-21 14:53:45 +08:00
parent 63cb3033df
commit 541f9dd0d1
2 changed files with 16 additions and 10 deletions
+11 -10
View File
@@ -33,16 +33,6 @@ class api extends control
*/
public function index($libID = 0, $moduleID = 0, $apiID = 0, $version = 0, $release = 0, $appendLib = 0)
{
/* Get all api doc libraries. */
$libs = $this->doc->getApiLibs($appendLib);
if($libID == 0 and !empty($libs)) $libID = key($libs);
$lib = $this->doc->getLibById($libID);
$appendLib = (!empty($lib) and $lib->deleted == '1') ? $libID : 0;
/* Generate bread crumbs dropMenu. */
if($libs) $this->lang->modulePageNav = $this->generateLibsDropMenu($libs, $libID, $release);
/* Get an api doc. */
if($apiID > 0)
{
@@ -69,6 +59,17 @@ class api extends control
$this->view->typeList = $this->api->getTypeList($libID);
}
/* Get all api doc libraries. */
$libs = $this->doc->getApiLibs($appendLib);
if($libID == 0 and $apiID > 0) $libID = $api->lib;
if($libID == 0 and !empty($libs)) $libID = key($libs);
$lib = $this->doc->getLibById($libID);
$appendLib = (!empty($lib) and $lib->deleted == '1') ? $libID : 0;
/* Generate bread crumbs dropMenu. */
if($libs) $this->lang->modulePageNav = $this->generateLibsDropMenu($libs, $libID, $release);
$this->setMenu($libID, $moduleID);
$this->view->lib = $lib;