[Fusionforge-commits] FusionForge branch 6.1 updated. v6.1rc1-60-ge4de926
Franck Villaume
nerville at libremir.placard.fr.eu.org
Tue May 1 12:45:46 CEST 2018
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".
The branch, 6.1 has been updated
via e4de926c10c20ffdb497d306308674d01eff4e78 (commit)
via a00a5139038331a3df50a9b57d1cb3c0f1da8e4b (commit)
via 6ea0203f6c85c5cded4308fce06c6628a4245f29 (commit)
via 30329c4a4348b8afc6b1e778354221a57caf0fb7 (commit)
via 7b04d5abcc9ac1e282fb7bb02251e8fac8b85253 (commit)
via c2082ab2a7fb02075097cecc5fb32e5e69a57144 (commit)
via 0c3d4c618dabcffd5ea23e8b48e7685179b7eced (commit)
via 0199db336bf7005e830256f1f6557b0bb205f50f (commit)
via d95f48d862e56920b03173be796078b4986585d0 (commit)
from 54a28c2219ecbc2f46e3342d6cf813908a6b247c (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=e4de926c10c20ffdb497d306308674d01eff4e78
commit e4de926c10c20ffdb497d306308674d01eff4e78
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 12:45:18 2018 +0200
tabs
diff --git a/src/www/include/canned_responses.php b/src/www/include/canned_responses.php
index 3e18d96..4cb2056 100644
--- a/src/www/include/canned_responses.php
+++ b/src/www/include/canned_responses.php
@@ -24,24 +24,22 @@
/**
* add_canned_response() - Add a new canned response
*
- * @param string $title Canned response title
- * @param string $text Canned response text
+ * @param string $title Canned response title
+ * @param string $text Canned response text
*/
-function add_canned_response($title, $text)
-{
- global $error_msg;
- if( !db_query_params ('INSERT INTO canned_responses (response_title, response_text) VALUES($1,$2)',
- array($title,
- $text)) ) {
- $error_msg .= db_error();
- }
+function add_canned_response($title, $text) {
+ global $error_msg;
+ if( !db_query_params ('INSERT INTO canned_responses (response_title, response_text) VALUES($1,$2)',
+ array($title,
+ $text)) ) {
+ $error_msg .= db_error();
+ }
}
/**
* get_canned_responses() - Get an HTML select-box of canned responses
*/
-function get_canned_responses()
-{
+function get_canned_responses() {
global $canned_response_res;
if (!$canned_response_res) {
$canned_response_res = db_query_params ('SELECT response_id, response_title FROM canned_responses',
diff --git a/src/www/include/project_summary.php b/src/www/include/project_summary.php
index 1c583e2..0388f13 100644
--- a/src/www/include/project_summary.php
+++ b/src/www/include/project_summary.php
@@ -29,8 +29,8 @@ $project_agg_arr=array();
/**
* project_setup_agg() - Set up a project aggregate array.
*
- * @param int $group_id Project ID
- * @access private
+ * @param int $group_id Project ID
+ * @access private
*/
function project_setup_agg($group_id) {
global $project_agg_arr,$project_agg_arr_is_set;
@@ -48,10 +48,10 @@ function project_setup_agg($group_id) {
/**
* project_getaggvalue() - Get a projects aggregate value for a specific type
*
- * @param int $group_id The group ID
- * @param string $type The type
- * @return string
- * @access private
+ * @param int $group_id The group ID
+ * @param string $type The type
+ * @return string
+ * @access private
*/
function project_getaggvalue($group_id, $type) {
global $project_agg_arr,$project_agg_arr_is_set;
@@ -89,7 +89,7 @@ function project_get_survey_count($group_id) {
/**
* project_summary() - Build a project summary box that projects can insert into their project pages
*
- * @param int $group_id The group ID
+ * @param int $group_id The group ID
* @param string $mode How to return the results.
* @param bool $no_table Whether to return the results within an HTML table or not
* @return string
diff --git a/src/www/include/role_utils.php b/src/www/include/role_utils.php
index 8b079b3..bfbb42b 100644
--- a/src/www/include/role_utils.php
+++ b/src/www/include/role_utils.php
@@ -20,11 +20,11 @@
/**
* Displays a selection box for roles in a group (TODO : provide more details on parameters roles)
- * @param int $group_id
- * @param string $name
- * @param string $selected
- * @param bool $local_only
- * @return string
+ * @param int $group_id
+ * @param string $name
+ * @param string $selected
+ * @param bool $local_only
+ * @return string
*/
function role_box ($group_id, $name, $selected='xzxzxz', $local_only=true) {
$group = group_get_object($group_id);
diff --git a/src/www/include/trove.php b/src/www/include/trove.php
index 40b08ef..c761fbc 100644
--- a/src/www/include/trove.php
+++ b/src/www/include/trove.php
@@ -179,7 +179,7 @@ function trove_setnode($group_id, $trove_cat_id, $rootnode=0) {
/**
* trove_getrootcat() - Get the root categegory
*
- * @param int $trove_cat_id Trove category ID
+ * @param int $trove_cat_id Trove category ID
* @return int
*/
function trove_getrootcat($trove_cat_id) {
diff --git a/src/www/include/vote_function.php b/src/www/include/vote_function.php
index a644bfa..6e7a5c2 100644
--- a/src/www/include/vote_function.php
+++ b/src/www/include/vote_function.php
@@ -26,8 +26,8 @@
/**
* vote_number_to_stars() - Turns vote results into *'s
*
- * @param int $raw Raw value
- * @return string
+ * @param int $raw Raw value
+ * @return string
*/
function vote_number_to_stars($raw) {
$raw=intval($raw*2);
@@ -51,8 +51,8 @@ function vote_number_to_stars($raw) {
/**
* vote_show_thumbs() - Show vote stars
*
- * @param int $id The survey ID
- * @param string $flag The rating type
+ * @param int $id The survey ID
+ * @param string $flag The rating type
* @return string
*/
function vote_show_thumbs($id, $flag) {
@@ -74,8 +74,8 @@ function vote_show_thumbs($id, $flag) {
/**
* vote_get_rating() - Get a vote rating
*
- * @param int $id The survey ID
- * @param string $flag The rating type
+ * @param int $id The survey ID
+ * @param string $flag The rating type
* @return mixed|string
*/
function vote_get_rating ($id, $flag) {
@@ -92,8 +92,8 @@ function vote_get_rating ($id, $flag) {
/**
* vote_show_release_radios() - Show release radio buttons
*
- * @param int $vote_on_id The survey ID
- * @param string $flag The rating type
+ * @param int $vote_on_id The survey ID
+ * @param string $flag The rating type
*/
function vote_show_release_radios ($vote_on_id, $flag) {
global $HTML;
@@ -140,8 +140,8 @@ function vote_show_release_radios ($vote_on_id, $flag) {
/**
* show_survey() - Select and show a specific survey from the database
*
- * @param int $group_id The group ID
- * @param int $survey_id The survey ID
+ * @param int $group_id The group ID
+ * @param int $survey_id The survey ID
*/
function show_survey ($group_id, $survey_id) {
global $HTML;
@@ -298,8 +298,8 @@ if (db_numrows($result) > 0) {
/**
* Show a single question for the new user rating system
*
- * @param string $question The question to show
- * @param string $element_name The array element
+ * @param string $question The question to show
+ * @param string $element_name The array element
*/
function vote_show_a_question ($question, $element_name) {
echo '
@@ -385,8 +385,8 @@ $USER_RATING_VALUES[]='3';
/**
* vote_show_user_rate_box() - Show user rating box
*
- * @param int $user_id The user ID
- * @param int $by_id The user ID of the user who is rating $user_id
+ * @param int $user_id The user ID
+ * @param int $by_id The user ID of the user who is rating $user_id
*/
function vote_show_user_rate_box ($user_id, $by_id=0) {
if ($by_id) {
@@ -433,7 +433,7 @@ function vote_show_user_rate_box ($user_id, $by_id=0) {
/**
* vote_show_user_rating() - Show a user rating
*
- * @param int $user_id The user ID
+ * @param int $user_id The user ID
*/
function vote_show_user_rating($user_id) {
global $USER_RATING_QUESTIONS;
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=a00a5139038331a3df50a9b57d1cb3c0f1da8e4b
commit a00a5139038331a3df50a9b57d1cb3c0f1da8e4b
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 12:35:09 2018 +0200
remove empty lines
diff --git a/src/common/include/TroveCat.class.php b/src/common/include/TroveCat.class.php
index 55d9e2d..3b78a8e 100644
--- a/src/common/include/TroveCat.class.php
+++ b/src/common/include/TroveCat.class.php
@@ -94,12 +94,10 @@ class TroveCat extends FFError {
function getIDsFullPath() {
return $this->data_array['fullpath_ids'];
-
}
function getDescription() {
return $this->data_array['description'];
-
}
function listSubTree() {
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=6ea0203f6c85c5cded4308fce06c6628a4245f29
commit 6ea0203f6c85c5cded4308fce06c6628a4245f29
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 12:34:15 2018 +0200
tabs vs. space
diff --git a/src/common/include/TroveCat.class.php b/src/common/include/TroveCat.class.php
index f95897c..55d9e2d 100644
--- a/src/common/include/TroveCat.class.php
+++ b/src/common/include/TroveCat.class.php
@@ -42,15 +42,15 @@ class TroveCat extends FFError {
$this->fetchData($cat_id);
}
- /**
- * fetchData - May need to refresh database fields.
- *
- * If an update occurred and you need to access the updated info.
- *
- * @param int $cat_id
- * @param bool $res
- * @return bool success;
- */
+ /**
+ * fetchData - May need to refresh database fields.
+ *
+ * If an update occurred and you need to access the updated info.
+ *
+ * @param int $cat_id
+ * @param bool $res
+ * @return bool success;
+ */
function fetchData($cat_id, &$res = false) {
unset($this->data_array);
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=30329c4a4348b8afc6b1e778354221a57caf0fb7
commit 30329c4a4348b8afc6b1e778354221a57caf0fb7
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 12:30:05 2018 +0200
remove useless code
diff --git a/src/common/include/Navigation.class.php b/src/common/include/Navigation.class.php
index a82862f..84407cf 100644
--- a/src/common/include/Navigation.class.php
+++ b/src/common/include/Navigation.class.php
@@ -40,10 +40,6 @@ class Navigation extends FFError {
*/
var $project_menu_data;
- function __construct() {
- parent::__construct();
- }
-
/**
* getTitle - Get the HTML code of the title of the page.
* If the array $params contains a value for the key 'title',
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=7b04d5abcc9ac1e282fb7bb02251e8fac8b85253
commit 7b04d5abcc9ac1e282fb7bb02251e8fac8b85253
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 12:26:40 2018 +0200
tabs & space
diff --git a/src/common/include/HTTPRequest.class.php b/src/common/include/HTTPRequest.class.php
index 537d8c9..74a388f 100644
--- a/src/common/include/HTTPRequest.class.php
+++ b/src/common/include/HTTPRequest.class.php
@@ -25,107 +25,106 @@ require_once 'common/include/Codendi_Request.class.php';
*/
class HTTPRequest extends Codendi_Request {
- function __construct() {
- parent::__construct($_REQUEST);
- }
+ function __construct() {
+ parent::__construct($_REQUEST);
+ }
- /**
- * Get the value of $variable in $this->params (server side values).
- *
- * @param string $variable Name of the parameter to get.
- * @return mixed If the variable exist, the value is returned (string)
- * otherwise return false;
- */
- function getFromServer($variable) {
- return $this->_get($variable, $_SERVER);
- }
+ /**
+ * Get the value of $variable in $this->params (server side values).
+ *
+ * @param string $variable Name of the parameter to get.
+ * @return mixed If the variable exist, the value is returned (string)
+ * otherwise return false;
+ */
+ function getFromServer($variable) {
+ return $this->_get($variable, $_SERVER);
+ }
- /**
- * Check if current request is send via 'post' method.
- *
- * This method is useful to test if the current request comes from a form.
- *
- * @return bool
- */
- function isPost() {
- if($_SERVER['REQUEST_METHOD'] == 'POST') {
- return true;
- } else {
- return false;
- }
- }
+ /**
+ * Check if current request is send via 'post' method.
+ *
+ * This method is useful to test if the current request comes from a form.
+ *
+ * @return bool
+ */
+ function isPost() {
+ if($_SERVER['REQUEST_METHOD'] == 'POST') {
+ return true;
+ } else {
+ return false;
+ }
+ }
- /**
- * Return true if browser used to submit the request is netscape 4.
- *
- * @return bool
- */
- function browserIsNetscape4() {
- return browser_is_netscape4();
- }
+ /**
+ * Return true if browser used to submit the request is netscape 4.
+ *
+ * @return bool
+ */
+ function browserIsNetscape4() {
+ return browser_is_netscape4();
+ }
- /**
- * Singleton method for the class.
- *
- * @return mixed HTTPRequest Object.
- */
- static function &instance() {
- static $_httprequest_instance;
- if (!$_httprequest_instance) {
- $_httprequest_instance = new HTTPRequest();
- }
- return $_httprequest_instance;
- }
+ /**
+ * Singleton method for the class.
+ *
+ * @return mixed HTTPRequest Object.
+ */
+ static function &instance() {
+ static $_httprequest_instance;
+ if (!$_httprequest_instance) {
+ $_httprequest_instance = new HTTPRequest();
+ }
+ return $_httprequest_instance;
+ }
- /**
- * Validate file upload.
- *
- * @param Valid_File Validator for files.
- * @return bool
- */
- function validFile(&$validator) {
- if(is_a($validator, 'Valid_File')) {
- $this->_validated_input[$validator->getKey()] = true;
- return $validator->validate($_FILES, $validator->getKey());
- } else {
- return false;
- }
- }
+ /**
+ * Validate file upload.
+ *
+ * @param Valid_File Validator for files.
+ * @return bool
+ */
+ function validFile(&$validator) {
+ if(is_a($validator, 'Valid_File')) {
+ $this->_validated_input[$validator->getKey()] = true;
+ return $validator->validate($_FILES, $validator->getKey());
+ } else {
+ return false;
+ }
+ }
- /**
- * Remove slashes in $value. If $value is an array, remove slashes for each
- * element.
- *
- * @access private
- * @param mixed $value
- * @return mixed
- */
- function _stripslashes($value) {
- if (is_string($value)) {
- $value = stripslashes($value);
- } elseif (is_array($value)) {
- foreach($value as $key => $val) {
- $value[$key] = $this->_stripslashes($val);
- }
- }
- return $value;
- }
+ /**
+ * Remove slashes in $value. If $value is an array, remove slashes for each
+ * element.
+ *
+ * @access private
+ * @param mixed $value
+ * @return mixed
+ */
+ function _stripslashes($value) {
+ if (is_string($value)) {
+ $value = stripslashes($value);
+ } elseif (is_array($value)) {
+ foreach($value as $key => $val) {
+ $value[$key] = $this->_stripslashes($val);
+ }
+ }
+ return $value;
+ }
- /**
- * Get the value of $variable in $array. If magic_quotes are enabled, the
- * value is escaped.
- *
- * @access private
- * @param string $variable Name of the parameter to get.
- * @param array $array Name of the parameter to get.
+ /**
+ * Get the value of $variable in $array. If magic_quotes are enabled, the
+ * value is escaped.
+ *
+ * @access private
+ * @param string $variable Name of the parameter to get.
+ * @param array $array Name of the parameter to get.
* @return bool|mixed
*/
- function _get($variable, $array) {
- if ($this->_exist($variable, $array)) {
- return (get_magic_quotes_gpc()?$this->_stripslashes($array[$variable]):$array[$variable]);
- } else {
- return false;
- }
- }
-
+ function _get($variable, $array) {
+ if ($this->_exist($variable, $array)) {
+ return (get_magic_quotes_gpc()?$this->_stripslashes($array[$variable]):$array[$variable]);
+ } else {
+ return false;
+ }
+ }
}
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=c2082ab2a7fb02075097cecc5fb32e5e69a57144
commit c2082ab2a7fb02075097cecc5fb32e5e69a57144
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 12:20:10 2018 +0200
tabs & missing licence
diff --git a/src/common/include/PluginInfo.class.php b/src/common/include/PluginInfo.class.php
index 9d293a2..1b3f5db 100644
--- a/src/common/include/PluginInfo.class.php
+++ b/src/common/include/PluginInfo.class.php
@@ -22,34 +22,33 @@
* PluginInfo
*/
class PluginInfo {
+ var $plugin;
+ var $pluginDescriptor;
+ var $propertyDescriptors;
- var $plugin;
- var $pluginDescriptor;
- var $propertyDescriptors;
+ function __construct($plugin) {
+ $this->plugin = $plugin;
+ }
- function __construct($plugin) {
- $this->plugin = $plugin;
- }
+ function setPluginDescriptor($descriptor) {
+ }
- function setPluginDescriptor($descriptor) {
- }
+ function getPluginDescriptor() {
+ }
+ function getPropertyDescriptors() {
+ }
- function getPluginDescriptor() {
- }
- function getPropertyDescriptors() {
- }
+ function _addPropertyDescriptor($descriptor) {
+ }
+ function _removePropertyDescriptor($descriptor) {
+ }
- function _addPropertyDescriptor($descriptor) {
- }
- function _removePropertyDescriptor($descriptor) {
- }
+ function loadProperties() {
+ }
- function loadProperties() {
- }
+ function saveProperties() {
+ }
- function saveProperties() {
- }
-
- function getPropertyDescriptorForName($name) {
- }
+ function getPropertyDescriptorForName($name) {
+ }
}
diff --git a/src/common/include/UserManager.class.php b/src/common/include/UserManager.class.php
index 343ac1d..5fbcec9 100644
--- a/src/common/include/UserManager.class.php
+++ b/src/common/include/UserManager.class.php
@@ -18,7 +18,7 @@
* along with Fusionforge. If not, see <http://www.gnu.org/licenses/>.
*/
-require_once 'User.class.php';
+require_once $gfcommon.'include/User.class.php';
class UserManager {
diff --git a/src/common/include/preplugins.php b/src/common/include/preplugins.php
index a472251..3236948 100644
--- a/src/common/include/preplugins.php
+++ b/src/common/include/preplugins.php
@@ -1,11 +1,30 @@
<?php
+/**
+ * Copyright (c) Xerox Corporation, Codendi Team, 2001-2009. All rights reserved
+ *
+ * This file is a part of Fusionforge.
+ *
+ * Fusionforge is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * Fusionforge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Fusionforge. If not, see <http://www.gnu.org/licenses/>.
+ */
+
//Codendi class for httpRequest
-require_once 'common/include/HTTPRequest.class.php';
+require_once $gfcommon.'include/HTTPRequest.class.php';
//Codendi class for hmlPurifier
-require_once 'common/include/Codendi_HTMLPurifier.class.php';
+require_once $gfcommon.'include/Codendi_HTMLPurifier.class.php';
//Codendi class for Validator
-require_once 'common/valid/ValidFactory.class.php';
+require_once $gfcommon.'valid/ValidFactory.class.php';
//Manager from Codendi
-require_once 'common/include/ProjectManager.class.php';
-require_once 'common/include/UserManager.class.php';
+require_once $gfcommon.'include/ProjectManager.class.php';
+require_once $gfcommon.'include/UserManager.class.php';
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=0c3d4c618dabcffd5ea23e8b48e7685179b7eced
commit 0c3d4c618dabcffd5ea23e8b48e7685179b7eced
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 12:19:44 2018 +0200
Unused file. Raise your hand if you really need it. :-)
diff --git a/src/common/include/PluginPersistence.class.php b/src/common/include/PluginPersistence.class.php
deleted file mode 100644
index 37de553..0000000
--- a/src/common/include/PluginPersistence.class.php
+++ /dev/null
@@ -1,141 +0,0 @@
-<?php
-/**
- * Handles persistence of data for plugins
- *
- * @author Olivier Berger
- *
- */
-
-/**
- * Handles persistence of data for a plugin as a whole
- *
- * @author Olivier Berger
- *
- */
-
-// May create an interface with 2 implementations : JSON or php serialize...
-
-class PluginPersistentStore extends FFError {
-
- var $plugin_id;
-
- /*
-
- CREATE TABLE plugins_persistence (
- plugin_id integer,
- persisted_key character varying(100),
- persisted_data bytea,
- -- CONSTRAINT plugins_persistence_pkey PRIMARY KEY (plugin_id, persisted_key) not necessary to have unique keys
- -- May need an index on (plugin_id, persisted_key)
- )
-*/
-
- const persistence_table = 'plugins_persistence';
-
- /**
- * @param int $plugin_id
- */
- function __construct($plugin_id) {
- $this->plugin_id = $plugin_id;
- }
-
- protected function additionalAndClause() {
- return '';
- }
-
- /**
- * Loads persisted objects (saved in serialized form)
- *
- * @param string $key
- * @return array
- */
- public function readObject($key) {
- $result = array();
- $res = db_query_params('SELECT persisted_data
- FROM '.self::persistence_table.'
- WHERE plugin_id = $1
- AND persisted_key = $2 '.$self->additionalAndClause(),
- array($this->plugin_id,
- $key));
- $rows = db_numrows($res);
-
- /*
- if ($rows > 1) {
- $this->setError(_('More than one value for the plugin + key'))
- }*/
- for ($i = 0; $i < $rows; $i++) {
- $data = db_result($res, $i, 'persisted_data');
- $object = unserialize($data);
- $result[] = $object;
- }
- return $result;
- }
-
- public function saveObject($object, $key) {
- $data = serialize($object);
- $res = db_query_params('INSERT INTO '.self::persistence_table.' (plugin_id, persisted_key, persisted_data) VALUES ($1, $2, $3)',
- array($this->plugin_id, $key, $data));
- }
-
-}
-
-/**
- * Handles persistence of data for a plugin, by group
- *
- * @author olivier
- *
- */
-class PluginGroupPersistentStore {
- var $group_plugin_id;
-
- /*
- CREATE TABLE group_plugin_persistence (
- group_plugin_id integer,
- persisted_key character varying(100),
- persisted_data bytea,
- CONSTRAINT plugins_persistence_pkey PRIMARY KEY (group_plugin_id, persisted_key)
-
- */
- public function __construct($plugin_id, $group_id) {
- parent::__construct($plugin_id);
-
- $res = db_query_params('SELECT group_plugin_id
- FROM group_plugin
- WHERE plugin_id=$1
- AND group_id=$2', array($plugin_id, $group_id));
- $rows = db_numrows($res);
-
- if ($rows > 1) {
- $this->setError(_('More than one value for the plugin + key'));
- }
- $this->group_plugin_id = db_result($res, 0, 'persisted_data');
- }
-
- protected function additionalAndClause() {
- $clause = parent::additionalAndClause();
- $clause .= 'AND group_plugin_id='.$this->group_plugin_id;
- return $clause;
- }
-
-}
-
-/**
- * Handles persistence of data for a plugin, by user
- *
- * @author olivier
- *
- */
-class PluginUserPersistentStore {
- var $user_id;
-
- /*
-
- CREATE TABLE user_plugin_persistence (
- user_plugin_id integer,
- persisted_key character varying(100),
- persisted_data bytea,
- CONSTRAINT plugins_persistence_pkey PRIMARY KEY (user_plugin_id, persisted_key)
-
- */
-
-}
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=0199db336bf7005e830256f1f6557b0bb205f50f
commit 0199db336bf7005e830256f1f6557b0bb205f50f
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 12:13:37 2018 +0200
tabs & empty lines
diff --git a/src/common/include/ProjectManager.class.php b/src/common/include/ProjectManager.class.php
index 6ebd60f..fe1a719 100644
--- a/src/common/include/ProjectManager.class.php
+++ b/src/common/include/ProjectManager.class.php
@@ -23,37 +23,34 @@
*/
class ProjectManager {
- /**
- * Hold an instance of the class
- */
- private static $_instance;
-
- /**
- * A private constructor; prevents direct creation of object
- */
- private function __construct() {
-
- }
-
- /**
- * ProjectManager is a singleton
- * @return ProjectManager
- */
- public static function instance() {
- if (!isset(self::$_instance)) {
- $c = __CLASS__;
- self::$_instance = new $c;
- }
- return self::$_instance;
- }
-
- /**
- * @param $group_id int The id of the project to look for
- * @return Project
- */
- public function & getProject($group_id) {
-
- return group_get_object($group_id);
- }
-
+ /**
+ * Hold an instance of the class
+ */
+ private static $_instance;
+
+ /**
+ * A private constructor; prevents direct creation of object
+ */
+ private function __construct() {
+ }
+
+ /**
+ * ProjectManager is a singleton
+ * @return ProjectManager
+ */
+ public static function instance() {
+ if (!isset(self::$_instance)) {
+ $c = __CLASS__;
+ self::$_instance = new $c;
+ }
+ return self::$_instance;
+ }
+
+ /**
+ * @param $group_id int The id of the project to look for
+ * @return Project
+ */
+ public function & getProject($group_id) {
+ return group_get_object($group_id);
+ }
}
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=d95f48d862e56920b03173be796078b4986585d0
commit d95f48d862e56920b03173be796078b4986585d0
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date: Tue May 1 11:13:36 2018 +0200
fix typo & prepare for massive user/group support
diff --git a/src/common/include/account.php b/src/common/include/account.php
index d3e0108..5d1a7a1 100644
--- a/src/common/include/account.php
+++ b/src/common/include/account.php
@@ -270,7 +270,7 @@ function account_get_user_default_shell() {
* @return array Available shells
*/
function account_getavailableshells($add_user_default_shell = true) {
- // we'd better use the shells defined inside the 'chroot' in {core/chroot}/etc/shells it it exists
+ // we'd better use the shells defined inside the 'chroot' in {core/chroot}/etc/shells if it exists
$chroot = forge_get_config('chroot');
$shells_file = $chroot.'/etc/shells';
if(! file_exists($shells_file) ) {
@@ -341,7 +341,7 @@ function account_shellselects($current) {
* @return string home directory path
*/
function account_user_homedir($user) {
- //return '/home/users/'.substr($user,0,1).'/'.substr($user,0,2).'/'.$user;
+ //return forge_get_config('homedir_prefix').'/'.substr($user,0,1).'/'.substr($user,0,2).'/'.$user;
return forge_get_config('homedir_prefix').'/'.$user;
}
@@ -352,7 +352,7 @@ function account_user_homedir($user) {
* @return string home directory path
*/
function account_group_homedir($group) {
- //return '/home/groups/'.substr($group,0,1).'/'.substr($group,0,2).'/'.$group;
+ //return forge_get_config('groupdir_prefix').'/'.substr($group,0,1).'/'.substr($group,0,2).'/'.$group;
return forge_get_config('groupdir_prefix').'/'.$group;
}
-----------------------------------------------------------------------
Summary of changes:
src/common/include/HTTPRequest.class.php | 187 ++++++++++++-------------
src/common/include/Navigation.class.php | 4 -
src/common/include/PluginInfo.class.php | 45 +++---
src/common/include/PluginPersistence.class.php | 141 -------------------
src/common/include/ProjectManager.class.php | 63 ++++-----
src/common/include/TroveCat.class.php | 20 ++-
src/common/include/UserManager.class.php | 2 +-
src/common/include/account.php | 6 +-
src/common/include/preplugins.php | 29 +++-
src/www/include/canned_responses.php | 22 ++-
src/www/include/project_summary.php | 14 +-
src/www/include/role_utils.php | 10 +-
src/www/include/trove.php | 2 +-
src/www/include/vote_function.php | 30 ++--
14 files changed, 220 insertions(+), 355 deletions(-)
delete mode 100644 src/common/include/PluginPersistence.class.php
hooks/post-receive
--
FusionForge
More information about the Fusionforge-commits
mailing list