[Fusionforge-commits] r17988 - in trunk/src/common: docman/include forum import include include/system search system_event tracker
Marc-Etienne VARGENAU
vargenau at fusionforge.org
Tue Sep 17 18:27:07 CEST 2013
Author: vargenau
Date: 2013-09-17 18:27:07 +0200 (Tue, 17 Sep 2013)
New Revision: 17988
Modified:
trunk/src/common/docman/include/utils.php
trunk/src/common/forum/ForumHTML.class.php
trunk/src/common/import/import_tasks.php
trunk/src/common/import/import_trackers.php
trunk/src/common/include/account.php
trunk/src/common/include/session.php
trunk/src/common/include/squal_exit.php
trunk/src/common/include/system/NSSPGSQL.class.php
trunk/src/common/include/tag_cloud.php
trunk/src/common/search/DocsSearchQuery.class.php
trunk/src/common/search/TasksSearchQuery.class.php
trunk/src/common/search/TrackersSearchQuery.class.php
trunk/src/common/system_event/SystemEventManager.class.php
trunk/src/common/tracker/ArtifactExtraField.class.php
Log:
Update PHP Doc
Modified: trunk/src/common/docman/include/utils.php
===================================================================
--- trunk/src/common/docman/include/utils.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/docman/include/utils.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -42,11 +42,11 @@
/**
* docman_fill_zip - Recursive function to add docgroup and documents inside zip for backup
*
- * @param $object zip
- * @param $array nested groups
- * @param $object documentfactory
- * @param $int documentgroup id : default value = 0
- * @param $string documentgroup parent name : default value = empty
+ * @param object $zip
+ * @param array $nested_groups
+ * @param object $document_factory
+ * @param int $docgroup id : default value = 0
+ * @param string $parent_docname parent name : default value = empty
* @return boolean success or not
* @access public
*/
Modified: trunk/src/common/forum/ForumHTML.class.php
===================================================================
--- trunk/src/common/forum/ForumHTML.class.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/forum/ForumHTML.class.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -295,11 +295,11 @@
/**
* LinkAttachEditForm - Returns the link to the attach form for editing
*
- * @param string Filename
- * @param int group id
- * @param int forum id
- * @param int attach id
- * @param int msg id
+ * @param string $filename Filename
+ * @param int $group_id group id
+ * @param int $forum_id forum id
+ * @param int $attachid attach id
+ * @param int $msg_id msg id
*
* @return The HTML output
*/
@@ -318,7 +318,7 @@
<table>
<tr>
- <td>' . _('Use the "Browse" button to find the file you want to attach') . '</td>
+ <td>' . _('Use the “Browse” button to find the file you want to attach') . '</td>
</tr>
<tr>
<td>' . _('File to upload') . ': <input type="file" name="attachment1"/></td>
@@ -326,14 +326,14 @@
<tr>
<td class="warning">' . _('Warning: Uploaded file will replace current file') . '</td>
</tr>
- </table>
- <input type="submit" name="go" value="'._('Update').'" />
- <input type="hidden" name="doedit" value="1"/>
- <input type="hidden" name="edit" value="yes"/>
- <input type="hidden" name="forum_id" value="'.$forum_id.'"/>
- <input type="hidden" name="group_id" value="'.$group_id.'"/>
- <input type="hidden" name="attachid" value="'.$attachid.'"/>
- <input type="hidden" name="msg_id" value="'.$msg_id.'"/>
+ </table>
+ <input type="submit" name="go" value="'._('Update').'" />
+ <input type="hidden" name="doedit" value="1" />
+ <input type="hidden" name="edit" value="yes" />
+ <input type="hidden" name="forum_id" value="'.$forum_id.'" />
+ <input type="hidden" name="group_id" value="'.$group_id.'" />
+ <input type="hidden" name="attachid" value="'.$attachid.'" />
+ <input type="hidden" name="msg_id" value="'.$msg_id.'" />
</fieldset>
</form>
<p/>';
@@ -501,7 +501,7 @@
$is_followup_to = $msg->getParentID();
$has_followups = $msg->hasFollowups();
$most_recent_date = $msg->getMostRecentDate();
- $g =& $this->Forum->getGroup();
+ $g = $this->Forum->getGroup();
$group_id = $g->getID();
if (forge_check_perm ('forum', $this->Forum->getID(), 'post')) { // minor control, but anyways it should be an admin at this point
@@ -528,19 +528,19 @@
<input type="text" required="required" name="subject" value="<?php echo $subject; ?>" size="80" maxlength="80" />
<br />
<strong><?php echo _('Message:'); ?></strong><?php echo notepad_button('document.forms.ForumEditForm.body') ?><?php echo utils_requiredField(); ?><br />
- <?php
- $GLOBALS['editor_was_set_up']=false;
- $params = array() ;
- $params['body'] = $body;
- $params['width'] = "800";
- $params['height'] = "500";
- $params['group'] = $group_id;
- plugin_hook("text_editor",$params);
- if (!$GLOBALS['editor_was_set_up']) {
- //if we don't have any plugin for text editor, display a simple textarea edit box
- echo '<textarea name="body" required="required" rows="10" cols="70">' . $body . '</textarea>';
- }
- unset($GLOBALS['editor_was_set_up']);
+ <?php
+ $GLOBALS['editor_was_set_up']=false;
+ $params = array() ;
+ $params['body'] = $body;
+ $params['width'] = "800";
+ $params['height'] = "500";
+ $params['group'] = $group_id;
+ plugin_hook("text_editor",$params);
+ if (!$GLOBALS['editor_was_set_up']) {
+ //if we don't have any plugin for text editor, display a simple textarea edit box
+ echo '<textarea required="required" name="body" rows="10" cols="70">' . $body . '</textarea>';
+ }
+ unset($GLOBALS['editor_was_set_up']);
?>
<br />
Modified: trunk/src/common/import/import_tasks.php
===================================================================
--- trunk/src/common/import/import_tasks.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/import/import_tasks.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -216,7 +216,7 @@
/**
* deleteTrackers - Delete all existing default trackers from a projet
- * @param Group A Group object
+ * @param object Group A Group object
*/
function deleteTrackers(){
$pgf = new ProjectGroupFactory($this->group);
Modified: trunk/src/common/import/import_trackers.php
===================================================================
--- trunk/src/common/import/import_trackers.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/import/import_trackers.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -315,8 +315,9 @@
}
/**
* tracker_fill - Create trackers from an array in a given group
- * @param array Trackers part of a JSON pluck, including label, artifacts, vocabulary...
- * @param int Group id of the group where the trackers should be added
+ * @param array $trackers Trackers part of a JSON pluck, including label, artifacts, vocabulary...
+ * @param int $group_id Group id of the group where the trackers should be added
+ * @param array $users
*/
function tracker_fill($trackers, $group_id, $users){
Modified: trunk/src/common/include/account.php
===================================================================
--- trunk/src/common/include/account.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/include/account.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -45,35 +45,35 @@
* @return bool true on success/false on failure
*
*/
-function account_namevalid($name, $unix=0) {
+function account_namevalid($name, $unix=false) {
if (!$unix) {
// If accounts comes from ldap and no shell access, then disable controls.
$pluginManager = plugin_manager_get_object();
- if (!forge_get_config('use_shell') && $pluginManager->PluginIsInstalled('authldap')) {
- return 1;
+ if (!forge_get_config('use_shell') && $pluginManager->PluginIsInstalled('ldapextauth')) {
+ return true;
}
}
// no spaces
if (strrpos($name,' ') > 0) {
$GLOBALS['register_error'] = _('There cannot be any spaces in the login name.');
- return 0;
+ return false;
}
// min and max length
if (strlen($name) < 3) {
$GLOBALS['register_error'] = _('Name is too short. It must be at least 3 characters.');
- return 0;
+ return false;
}
if (strlen($name) > 15) {
$GLOBALS['register_error'] = _('Name is too long. It must be less than 15 characters.');
- return 0;
+ return false;
}
if (!preg_match('/^[a-z0-9][-a-z0-9_\.]+$/', $name)) {
$GLOBALS['register_error'] = _('Illegal character in name.');
- return 0;
+ return false;
}
// illegal names
@@ -82,24 +82,24 @@
. "debian|ns|download)$";
if( preg_match("/$regExpReservedNames/i", $name) ) {
$GLOBALS['register_error'] = _('Name is reserved.');
- return 0;
+ return false;
}
if (forge_get_config('use_shell')) {
- if ( exec("getent passwd $name") != "" ){
+ if (exec("getent passwd $name") != "" ){
$GLOBALS['register_error'] = _('That username already exists.');
- return 0;
+ return false;
}
- if ( exec("getent group $name") != "" ){
+ if (exec("getent group $name") != "" ){
$GLOBALS['register_error'] = _('That username already exists.');
- return 0;
+ return false;
}
}
if (preg_match("/^(anoncvs_)/i",$name)) {
$GLOBALS['register_error'] = _('Name is reserved for CVS.');
- return 0;
+ return false;
}
- return 1;
+ return true;
}
/**
Modified: trunk/src/common/include/session.php
===================================================================
--- trunk/src/common/include/session.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/include/session.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -155,7 +155,7 @@
* This function destroys object associated with the current session,
* making user "logged out". Deletes both user and session cookies.
*
- * @return true/false
+ * @return bool true/false
*
*/
function session_logout() {
@@ -176,18 +176,17 @@
* High-level function for user login. Check credentials, and if they
* are valid, open new session.
*
- * @param string User name
- * @param string User password (in clear text)
- * @param bool Allow login to non-confirmed user account (only for confirmation of the very account)
- * @return true/false, if false reason is in global $feedback
- * @access public
+ * @param string $loginname User name
+ * @param string $passwd User password (in clear text)
+ * @param bool|int $allowpending Allow login to non-confirmed user account (only for confirmation of the very account)
+ * @return bool true/false, if false reason is in global $feedback
*
*/
-function session_login_valid($loginname, $passwd, $allowpending=0) {
+function session_login_valid($loginname, $passwd, $allowpending = 0) {
global $feedback, $error_msg, $warning_msg;
if (!$loginname || !$passwd) {
- $warning_msg = _('Missing Password Or Users Name');
+ $warning_msg = _('Missing Password Or User Name');
return false;
}
@@ -286,28 +285,28 @@
// Let's check the status of this user
// if allowpending (for verify.php) then allow
- $userstatus=$usr['status'];
+ $userstatus = $usr['status'];
if ($allowpending && ($usr['status'] == 'P')) {
//1;
} else {
if ($usr['status'] == 'S') {
//acount suspended
- $warning_msg = _('Account Suspended');
+ $feedback = _('Account Suspended');
return false;
}
if ($usr['status'] == 'P') {
//account pending
- $warning_msg = _('Account Pending');
+ $feedback = _('Account Pending');
return false;
}
if ($usr['status'] == 'D') {
//account deleted
- $warning_msg = _('Account Deleted');
+ $feedback = _('Account Deleted');
return false;
}
if ($usr['status'] != 'A') {
//unacceptable account flag
- $warning_msg = _('Account Not Active');
+ $feedback = _('Account Not Active');
return false;
}
}
@@ -329,9 +328,9 @@
* For IPv6 addresses, no fuzz is needed since there's
* usually no NAT in IPv6.
*
- * @param string The old IP address
- * @param string The new IP address
- * @return true/false
+ * @param string $oldip The old IP address
+ * @param string $newip The new IP address
+ * @return bool true/false
* @access private
*/
function session_check_ip($oldip, $newip) {
@@ -358,8 +357,7 @@
/**
* session_issecure() - Check if current session is secure
*
- * @return true/false
- * @access public
+ * @return bool
*/
function session_issecure() {
return (strtoupper(getStringFromServer('HTTPS')) == "ON");
@@ -371,10 +369,10 @@
* Set a cookie with default temporal scope of the current browser session
* and URL space of the current webserver
*
- * @param string Name of cookie
- * @param string Value of cookie
- * @param string Domain scope (default '')
- * @param string Expiration time in UNIX seconds (default 0)
+ * @param string $name Name of cookie
+ * @param string $value Value of cookie
+ * @param string $domain Domain scope (default '')
+ * @param int $expiration Expiration time in UNIX seconds (default 0)
*/
function session_set_cookie($name, $value, $domain='', $expiration=0) {
return session_cookie($name, $value, $domain, $expiration);
@@ -458,16 +456,18 @@
* Calling page will terminate with error message if current user
* fails checks.
*
- * @param array Associative array specifying criteria
- * @return does not return if check is failed
+ * @deprecated
*
+ * @param array $req Associative array specifying criteria
+ * @param string $reason
+ * @return does not return if check is failed
*/
-function session_require($req, $reason='') {
+function session_require($req, $reason = '') {
if (!session_loggedin()) {
exit_not_logged_in();
}
- $user =& user_get_object(user_getid());
+ $user = user_get_object(user_getid());
if (!$user->isActive()) {
session_logout();
exit_error(_('Your account is no longer active; you have been disconnected'), '');
@@ -507,7 +507,7 @@
* fails checks.
*
*/
-function session_require_perm($section, $reference, $action=NULL, $reason='') {
+function session_require_perm($section, $reference, $action = NULL, $reason = '') {
if (!forge_check_perm($section, $reference, $action)) {
exit_permission_denied($reason, $section);
}
@@ -549,8 +549,7 @@
* This function sets up SourceForge session for the given user,
* making one be "logged in".
*
- * @param int The user ID
- * @return none
+ * @param int $user_id The user ID
*/
function session_set_new($user_id) {
$token = session_build_session_token($user_id);
@@ -588,7 +587,7 @@
}
}
-function session_set_internal($user_id, $res=false) {
+function session_set_internal($user_id, $res = false) {
global $G_SESSION;
$G_SESSION = user_get_object($user_id, $res);
@@ -603,8 +602,6 @@
* session_set_admin() - Setup session for the admin user
*
* This function sets up a session for the administrator
- *
- * @return none
*/
function session_set_admin() {
$admins = RBACEngine::getInstance()->getUsersByAllowedAction('forge_admin', -1);
@@ -627,11 +624,12 @@
}
/**
- * Private optimization function for logins - fetches user data, language, and session
- * with one query
+ * Private optimization function for logins - fetches user data, language, and session
+ * with one query
*
- * @param int The user ID
+ * @param int $user_id The user ID
* @access private
+ * @return resource
*/
function session_getdata($user_id) {
return db_query_params('SELECT u.*, sl.language_id, sl.name,
@@ -649,8 +647,6 @@
*
* This function checks that the user is logged in and if so, initialize
* internal session environment.
- *
- * @return none
*/
function session_set() {
global $G_SESSION;
@@ -787,13 +783,13 @@
}
function setup_tz_from_context() {
- $LUSER =& session_get_user();
- if (!is_object($LUSER) || $LUSER->isError()) {
+ $user = session_get_user();
+ if (!is_object($user) || $user->isError()) {
$tz = forge_get_config('default_timezone');
} else {
- $tz = $LUSER->getTimeZone();
+ $tz = $user->getTimeZone();
}
- putenv('TZ=' . $tz);
+ putenv('TZ='.$tz);
date_default_timezone_set($tz);
}
@@ -816,8 +812,9 @@
global $G_SESSION;
if ($G_SESSION) {
return $G_SESSION->getID();
+ } else {
+ return false;
}
- return false;
}
/**
@@ -829,8 +826,9 @@
if ($G_SESSION) {
return $G_SESSION->isLoggedIn();
+ } else {
+ return false;
}
- return false;
}
// Local Variables:
Modified: trunk/src/common/include/squal_exit.php
===================================================================
--- trunk/src/common/include/squal_exit.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/include/squal_exit.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -29,14 +29,14 @@
* @param string Error toptab
*/
function exit_error($title,$toptab='') {
- print 'ERROR - '.$title;
+ print 'Error: '.$title;
exit;
}
/**
* exit_permission_denied() - Return a 'Permission Denied' error
- * @param string $reason_descr
- * @param string toptab needed for navigation
+ * @param $reason_descr string
+ * @param $toptab string toptab needed for navigation
*/
function exit_permission_denied($reason_descr='',$toptab='') {
exit_error('PERMISSION DENIED');
@@ -58,9 +58,9 @@
/**
* exit_missing_param() - Return a 'Missing Required Parameters' error
- * @param string URL : usually $_SERVER['HTTP_REFERER']
- * @param array array of missing parameters
- * @param string toptab needed for navigation
+ * @param string $url URL : usually $_SERVER['HTTP_REFERER']
+ * @param array $missing_params array of missing parameters
+ * @param string $toptab needed for navigation
*/
function exit_missing_param($url='',$missing_params=array(),$toptab='') {
exit_error('MISSING REQUIRED PARAMETERS');
Modified: trunk/src/common/include/system/NSSPGSQL.class.php
===================================================================
--- trunk/src/common/include/system/NSSPGSQL.class.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/include/system/NSSPGSQL.class.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -41,7 +41,7 @@
/**
* sysCreateUser() - Create a user
*
- * @param int The user ID of the user to create
+ * @param int $user_id The user ID of the user to create
* @return bool The return status
*
*/
@@ -52,7 +52,7 @@
/**
* sysRemoveUser() - Remove a user
*
- * @param int The user ID of the user to remove
+ * @param int $user_id The user ID of the user to remove
* @return bool true on success/false on failure
*
*/
@@ -67,7 +67,7 @@
/**
* sysCheckGroup() - Check for the existence of a group
*
- * @param int The ID of the group to check
+ * @param int $group_id The ID of the group to check
* @return bool true on success/false on failure
*
*/
@@ -82,7 +82,7 @@
/**
* sysCreateGroup() - Create a group
*
- * @param int The ID of the group to create
+ * @param int $group_id The ID of the group to create
* @return bool true on success/false on failure
*
*/
Modified: trunk/src/common/include/tag_cloud.php
===================================================================
--- trunk/src/common/include/tag_cloud.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/include/tag_cloud.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -68,16 +68,17 @@
* F(count) = size = A * count + 1 - A * Cmin
* => size = 1 + (count - Cmin) * A
*
- * @param array selected tag, max tag displayed, number of sizes available,
- * class prefix for css class, style for selected tag
+ * @param array $params selected tag, max tag displayed, number of sizes available,
+ * class prefix for css class, style for selected tag
+ * @return string
*/
-function tag_cloud($params = '') {
+function tag_cloud($params = array()) {
global $NB_SIZE;
global $NB_MAX;
global $CLASS_PREFIX;
global $SELECTED_STYLE;
- if (! is_array($params)) $parames = array();
+ if (! is_array($params)) $params = array();
if (! isset($params['selected'])) {
$params['selected'] = '';
}
@@ -169,6 +170,7 @@
* where the tag is defined.
*
* @param int Group ID
+ * @return string
*/
function list_project_tag($group_id) {
$req = 'SELECT name FROM project_tags WHERE group_id = $1';
Modified: trunk/src/common/search/DocsSearchQuery.class.php
===================================================================
--- trunk/src/common/search/DocsSearchQuery.class.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/search/DocsSearchQuery.class.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -47,11 +47,11 @@
* Constructor
*
* @param string $words words we are searching for
- * @param int $offset offset
- * @param boolean $isExact if we want to search for all the words or if only one matching the query is sufficient
- * @param int $groupId group id
- * @param array $sections sections to search in
- * @param boolean $showNonPublic flag if private sections are searched too
+ * @param int $offset offset
+ * @param bool $isExact if we want to search for all the words or if only one matching the query is sufficient
+ * @param int $groupId group id
+ * @param string $sections sections to search in
+ * @param bool $showNonPublic flag if private sections are searched too
*/
function __construct($words, $offset, $isExact, $groupId, $sections = SEARCH__ALL_SECTIONS, $showNonPublic = false) {
$this->groupId = $groupId;
Modified: trunk/src/common/search/TasksSearchQuery.class.php
===================================================================
--- trunk/src/common/search/TasksSearchQuery.class.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/search/TasksSearchQuery.class.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -44,12 +44,12 @@
/**
* Constructor
*
- * @param string $words words we are searching for
- * @param int $offset offset
- * @param boolean $isExact if we want to search for all the words or if only one matching the query is sufficient
- * @param int $groupId group id
- * @param array $sections sections to search in
- * @param boolean $showNonPublic flag if private sections are searched too
+ * @param string $words words we are searching for
+ * @param int $offset offset
+ * @param bool $isExact if we want to search for all the words or if only one matching the query is sufficient
+ * @param int $groupId group id
+ * @param string $sections sections to search in
+ * @param bool $showNonPublic flag if private sections are searched too
*/
function __construct($words, $offset, $isExact, $groupId, $sections=SEARCH__ALL_SECTIONS, $showNonPublic=false) {
$this->groupId = $groupId;
@@ -68,9 +68,6 @@
function getQuery() {
$qpa = db_construct_qpa () ;
-
-
-
if (forge_get_config('use_fti')) {
$words = $this->getFTIwords();
Modified: trunk/src/common/search/TrackersSearchQuery.class.php
===================================================================
--- trunk/src/common/search/TrackersSearchQuery.class.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/search/TrackersSearchQuery.class.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -44,12 +44,12 @@
/**
* Constructor
*
- * @param string $words words we are searching for
- * @param int $offset offset
- * @param boolean $isExact if we want to search for all the words or if only one matching the query is sufficient
- * @param int $groupId group id
- * @param array $sections sections to search in
- * @param boolean $showNonPublic flag if private sections are searched too
+ * @param string $words words we are searching for
+ * @param int $offset offset
+ * @param bool $isExact if we want to search for all the words or if only one matching the query is sufficient
+ * @param int $groupId group id
+ * @param string $sections sections to search in
+ * @param bool $showNonPublic flag if private sections are searched too
*/
function __construct($words, $offset, $isExact, $groupId, $sections=SEARCH__ALL_SECTIONS, $showNonPublic=false) {
$this->groupId = $groupId;
Modified: trunk/src/common/system_event/SystemEventManager.class.php
===================================================================
--- trunk/src/common/system_event/SystemEventManager.class.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/system_event/SystemEventManager.class.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -62,23 +62,22 @@
* Table to display the status of the last n events
*
* @param int $offset the offset of the pagination
- * @param int $limit the number of event to includ in the table
- * @param boolean $full display a full table or only a summary
+ * @param int $limit the number of event to include in the table
+ * @param bool $full display a full table or only a summary
* @param array $filter_status the filter on status
* @param array $filter_type the filter on type
+ * @param array $filter_params
*
* @return array events
*/
- public function fetchEvents($offset = 0, $limit = 10, $full = false, $filter_status = false, $filter_type = false, $filter_params = false) {
+ public function fetchEvents($offset = 0, $limit = 10, $full = false, $filter_status = array(), $filter_type = array(), $filter_params = array()) {
$results = db_query_params('SELECT * FROM system_event WHERE type IN ($1) AND status IN($2) AND parameters=$3;',array($filter_type, $filter_status,$filter_params));
- while($row = db_fetch_array($results))
- {
+ while($row = db_fetch_array($results)) {
$events[]=$row;
}
if (isset($events)) {
return $events;
- }
- else {
+ } else {
return null;
}
Modified: trunk/src/common/tracker/ArtifactExtraField.class.php
===================================================================
--- trunk/src/common/tracker/ArtifactExtraField.class.php 2013-09-17 14:00:26 UTC (rev 17987)
+++ trunk/src/common/tracker/ArtifactExtraField.class.php 2013-09-17 16:27:07 UTC (rev 17988)
@@ -88,13 +88,13 @@
* a tracker. This function is only used to create rows for boxes
* configured by the admin.
*
- * @param string Name of the extra field.
- * @param int The type of field - radio, select, text, textarea
- * @param int Attribute1 - for text (size) and textarea (rows)
- * @param int Attribute2 - for text (maxlength) and textarea (cols)
- * @param int is_required - true or false whether this is a required field or not.
- * @param string alias - alias for this extra field (optional)
- * @return true on success / false on failure.
+ * @param string $name Name of the extra field.
+ * @param int $field_type The type of field - radio, select, text, textarea
+ * @param int $attribute1 For text (size) and textarea (rows)
+ * @param int $attribute2 For text (maxlength) and textarea (cols)
+ * @param int $is_required True or false whether this is a required field or not.
+ * @param string $alias Alias for this extra field (optional)
+ * @return bool true on success / false on failure.
*/
function create($name,$field_type,$attribute1,$attribute2,$is_required=0,$alias='') {
//
@@ -360,12 +360,12 @@
* for boxes configured by
* the admin.
*
- * @param string Name of the field.
- * @param int Attribute1 - for text (size) and textarea (rows)
- * @param int Attribute2 - for text (maxlength) and textarea (cols)
- * @param int is_required - true or false whether this is a required field or not.
- * @param string Alias for this field
- * @return boolean success.
+ * @param string $name Name of the field.
+ * @param int $attribute1 For text (size) and textarea (rows)
+ * @param int $attribute2 For text (maxlength) and textarea (cols)
+ * @param int $is_required True or false whether this is a required field or not.
+ * @param string $alias Alias for this field
+ * @return bool success.
*/
function update($name,$attribute1,$attribute2,$is_required=0,$alias="") {
if (!forge_check_perm ('tracker_admin', $this->ArtifactType->Group->getID())) {
More information about the Fusionforge-commits
mailing list