mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-06 09:38:23 +01:00
function Comment Missing
This commit is contained in:
@@ -238,9 +238,9 @@
|
||||
<!--<rule ref="PEAR.Commenting.FunctionComment.MissingReturn">
|
||||
<severity>0</severity>
|
||||
</rule>-->
|
||||
<rule ref="PEAR.Commenting.FunctionComment.Missing">
|
||||
<!--<rule ref="PEAR.Commenting.FunctionComment.Missing">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
</rule>-->
|
||||
|
||||
<rule ref="PEAR.Commenting.FunctionComment.SpacingAfterParamType" />
|
||||
|
||||
|
||||
@@ -25,9 +25,18 @@ include_once DOL_DOCUMENT_ROOT.'/admin/dolistore/class/PSWebServiceLibrary.class
|
||||
*/
|
||||
class Dolistore
|
||||
{
|
||||
// params
|
||||
public $start; // beginning of pagination
|
||||
public $end; // end of pagination
|
||||
/**
|
||||
* beginning of pagination
|
||||
* @var int
|
||||
*/
|
||||
|
||||
public $start;
|
||||
/**
|
||||
* end of pagination
|
||||
* @var int
|
||||
*/
|
||||
public $end;
|
||||
|
||||
public $per_page; // pagination: display per page
|
||||
public $categorie; // the current categorie
|
||||
public $search; // the search keywords
|
||||
@@ -282,16 +291,33 @@ class Dolistore
|
||||
return $html;
|
||||
}
|
||||
|
||||
/**
|
||||
* get previous link
|
||||
*
|
||||
* @param string $text symbol previous
|
||||
* @return string html previous link
|
||||
*/
|
||||
function get_previous_link($text = '<<')
|
||||
{
|
||||
return '<a href="'.$this->get_previous_url().'" class="button">'.$text.'</a>';
|
||||
}
|
||||
|
||||
/**
|
||||
* get next link
|
||||
*
|
||||
* @param string $text symbol next
|
||||
* @return string html next link
|
||||
*/
|
||||
function get_next_link($text = '>>')
|
||||
{
|
||||
return '<a href="'.$this->get_next_url().'" class="button">'.$text.'</a>';
|
||||
}
|
||||
|
||||
/**
|
||||
* get previous url
|
||||
*
|
||||
* @return string previous url
|
||||
*/
|
||||
function get_previous_url()
|
||||
{
|
||||
$param_array = array();
|
||||
@@ -309,6 +335,11 @@ class Dolistore
|
||||
return $this->url."&".$param;
|
||||
}
|
||||
|
||||
/**
|
||||
* get next url
|
||||
*
|
||||
* @return string next url
|
||||
*/
|
||||
function get_next_url()
|
||||
{
|
||||
$param_array = array();
|
||||
@@ -326,6 +357,13 @@ class Dolistore
|
||||
return $this->url."&".$param;
|
||||
}
|
||||
|
||||
/**
|
||||
* version compare
|
||||
*
|
||||
* @param string $v1 version 1
|
||||
* @param string $v2 version 2
|
||||
* @return int result of compare
|
||||
*/
|
||||
function version_compare($v1, $v2)
|
||||
{
|
||||
$v1 = explode('.', $v1);
|
||||
@@ -355,4 +393,3 @@ class Dolistore
|
||||
return $ret;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -52,6 +52,12 @@ if (!$mode) $mode='config';
|
||||
|
||||
// used in library escpos maybe useful if php doesn't support gzdecode
|
||||
if (!function_exists('gzdecode')) {
|
||||
/**
|
||||
* Gzdecode
|
||||
*
|
||||
* @param string $data data to deflate
|
||||
* @return string data deflated
|
||||
*/
|
||||
function gzdecode($data)
|
||||
{
|
||||
return gzinflate(substr($data,10,-8));
|
||||
@@ -450,4 +456,3 @@ if ($mode == 'template' && $user->admin)
|
||||
// End of page
|
||||
llxFooter();
|
||||
$db->close();
|
||||
|
||||
|
||||
@@ -607,19 +607,19 @@ function GETPOST($paramname, $check='none', $method=0, $filter=null, $options=nu
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Return a prefix to use for this Dolibarr instance, for session/cookie names or email id.
|
||||
* This prefix is valid in a web context only and is unique for instance and avoid conflict
|
||||
* between multi-instances, even when having two instances with one root dir or two instances
|
||||
* in virtual servers.
|
||||
*
|
||||
* @param string $mode '' (prefix for session name) or 'email' (prefix for email id)
|
||||
* @return string A calculated prefix
|
||||
*/
|
||||
if (! function_exists('dol_getprefix'))
|
||||
{
|
||||
function dol_getprefix($mode='')
|
||||
{
|
||||
/**
|
||||
* Return a prefix to use for this Dolibarr instance, for session/cookie names or email id.
|
||||
* This prefix is valid in a web context only and is unique for instance and avoid conflict
|
||||
* between multi-instances, even when having two instances with one root dir or two instances
|
||||
* in virtual servers.
|
||||
*
|
||||
* @param string $mode '' (prefix for session name) or 'email' (prefix for email id)
|
||||
* @return string A calculated prefix
|
||||
*/
|
||||
function dol_getprefix($mode='')
|
||||
{
|
||||
global $conf;
|
||||
|
||||
// If MAIL_PREFIX_FOR_EMAIL_ID is set and prefix is for email
|
||||
|
||||
@@ -1167,6 +1167,14 @@ function get_next_value($db,$mask,$table,$field,$where='',$objsoc='',$date='',$m
|
||||
return $numFinal;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get string between
|
||||
*
|
||||
* @param string $string String to test
|
||||
* @param int $start Value for start
|
||||
* @param int $end Value for end
|
||||
* @return string Return part of string
|
||||
*/
|
||||
function get_string_between($string, $start, $end)
|
||||
{
|
||||
$string = " ".$string;
|
||||
|
||||
@@ -34,11 +34,18 @@ class CdavLib
|
||||
|
||||
private $langs;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param User $user user
|
||||
* @param DoliDB $db Database handler
|
||||
* @param Translation $langs translation
|
||||
*/
|
||||
function __construct($user, $db, $langs)
|
||||
{
|
||||
$this->user = $user;
|
||||
$this->db = $db;
|
||||
$this->langs = $langs;
|
||||
$this->user = $user;
|
||||
$this->db = $db;
|
||||
$this->langs = $langs;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -657,6 +657,9 @@ class PropalmergepdfproductLine
|
||||
var $tms='';
|
||||
var $import_key;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
function __construct()
|
||||
{
|
||||
return 1;
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
/**
|
||||
* Define head array for tabs of inventory tools setup pages
|
||||
*
|
||||
* @return Array of head
|
||||
* @return array Array of head
|
||||
*/
|
||||
function inventoryAdminPrepareHead()
|
||||
{
|
||||
@@ -55,6 +55,15 @@ function inventoryAdminPrepareHead()
|
||||
return $head;
|
||||
}
|
||||
|
||||
/**
|
||||
* Define head array for tabs of inventory tools setup pages
|
||||
*
|
||||
* @param Inventory $inventory Object inventory
|
||||
* @param string $title parameter
|
||||
* @param string $get parameter
|
||||
*
|
||||
* @return array Array of head
|
||||
*/
|
||||
function inventoryPrepareHead(&$inventory, $title='Inventory', $get='')
|
||||
{
|
||||
global $langs;
|
||||
@@ -66,6 +75,13 @@ function inventoryPrepareHead(&$inventory, $title='Inventory', $get='')
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Define head array for tabs of inventory tools setup pages
|
||||
*
|
||||
* @param Inventory $inventory Object inventory
|
||||
*
|
||||
* @return string html of products
|
||||
*/
|
||||
function inventorySelectProducts(&$inventory)
|
||||
{
|
||||
global $conf,$db,$langs;
|
||||
@@ -101,4 +117,3 @@ function inventorySelectProducts(&$inventory)
|
||||
|
||||
return $select_html;
|
||||
}
|
||||
|
||||
|
||||
@@ -53,6 +53,11 @@ class ProductAttribute
|
||||
*/
|
||||
public $rang;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param DoliDB $db Database handler
|
||||
*/
|
||||
public function __construct(DoliDB $db)
|
||||
{
|
||||
global $conf;
|
||||
|
||||
@@ -52,8 +52,13 @@ class ProductAttributeValue
|
||||
*/
|
||||
public $value;
|
||||
|
||||
public function __construct(DoliDB $db)
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param DoliDB $db Database handler
|
||||
*/
|
||||
public function __construct(DoliDB $db)
|
||||
{
|
||||
global $conf;
|
||||
|
||||
$this->db = $db;
|
||||
|
||||
@@ -70,7 +70,12 @@ class ProductCombination
|
||||
*/
|
||||
public $entity;
|
||||
|
||||
public function __construct(DoliDB $db)
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param DoliDB $db Database handler
|
||||
*/
|
||||
public function __construct(DoliDB $db)
|
||||
{
|
||||
global $conf;
|
||||
|
||||
|
||||
@@ -52,10 +52,15 @@ class ProductCombination2ValuePair
|
||||
*/
|
||||
public $fk_prod_attr_val;
|
||||
|
||||
public function __construct(DoliDB $db)
|
||||
{
|
||||
$this->db = $db;
|
||||
}
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param DoliDB $db Database handler
|
||||
*/
|
||||
public function __construct(DoliDB $db)
|
||||
{
|
||||
$this->db = $db;
|
||||
}
|
||||
|
||||
/**
|
||||
* Translates this class to a human-readable string
|
||||
|
||||
Reference in New Issue
Block a user