diff --git a/module/action/model.php b/module/action/model.php index 1f7af1059e..672844e097 100755 --- a/module/action/model.php +++ b/module/action/model.php @@ -1072,7 +1072,7 @@ class actionModel extends model /* Add name field to the actions. */ $action->objectName = isset($objectNames[$action->objectType][$action->objectID]) ? $objectNames[$action->objectType][$action->objectID] : ''; - if($action->objectType =='program' and strpos('syncexecution,syncproject,syncprogram', $action->action) !==false) + if($action->objectType == 'program' and strpos('syncexecution,syncproject,syncprogram', $action->action) !== false) { $action->objectName .= $this->lang->action->label->startProgram; } @@ -1319,9 +1319,9 @@ class actionModel extends model { $libID = $action->objectID; $type = 'custom'; - if($action->execution != 0) $type = 'execution'; - if($action->project != 0) $type = 'project'; - if($action->product != ',0,') $type = 'product'; + if(!empty($action->project)) $type = 'project'; + if(!empty($action->execution)) $type = 'execution'; + if(!empty($action->product)) $type = 'product'; $libObjectID = $type != 'custom' ? $action->$type : ''; $libObjectID = trim($libObjectID, ','); diff --git a/module/api/control.php b/module/api/control.php index 5d058bdcc3..05d51bd5a6 100755 --- a/module/api/control.php +++ b/module/api/control.php @@ -340,7 +340,7 @@ class api extends control /** * Edit an api doc library * - * @param $id + * @param int $id * @access public * @return void */ @@ -374,9 +374,12 @@ class api extends control /** + * Delete api library. + * * @param int $libID * @param string $confirm - * @param string $from + * @access public + * @return void */ public function deleteLib($libID, $confirm = 'no') { @@ -400,7 +403,7 @@ class api extends control /** * Edit library. * - * @param int $apiID + * @param int $apiID * @access public * @return void */ diff --git a/module/doc/control.php b/module/doc/control.php index 1430bf7696..a7dfce5c67 100644 --- a/module/doc/control.php +++ b/module/doc/control.php @@ -1046,6 +1046,8 @@ class doc extends control } } + $doc = $docID ? $doc : ''; + $this->view->customObjectLibs = $customObjectLibs; $this->view->showLibs = $this->config->doc->custom->objectLibs; @@ -1053,7 +1055,7 @@ class doc extends control $this->view->position[] = ($type == 'book' or $type == 'custom') ? $this->lang->doc->customAB : $object->name; $this->view->docID = $docID; - $this->view->doc = $docID ? $doc : ''; + $this->view->doc = $doc; $this->view->type = $type; $this->view->version = $version; $this->view->object = $object;