@@ -50,7 +50,7 @@ discard block |
||
| 50 | 50 | public $version = 'dolibarr'; |
| 51 | 51 | |
| 52 | 52 | |
| 53 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 53 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 54 | 54 | /** |
| 55 | 55 | * Return list of active generation modules |
| 56 | 56 | * |
@@ -60,7 +60,7 @@ discard block |
||
| 60 | 60 | */ |
| 61 | 61 | public static function liste_modeles($db, $maxfilenamelength = 0) |
| 62 | 62 | { |
| 63 | - // phpcs:enable |
|
| 63 | + // phpcs:enable |
|
| 64 | 64 | $type = 'stock'; |
| 65 | 65 | $list = array(); |
| 66 | 66 | |
@@ -119,7 +119,7 @@ discard block |
||
| 119 | 119 | } |
| 120 | 120 | |
| 121 | 121 | |
| 122 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 122 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 123 | 123 | /** |
| 124 | 124 | * Function to build a document on disk using the generic odt module. |
| 125 | 125 | * |
@@ -133,7 +133,7 @@ discard block |
||
| 133 | 133 | */ |
| 134 | 134 | public function write_file($object, $outputlangs, $srctemplatepath = '', $hidedetails = 0, $hidedesc = 0, $hideref = 0) |
| 135 | 135 | { |
| 136 | - // phpcs:enable |
|
| 136 | + // phpcs:enable |
|
| 137 | 137 | global $user, $langs, $conf, $mysoc, $db, $hookmanager; |
| 138 | 138 | |
| 139 | 139 | if (!is_object($outputlangs)) { |
@@ -572,7 +572,7 @@ discard block |
||
| 572 | 572 | } |
| 573 | 573 | } |
| 574 | 574 | |
| 575 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 575 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 576 | 576 | /** |
| 577 | 577 | * Show table for lines |
| 578 | 578 | * |
@@ -679,7 +679,7 @@ discard block |
||
| 679 | 679 | } |
| 680 | 680 | } |
| 681 | 681 | |
| 682 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 682 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 683 | 683 | /** |
| 684 | 684 | * Show top header of page. |
| 685 | 685 | * |
@@ -833,7 +833,7 @@ discard block |
||
| 833 | 833 | return $top_shift; |
| 834 | 834 | } |
| 835 | 835 | |
| 836 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 836 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore |
|
| 837 | 837 | /** |
| 838 | 838 | * Show footer of page. Need this->emetteur object |
| 839 | 839 | * |
@@ -630,7 +630,7 @@ |
||
| 630 | 630 | |
| 631 | 631 | |
| 632 | 632 | if (empty($hidetop)) { |
| 633 | - $pdf->line($this->marge_gauche, $tab_top + 11, $this->page_largeur - $this->marge_droite, $tab_top + 11); // line takes a position y in 2nd parameter and 4th parameter |
|
| 633 | + $pdf->line($this->marge_gauche, $tab_top + 11, $this->page_largeur - $this->marge_droite, $tab_top + 11); // line takes a position y in 2nd parameter and 4th parameter |
|
| 634 | 634 | $pdf->SetXY($this->posxdesc - 1, $tab_top + 1); |
| 635 | 635 | $pdf->MultiCell($this->wref, 3, $outputlangs->transnoentities("Ref"), '', 'L'); |
| 636 | 636 | } |
@@ -190,7 +190,7 @@ discard block |
||
| 190 | 190 | return $texte; |
| 191 | 191 | } |
| 192 | 192 | |
| 193 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 193 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 194 | 194 | /** |
| 195 | 195 | * Function to build a document on disk using the generic odt module. |
| 196 | 196 | * |
@@ -204,7 +204,7 @@ discard block |
||
| 204 | 204 | */ |
| 205 | 205 | public function write_file($object, $outputlangs, $srctemplatepath, $hidedetails = 0, $hidedesc = 0, $hideref = 0) |
| 206 | 206 | { |
| 207 | - // phpcs:enable |
|
| 207 | + // phpcs:enable |
|
| 208 | 208 | global $stock, $langs, $conf, $mysoc, $hookmanager, $user; |
| 209 | 209 | |
| 210 | 210 | if (empty($srctemplatepath)) { |
@@ -173,7 +173,7 @@ |
||
| 173 | 173 | $maxfilesizearray = getMaxFileSizeArray(); |
| 174 | 174 | $maxmin = $maxfilesizearray['maxmin']; |
| 175 | 175 | if ($maxmin > 0) { |
| 176 | - $texte .= '<input type="hidden" name="MAX_FILE_SIZE" value="' . ($maxmin * 1024) . '">'; // MAX_FILE_SIZE must precede the field type=file |
|
| 176 | + $texte .= '<input type="hidden" name="MAX_FILE_SIZE" value="' . ($maxmin * 1024) . '">'; // MAX_FILE_SIZE must precede the field type=file |
|
| 177 | 177 | } |
| 178 | 178 | $texte .= ' <input type="file" name="uploadfile">'; |
| 179 | 179 | $texte .= '<input type="hidden" value="STOCK_ADDON_PDF_ODT_PATH" name="keyforuploaddir">'; |
@@ -215,7 +215,7 @@ discard block |
||
| 215 | 215 | return $texte; |
| 216 | 216 | } |
| 217 | 217 | |
| 218 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 218 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 219 | 219 | /** |
| 220 | 220 | * Function to build a document on disk using the generic odt module. |
| 221 | 221 | * |
@@ -229,7 +229,7 @@ discard block |
||
| 229 | 229 | */ |
| 230 | 230 | public function write_file($object, $outputlangs, $srctemplatepath, $hidedetails = 0, $hidedesc = 0, $hideref = 0) |
| 231 | 231 | { |
| 232 | - // phpcs:enable |
|
| 232 | + // phpcs:enable |
|
| 233 | 233 | global $user, $langs, $conf, $mysoc, $hookmanager; |
| 234 | 234 | |
| 235 | 235 | if (empty($srctemplatepath)) { |
@@ -438,7 +438,7 @@ discard block |
||
| 438 | 438 | return -1; |
| 439 | 439 | } |
| 440 | 440 | |
| 441 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 441 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 442 | 442 | /** |
| 443 | 443 | * get substitution array for object |
| 444 | 444 | * |
@@ -449,7 +449,7 @@ discard block |
||
| 449 | 449 | */ |
| 450 | 450 | public function get_substitutionarray_object($object, $outputlangs, $array_key = 'object') |
| 451 | 451 | { |
| 452 | - // phpcs:enable |
|
| 452 | + // phpcs:enable |
|
| 453 | 453 | if (!$object instanceof User) { |
| 454 | 454 | dol_syslog("Expected User object, got " . gettype($object), LOG_ERR); |
| 455 | 455 | return array(); |
@@ -198,7 +198,7 @@ |
||
| 198 | 198 | $maxfilesizearray = getMaxFileSizeArray(); |
| 199 | 199 | $maxmin = $maxfilesizearray['maxmin']; |
| 200 | 200 | if ($maxmin > 0) { |
| 201 | - $texte .= '<input type="hidden" name="MAX_FILE_SIZE" value="' . ($maxmin * 1024) . '">'; // MAX_FILE_SIZE must precede the field type=file |
|
| 201 | + $texte .= '<input type="hidden" name="MAX_FILE_SIZE" value="' . ($maxmin * 1024) . '">'; // MAX_FILE_SIZE must precede the field type=file |
|
| 202 | 202 | } |
| 203 | 203 | $texte .= ' <input type="file" name="uploadfile">'; |
| 204 | 204 | $texte .= '<input type="hidden" value="USER_ADDON_PDF_ODT_PATH" name="keyforuploaddir">'; |
@@ -32,7 +32,7 @@ discard block |
||
| 32 | 32 | * \brief File with parent class for generating contracts to PDF and File of class to manage contract numbering |
| 33 | 33 | */ |
| 34 | 34 | |
| 35 | - require_once DOL_DOCUMENT_ROOT . '/core/class/commondocgenerator.class.php'; |
|
| 35 | + require_once DOL_DOCUMENT_ROOT . '/core/class/commondocgenerator.class.php'; |
|
| 36 | 36 | |
| 37 | 37 | /** |
| 38 | 38 | * Parent class to manage intervention document templates |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | public $error = ''; |
| 46 | 46 | |
| 47 | 47 | |
| 48 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 48 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 49 | 49 | /** |
| 50 | 50 | * Return list of active generation modules |
| 51 | 51 | * |
@@ -55,7 +55,7 @@ discard block |
||
| 55 | 55 | */ |
| 56 | 56 | public static function liste_modeles($db, $maxfilenamelength = 0) |
| 57 | 57 | { |
| 58 | - // phpcs:enable |
|
| 58 | + // phpcs:enable |
|
| 59 | 59 | $type = 'user'; |
| 60 | 60 | $list = array(); |
| 61 | 61 | |
@@ -38,7 +38,7 @@ |
||
| 38 | 38 | */ |
| 39 | 39 | class modDataPolicy extends DolibarrModules |
| 40 | 40 | { |
| 41 | - // @codingStandardsIgnoreEnd |
|
| 41 | + // @codingStandardsIgnoreEnd |
|
| 42 | 42 | /** |
| 43 | 43 | * Constructor. Define names, constants, directories, boxes, permissions |
| 44 | 44 | * |
@@ -269,7 +269,7 @@ discard block |
||
| 269 | 269 | } |
| 270 | 270 | |
| 271 | 271 | |
| 272 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 272 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 273 | 273 | /** |
| 274 | 274 | * Return if a code is used (by other element) |
| 275 | 275 | * |
@@ -280,7 +280,7 @@ discard block |
||
| 280 | 280 | */ |
| 281 | 281 | public function verif_dispo($db, $code, $product) |
| 282 | 282 | { |
| 283 | - // phpcs:enable |
|
| 283 | + // phpcs:enable |
|
| 284 | 284 | $sql = "SELECT barcode FROM " . MAIN_DB_PREFIX . "product"; |
| 285 | 285 | $sql .= " WHERE barcode = '" . $db->escape($code) . "'"; |
| 286 | 286 | $sql .= " AND entity IN (" . getEntity('product') . ")"; |
@@ -301,7 +301,7 @@ discard block |
||
| 301 | 301 | } |
| 302 | 302 | } |
| 303 | 303 | |
| 304 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 304 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 305 | 305 | /** |
| 306 | 306 | * Return if a barcode value match syntax |
| 307 | 307 | * |
@@ -311,7 +311,7 @@ discard block |
||
| 311 | 311 | */ |
| 312 | 312 | public function verif_syntax($codefortest, $typefortest) |
| 313 | 313 | { |
| 314 | - // phpcs:enable |
|
| 314 | + // phpcs:enable |
|
| 315 | 315 | global $conf; |
| 316 | 316 | |
| 317 | 317 | $result = 0; |
@@ -197,7 +197,7 @@ discard block |
||
| 197 | 197 | //Begin barcode with key: for barcode with key (EAN13...) calculate and substitute the last character (* or ?) used in the mask by the key |
| 198 | 198 | if ((substr($numFinal, -1) == '*') or (substr($numFinal, -1) == '?')) { // if last mask character is * or ? a joker, probably we have to calculate a key as last character (EAN13...) |
| 199 | 199 | $literaltype = ''; |
| 200 | - $literaltype = $this->literalBarcodeType($db, $type);//get literal_Barcode_Type |
|
| 200 | + $literaltype = $this->literalBarcodeType($db, $type); //get literal_Barcode_Type |
|
| 201 | 201 | switch ($literaltype) { |
| 202 | 202 | case 'EAN13': //EAN13 rowid = 2 |
| 203 | 203 | if (strlen($numFinal) == 13) {// be sure that the mask length is correct for EAN13 |
@@ -244,7 +244,7 @@ discard block |
||
| 244 | 244 | $code = strtoupper(trim($code)); |
| 245 | 245 | |
| 246 | 246 | if (empty($code) && $this->code_null && !getDolGlobalString('BARCODE_STANDARD_PRODUCT_MASK')) { |
| 247 | - $result = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 247 | + $result = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 248 | 248 | } elseif (empty($code) && (!$this->code_null || getDolGlobalString('BARCODE_STANDARD_PRODUCT_MASK'))) { |
| 249 | 249 | $result = -2; |
| 250 | 250 | } else { |
@@ -253,7 +253,7 @@ discard block |
||
| 253 | 253 | if ($is_dispo != 0) { |
| 254 | 254 | $result = -3; |
| 255 | 255 | } else { |
| 256 | - $result = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 256 | + $result = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 257 | 257 | } |
| 258 | 258 | } else { |
| 259 | 259 | if (dol_strlen($code) == 0) { |
@@ -273,7 +273,7 @@ discard block |
||
| 273 | 273 | } |
| 274 | 274 | |
| 275 | 275 | |
| 276 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 276 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 277 | 277 | /** |
| 278 | 278 | * Return if a code is used (by other element) |
| 279 | 279 | * |
@@ -284,7 +284,7 @@ discard block |
||
| 284 | 284 | */ |
| 285 | 285 | public function verif_dispo($db, $code, $thirdparty) |
| 286 | 286 | { |
| 287 | - // phpcs:enable |
|
| 287 | + // phpcs:enable |
|
| 288 | 288 | $sql = "SELECT barcode FROM " . MAIN_DB_PREFIX . "societe"; |
| 289 | 289 | $sql .= " WHERE barcode = '" . $db->escape($code) . "'"; |
| 290 | 290 | if ($thirdparty->id > 0) { |
@@ -303,7 +303,7 @@ discard block |
||
| 303 | 303 | } |
| 304 | 304 | } |
| 305 | 305 | |
| 306 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 306 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 307 | 307 | /** |
| 308 | 308 | * Return if a barcode value match syntax |
| 309 | 309 | * |
@@ -313,7 +313,7 @@ discard block |
||
| 313 | 313 | */ |
| 314 | 314 | public function verif_syntax($codefortest, $typefortest) |
| 315 | 315 | { |
| 316 | - // phpcs:enable |
|
| 316 | + // phpcs:enable |
|
| 317 | 317 | global $conf; |
| 318 | 318 | |
| 319 | 319 | $result = 0; |
@@ -204,7 +204,7 @@ discard block |
||
| 204 | 204 | //Begin barcode with key: for barcode with key (EAN13...) calculate and substitute the last character (* or ?) used in the mask by the key |
| 205 | 205 | if ((substr($numFinal, -1) == '*') or (substr($numFinal, -1) == '?')) { // if last mask character is * or ? a joker, probably we have to calculate a key as last character (EAN13...) |
| 206 | 206 | $literaltype = ''; |
| 207 | - $literaltype = $this->literalBarcodeType($db, $type);//get literal_Barcode_Type |
|
| 207 | + $literaltype = $this->literalBarcodeType($db, $type); //get literal_Barcode_Type |
|
| 208 | 208 | switch ($literaltype) { |
| 209 | 209 | case 'EAN13': //EAN13 rowid = 2 |
| 210 | 210 | if (strlen($numFinal) == 13) {// be sure that the mask length is correct for EAN13 |
@@ -247,7 +247,7 @@ discard block |
||
| 247 | 247 | $code = strtoupper(trim($code)); |
| 248 | 248 | |
| 249 | 249 | if (empty($code) && $this->code_null && !getDolGlobalString('BARCODE_STANDARD_THIRDPARTY_MASK')) { |
| 250 | - $result = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 250 | + $result = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 251 | 251 | } elseif (empty($code) && (!$this->code_null || getDolGlobalString('BARCODE_STANDARD_THIRDPARTY_MASK'))) { |
| 252 | 252 | $result = -2; |
| 253 | 253 | } else { |
@@ -256,7 +256,7 @@ discard block |
||
| 256 | 256 | if ($is_dispo != 0) { |
| 257 | 257 | $result = -3; |
| 258 | 258 | } else { |
| 259 | - $result = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 259 | + $result = 0; // @phan-suppress-current-line PhanPluginRedundantAssignment |
|
| 260 | 260 | } |
| 261 | 261 | } else { |
| 262 | 262 | if (dol_strlen($code) == 0) { |
@@ -39,7 +39,7 @@ discard block |
||
| 39 | 39 | */ |
| 40 | 40 | abstract class ModelePDFContract extends CommonDocGenerator |
| 41 | 41 | { |
| 42 | - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 42 | + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps |
|
| 43 | 43 | /** |
| 44 | 44 | * Return list of active generation modules |
| 45 | 45 | * |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | */ |
| 50 | 50 | public static function liste_modeles($db, $maxfilenamelength = 0) |
| 51 | 51 | { |
| 52 | - // phpcs:enable |
|
| 52 | + // phpcs:enable |
|
| 53 | 53 | $type = 'contract'; |
| 54 | 54 | $list = array(); |
| 55 | 55 | |