Fix phpcs

This commit is contained in:
Laurent Destailleur 2019-05-16 14:38:01 +02:00
parent ac1bab1711
commit 399ffb2dcc
11 changed files with 47 additions and 79 deletions

View File

@ -12,4 +12,3 @@ define('DOL_URL_ROOT', '/');
if (! defined("NOLOGIN")) define("NOLOGIN", '1'); if (! defined("NOLOGIN")) define("NOLOGIN", '1');
global $conf, $langs, $user, $db; global $conf, $langs, $user, $db;
include_once __DIR__ . '/../../htdocs/main.inc.php'; include_once __DIR__ . '/../../htdocs/main.inc.php';

View File

@ -209,20 +209,13 @@ if ($resql) {
/** /**
* Send email * Send email
* *
* @param string $mode * @param string $mode Mode (test | confirm)
* Mode (test | confirm) * @param string $oldemail Target email
* @param string $oldemail * @param string $message Message to send
* Target email * @param string $total Total amount of unpayed invoices
* @param string $message * @param string $userlang Code lang to use for email output.
* Message to send * @param string $oldtarget Target name
* @param string $total * @param int $duration_value duration value
* Total amount of unpayed invoices
* @param string $userlang
* Code lang to use for email output.
* @param string $oldtarget
* Target name
* @param int $duration_value
* duration value
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
function envoi_mail($mode, $oldemail, $message, $total, $userlang, $oldtarget, $duration_value) function envoi_mail($mode, $oldemail, $message, $total, $userlang, $oldtarget, $duration_value)

View File

@ -168,20 +168,13 @@ if ($resql) {
/** /**
* Send email * Send email
* *
* @param string $mode * @param string $mode Mode (test | confirm)
* Mode (test | confirm) * @param string $oldemail Old email
* @param string $oldemail * @param string $message Message to send
* Old email * @param string $total Total amount of unpayed invoices
* @param string $message * @param string $userlang Code lang to use for email output.
* Message to send * @param string $oldsalerepresentative Old sale representative
* @param string $total * @param int $duration_value Duration value
* Total amount of unpayed invoices
* @param string $userlang
* Code lang to use for email output.
* @param string $oldsalerepresentative
* Old sale representative
* @param int $duration_value
* duration value
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
function envoi_mail($mode, $oldemail, $message, $total, $userlang, $oldsalerepresentative, $duration_value) function envoi_mail($mode, $oldemail, $message, $total, $userlang, $oldsalerepresentative, $duration_value)

View File

@ -229,16 +229,12 @@ exit(0);
/** /**
* script cron usage * script cron usage
* *
* @param string $path * @param string $path Path
* path * @param string $script_file Filename
* @param string $script_file
* filename
* @return void * @return void
*/ */
function usage($path, $script_file) function usage($path, $script_file)
{ {
global $conf;
print "Usage: " . $script_file . " securitykey userlogin|'firstadmin' [cronjobid]\n"; print "Usage: " . $script_file . " securitykey userlogin|'firstadmin' [cronjobid]\n";
print "The script return 0 when everything worked successfully.\n"; print "The script return 0 when everything worked successfully.\n";
print "\n"; print "\n";

View File

@ -207,18 +207,12 @@ if ($resql) {
/** /**
* Send email * Send email
* *
* @param string $mode * @param string $mode Mode (test | confirm)
* Mode (test | confirm) * @param string $oldemail Target email
* @param string $oldemail * @param string $message Message to send
* Target email * @param string $total Total amount of unpayed invoices
* @param string $message * @param string $userlang Code lang to use for email output.
* Message to send * @param string $oldtarget Target name
* @param string $total
* Total amount of unpayed invoices
* @param string $userlang
* Code lang to use for email output.
* @param string $oldtarget
* Target name
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
function envoi_mail($mode, $oldemail, $message, $total, $userlang, $oldtarget) function envoi_mail($mode, $oldemail, $message, $total, $userlang, $oldtarget)

View File

@ -172,18 +172,12 @@ if ($resql) {
/** /**
* Send email * Send email
* *
* @param string $mode * @param string $mode Mode (test | confirm)
* Mode (test | confirm) * @param string $oldemail Old email
* @param string $oldemail * @param string $message Message to send
* Old email * @param string $total Total amount of unpayed invoices
* @param string $message * @param string $userlang Code lang to use for email output.
* Message to send * @param string $oldsalerepresentative Old sale representative
* @param string $total
* Total amount of unpayed invoices
* @param string $userlang
* Code lang to use for email output.
* @param string $oldsalerepresentative
* Old sale representative
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
function envoi_mail($mode, $oldemail, $message, $total, $userlang, $oldsalerepresentative) function envoi_mail($mode, $oldemail, $message, $total, $userlang, $oldsalerepresentative)

View File

@ -272,11 +272,11 @@ if ($result >= 0) {
exit($error); exit($error);
/** /**
* Function to say if a value is empty or not * Function to say if a value is empty or not
* *
* @param string $element * @param string $element Value to test
* Value to test
* @return boolean True of false * @return boolean True of false
*/ */
function dolValidElement($element) function dolValidElement($element)

View File

@ -181,11 +181,11 @@ if ($result >= 0) {
exit($error); exit($error);
/** /**
* Function to say if a value is empty or not * Function to say if a value is empty or not
* *
* @param string $element * @param string $element Value to test
* Value to test
* @return boolean True of false * @return boolean True of false
*/ */
function dolValidElementType($element) function dolValidElementType($element)

View File

@ -86,8 +86,7 @@ exit($error);
/** /**
* Migrate file from old path to new one for product $product * Migrate file from old path to new one for product $product
* *
* @param Product $product * @param Product $product Object product
* Object product
* @return void * @return void
*/ */
function migrate_product_photospath($product) function migrate_product_photospath($product)

View File

@ -230,11 +230,11 @@ if ($result >= 0) {
exit($error); exit($error);
/** /**
* Function to say if a value is empty or not * Function to say if a value is empty or not
* *
* @param string $element * @param string $element Value to test
* Value to test
* @return boolean True of false * @return boolean True of false
*/ */
function dolValidElement($element) function dolValidElement($element)

View File

@ -273,11 +273,11 @@ if ($result >= 0) {
exit($error); exit($error);
/** /**
* Function to say if a value is empty or not * Function to say if a value is empty or not
* *
* @param string $element * @param string $element Value to test
* Value to test
* @return boolean True of false * @return boolean True of false
*/ */
function dolValidElement($element) function dolValidElement($element)