This commit is contained in:
Frédéric FRANCE
2019-02-25 22:27:04 +01:00
parent 1c07006015
commit c89e4d79b8
19 changed files with 376 additions and 373 deletions

View File

@@ -49,7 +49,7 @@ class modPhpbarcode extends ModeleBarCode
*
* @return boolean true if module can be used
*/
function isEnabled()
public function isEnabled()
{
return true;
}
@@ -60,7 +60,7 @@ class modPhpbarcode extends ModeleBarCode
*
* @return string Texte descripif
*/
function info()
public function info()
{
global $langs;
@@ -76,7 +76,7 @@ class modPhpbarcode extends ModeleBarCode
*
* @return boolean false si conflit, true si ok
*/
function canBeActivated()
public function canBeActivated()
{
global $langs;
@@ -90,7 +90,7 @@ class modPhpbarcode extends ModeleBarCode
* @param string $encoding Encoding norm
* @return int >0 if supported, 0 if not
*/
function encodingIsSupported($encoding)
public function encodingIsSupported($encoding)
{
global $genbarcode_loc;
//print 'genbarcode_loc='.$genbarcode_loc.' encoding='.$encoding;exit;
@@ -100,8 +100,7 @@ class modPhpbarcode extends ModeleBarCode
if ($encoding == 'ISBN') $supported=1;
// Formats that hangs on Windows (when genbarcode.exe for Windows is called, so they are not
// activated on Windows)
if (file_exists($genbarcode_loc) && empty($_SERVER["WINDIR"]))
{
if (file_exists($genbarcode_loc) && empty($_SERVER["WINDIR"])) {
if ($encoding == 'EAN8') $supported=1;
if ($encoding == 'UPC') $supported=1;
if ($encoding == 'C39') $supported=1;
@@ -120,7 +119,7 @@ class modPhpbarcode extends ModeleBarCode
* @param integer $nooutputiferror No output if error
* @return int <0 if KO, >0 if OK
*/
function buildBarCode($code, $encoding, $readable = 'Y', $scale = 1, $nooutputiferror = 0)
public function buildBarCode($code, $encoding, $readable = 'Y', $scale = 1, $nooutputiferror = 0)
{
global $_GET,$_SERVER;
global $conf;
@@ -161,7 +160,7 @@ class modPhpbarcode extends ModeleBarCode
* @param integer $nooutputiferror No output if error
* @return int <0 if KO, >0 if OK
*/
function writeBarCode($code, $encoding, $readable = 'Y', $scale = 1, $nooutputiferror = 0)
public function writeBarCode($code, $encoding, $readable = 'Y', $scale = 1, $nooutputiferror = 0)
{
global $conf,$filebarcode;

View File

@@ -49,7 +49,7 @@ class modTcpdfbarcode extends ModeleBarCode
*
* @return string Text with description
*/
function info()
public function info()
{
global $langs;
@@ -61,7 +61,7 @@ class modTcpdfbarcode extends ModeleBarCode
*
* @return boolean true if module can be used
*/
function isEnabled()
public function isEnabled()
{
return true;
}
@@ -72,7 +72,7 @@ class modTcpdfbarcode extends ModeleBarCode
*
* @return boolean false si conflit, true si ok
*/
function canBeActivated()
public function canBeActivated()
{
global $langs;
@@ -85,7 +85,7 @@ class modTcpdfbarcode extends ModeleBarCode
* @param string $encoding Encoding norm
* @return int >0 if supported, 0 if not
*/
function encodingIsSupported($encoding)
public function encodingIsSupported($encoding)
{
$tcpdfEncoding = $this->getTcpdfEncodingType($encoding);
if (empty($tcpdfEncoding)) {
@@ -105,7 +105,7 @@ class modTcpdfbarcode extends ModeleBarCode
* @param integer $nooutputiferror No output if error (not used with this engine)
* @return int <0 if KO, >0 if OK
*/
function buildBarCode($code, $encoding, $readable = 'Y', $scale = 1, $nooutputiferror = 0)
public function buildBarCode($code, $encoding, $readable = 'Y', $scale = 1, $nooutputiferror = 0)
{
global $_GET;
@@ -152,7 +152,7 @@ class modTcpdfbarcode extends ModeleBarCode
* @param integer $nooutputiferror No output if error (not used with this engine)
* @return int <0 if KO, >0 if OK
*/
function writeBarCode($code, $encoding, $readable = 'Y', $scale = 1, $nooutputiferror = 0)
public function writeBarCode($code, $encoding, $readable = 'Y', $scale = 1, $nooutputiferror = 0)
{
global $conf,$_GET;