/** * Mark object as starred * * @param void * @return null */ function star() { if ($this->request->isAsyncCall()) { if ($this->request->isSubmitted()) { db_begin_work(); $action = $this->active_object->star($this->logged_user); if ($action && !is_error($action)) { db_commit(); } else { db_rollback(); } // if } // if require_once SYSTEM_MODULE_PATH . '/helpers/function.object_star.php'; print smarty_function_object_star(array('object' => $this->active_object, 'user' => $this->logged_user), $this->smarty); die; } else { $this->executeOnActiveObject('star', array($this->logged_user), lang(':type ":name" has been starred', array('type' => $this->active_object->getVerboseType(), 'name' => $this->active_object->getName())), lang('Failed to star :type ":name"', array('type' => $this->active_object->getVerboseType(true), 'name' => $this->active_object->getName()))); } // if }