Passed
Push — main ( 324b47...7af4bb )
by Rafael
43:55
created
htdocs/webportal/class/webportalpropal.class.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -315,7 +315,7 @@  discard block
 block discarded – undo
315 315
         return $this->LibStatut($this->fk_statut, $mode);
316 316
     }
317 317
 
318
-	// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
318
+    // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
319 319
     /**
320 320
      * Return the label of a given status
321 321
      *
@@ -325,7 +325,7 @@  discard block
 block discarded – undo
325 325
      */
326 326
     public function LibStatut($status, $mode = 0)
327 327
     {
328
-		// phpcs:enable
328
+        // phpcs:enable
329 329
         return $this->getPropalStatic()->LibStatut($status, $mode);
330 330
     }
331 331
 }
Please login to merge, or discard this patch.
htdocs/webportal/class/webportalpartnership.class.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -350,7 +350,7 @@  discard block
 block discarded – undo
350 350
         return $this->LibStatut($this->status, $mode);
351 351
     }
352 352
 
353
-	// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
353
+    // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
354 354
 
355 355
     /**
356 356
      *  Return the status
@@ -361,7 +361,7 @@  discard block
 block discarded – undo
361 361
      */
362 362
     public function LibStatut($status, $mode = 0)
363 363
     {
364
-		// phpcs:enable
364
+        // phpcs:enable
365 365
         return $this->getPartnershipStatic()->LibStatut($status, $mode);
366 366
     }
367 367
 }
Please login to merge, or discard this patch.
htdocs/webportal/class/context.class.php 3 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -17,11 +17,11 @@
 block discarded – undo
17 17
  * along with this program. If not, see <https://www.gnu.org/licenses/>.
18 18
  */
19 19
 
20
- /**
21
- * \file       htdocs/webportal/class/context.class.php
22
- * \ingroup    webportal
23
- * \brief      File of context class for WebPortal
24
- */
20
+    /**
21
+     * \file       htdocs/webportal/class/context.class.php
22
+     * \ingroup    webportal
23
+     * \brief      File of context class for WebPortal
24
+     */
25 25
 
26 26
 require_once __DIR__ . '/controller.class.php';
27 27
 require_once __DIR__ . '/webPortalTheme.class.php';
Please login to merge, or discard this patch.
Braces   +18 added lines, -6 removed lines patch added patch discarded remove patch
@@ -365,7 +365,9 @@  discard block
 block discarded – undo
365 365
 
366 366
         // if $moreParams is an array
367 367
         if (!empty($moreParams) && is_array($moreParams)) {
368
-            if (isset($moreParams['controller'])) unset($moreParams['controller']);
368
+            if (isset($moreParams['controller'])) {
369
+                unset($moreParams['controller']);
370
+            }
369 371
             if (!empty($moreParams)) {
370 372
                 foreach ($moreParams as $paramKey => $paramVal) {
371 373
                     $Tparams[$paramKey] = $paramVal;
@@ -384,8 +386,12 @@  discard block
 block discarded – undo
384 386
         // if $moreParams is a string
385 387
         if (!empty($moreParams) && !is_array($moreParams)) {
386 388
             if (empty($Tparams)) {
387
-                if ($moreParams[0] !== '?') $url .= '?';
388
-                if ($moreParams[0] === '&') $moreParams = substr($moreParams, 1);
389
+                if ($moreParams[0] !== '?') {
390
+                    $url .= '?';
391
+                }
392
+                if ($moreParams[0] === '&') {
393
+                    $moreParams = substr($moreParams, 1);
394
+                }
389 395
             }
390 396
             $url .= $moreParams;
391 397
         }
@@ -454,10 +460,16 @@  discard block
 block discarded – undo
454 460
      */
455 461
     public function setError($errors)
456 462
     {
457
-        if (!is_array($errors)) $errors = array($errors);
458
-        if (!isset($_SESSION['webportal_errors'])) $_SESSION['webportal_errors'] = array();
463
+        if (!is_array($errors)) {
464
+            $errors = array($errors);
465
+        }
466
+        if (!isset($_SESSION['webportal_errors'])) {
467
+            $_SESSION['webportal_errors'] = array();
468
+        }
459 469
         foreach ($errors as $msg) {
460
-            if (!in_array($msg, $_SESSION['webportal_errors'])) $_SESSION['webportal_errors'][] = $msg;
470
+            if (!in_array($msg, $_SESSION['webportal_errors'])) {
471
+                $_SESSION['webportal_errors'][] = $msg;
472
+            }
461 473
         }
462 474
     }
463 475
 
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -170,7 +170,7 @@
 block discarded – undo
170 170
         $this->tplPath = realpath(__DIR__ . '/../../public/webportal/tpl');
171 171
 
172 172
         $this->controller = GETPOST('controller', 'aZ09'); // for security, limited to 'aZ09'
173
-        $this->action = GETPOST('action', 'aZ09');// for security, limited to 'aZ09'
173
+        $this->action = GETPOST('action', 'aZ09'); // for security, limited to 'aZ09'
174 174
 
175 175
         if (empty($this->controller)) {
176 176
             $this->controller = 'default';
Please login to merge, or discard this patch.
htdocs/workstation/class/workstation.class.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -781,7 +781,7 @@  discard block
 block discarded – undo
781 781
         return $this->LibStatut($this->status, $mode);
782 782
     }
783 783
 
784
-	// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
784
+    // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
785 785
     /**
786 786
      *  Return the status
787 787
      *
@@ -791,7 +791,7 @@  discard block
 block discarded – undo
791 791
      */
792 792
     public function LibStatut($status, $mode = 0)
793 793
     {
794
-		// phpcs:enable
794
+        // phpcs:enable
795 795
         if (empty($this->labelStatus) || empty($this->labelStatusShort)) {
796 796
             global $langs;
797 797
             //$langs->load("workstation");
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
         'fk_user_modif' => array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserModif', 'enabled' => 1, 'position' => 511, 'notnull' => -1, 'visible' => -2,),
114 114
         'import_key' => array('type' => 'varchar(14)', 'label' => 'ImportId', 'enabled' => 1, 'position' => 512, 'notnull' => -1, 'visible' => -2,),
115 115
         'nb_operators_required' => array('type' => 'integer', 'label' => 'NbOperatorsRequired', 'enabled' => 1, 'position' => 50, 'notnull' => 0, 'visible' => 1, 'css' => 'right', 'csslist' => 'maxwidth75imp'),
116
-        'thm_operator_estimated' => array('type' => 'double', 'help' => 'THMOperatorEstimatedHelp','label' => 'THMOperatorEstimated', 'enabled' => 1, 'position' => 50, 'notnull' => 0, 'visible' => 1, 'css' => 'right', 'csslist' => 'maxwidth75imp'),
116
+        'thm_operator_estimated' => array('type' => 'double', 'help' => 'THMOperatorEstimatedHelp', 'label' => 'THMOperatorEstimated', 'enabled' => 1, 'position' => 50, 'notnull' => 0, 'visible' => 1, 'css' => 'right', 'csslist' => 'maxwidth75imp'),
117 117
         'thm_machine_estimated' => array('type' => 'double', 'help' => 'THMMachineEstimatedHelp', 'label' => 'THMMachineEstimated', 'enabled' => 1, 'position' => 50, 'notnull' => 0, 'visible' => 1, 'css' => 'right', 'csslist' => 'maxwidth75imp'),
118 118
         'status' => array('type' => 'smallint', 'label' => 'Status', 'enabled' => 1, 'position' => 1000, 'default' => '1', 'notnull' => 1, 'visible' => 1, 'index' => 1, 'arrayofkeyval' => array('0' => 'Disabled', '1' => 'Enabled'),),
119 119
     );
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
     /**
137 137
      * @var string type
138 138
      */
139
-    public $type;   // HUMAN, MACHINE, ...
139
+    public $type; // HUMAN, MACHINE, ...
140 140
 
141 141
     /**
142 142
      * @var integer|string date_creation
Please login to merge, or discard this patch.
doctemplates/websites/website_template-corporate/containers/master.inc.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1 1
 <?php
2 2
 
3 3
 // File generated to link to the master file - DO NOT MODIFY - It is just an include
4
-if (! defined('USEDOLIBARRSERVER') && ! defined('USEDOLIBARREDITOR')) {
5
-    if (! defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
4
+if (!defined('USEDOLIBARRSERVER') && !defined('USEDOLIBARREDITOR')) {
5
+    if (!defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
6 6
     require_once '/home/ldestailleur/git/dolibarr_dev/htdocs/master.inc.php';
7 7
 }
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,6 +2,8 @@
 block discarded – undo
2 2
 
3 3
 // File generated to link to the master file - DO NOT MODIFY - It is just an include
4 4
 if (! defined('USEDOLIBARRSERVER') && ! defined('USEDOLIBARREDITOR')) {
5
-    if (! defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
5
+    if (! defined('USEEXTERNALSERVER')) {
6
+        define('USEEXTERNALSERVER', 1);
7
+    }
6 8
     require_once '/home/ldestailleur/git/dolibarr_dev/htdocs/master.inc.php';
7 9
 }
Please login to merge, or discard this patch.
doctemplates/websites/website_template-noimg/containers/master.inc.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1 1
 <?php
2 2
 
3 3
 // File generated to link to the master file - DO NOT MODIFY - It is just an include
4
-if (! defined('USEDOLIBARRSERVER') && ! defined('USEDOLIBARREDITOR')) {
5
-    if (! defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
4
+if (!defined('USEDOLIBARRSERVER') && !defined('USEDOLIBARREDITOR')) {
5
+    if (!defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
6 6
     require_once '/var/www/html/dolibarr_dev/htdocs/master.inc.php';
7 7
 }
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,6 +2,8 @@
 block discarded – undo
2 2
 
3 3
 // File generated to link to the master file - DO NOT MODIFY - It is just an include
4 4
 if (! defined('USEDOLIBARRSERVER') && ! defined('USEDOLIBARREDITOR')) {
5
-    if (! defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
5
+    if (! defined('USEEXTERNALSERVER')) {
6
+        define('USEEXTERNALSERVER', 1);
7
+    }
6 8
     require_once '/var/www/html/dolibarr_dev/htdocs/master.inc.php';
7 9
 }
Please login to merge, or discard this patch.
doctemplates/websites/website_template-restaurant/containers/master.inc.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1 1
 <?php
2 2
 
3 3
 // File generated to link to the master file - DO NOT MODIFY - It is just an include
4
-if (! defined('USEDOLIBARRSERVER') && ! defined('USEDOLIBARREDITOR')) {
5
-    if (! defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
4
+if (!defined('USEDOLIBARRSERVER') && !defined('USEDOLIBARREDITOR')) {
5
+    if (!defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
6 6
     require_once '/home/ldestailleur/git/dolibarr_dev/htdocs/master.inc.php';
7 7
 }
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,6 +2,8 @@
 block discarded – undo
2 2
 
3 3
 // File generated to link to the master file - DO NOT MODIFY - It is just an include
4 4
 if (! defined('USEDOLIBARRSERVER') && ! defined('USEDOLIBARREDITOR')) {
5
-    if (! defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
5
+    if (! defined('USEEXTERNALSERVER')) {
6
+        define('USEEXTERNALSERVER', 1);
7
+    }
6 8
     require_once '/home/ldestailleur/git/dolibarr_dev/htdocs/master.inc.php';
7 9
 }
Please login to merge, or discard this patch.
doctemplates/websites/website_template-stellar/containers/master.inc.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1 1
 <?php
2 2
 
3 3
 // File generated to link to the master file - DO NOT MODIFY - It is just an include
4
-if (! defined('USEDOLIBARRSERVER') && ! defined('USEDOLIBARREDITOR')) {
5
-    if (! defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
4
+if (!defined('USEDOLIBARRSERVER') && !defined('USEDOLIBARREDITOR')) {
5
+    if (!defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
6 6
     require_once '/home/ldestailleur/git/dolibarr_dev/htdocs/master.inc.php';
7 7
 }
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,6 +2,8 @@
 block discarded – undo
2 2
 
3 3
 // File generated to link to the master file - DO NOT MODIFY - It is just an include
4 4
 if (! defined('USEDOLIBARRSERVER') && ! defined('USEDOLIBARREDITOR')) {
5
-    if (! defined('USEEXTERNALSERVER')) define('USEEXTERNALSERVER', 1);
5
+    if (! defined('USEEXTERNALSERVER')) {
6
+        define('USEEXTERNALSERVER', 1);
7
+    }
6 8
     require_once '/home/ldestailleur/git/dolibarr_dev/htdocs/master.inc.php';
7 9
 }
Please login to merge, or discard this patch.
htdocs/mrp/class/mo.class.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1523,7 +1523,7 @@  discard block
 block discarded – undo
1523 1523
         return $this->LibStatut($this->status, $mode);
1524 1524
     }
1525 1525
 
1526
-	// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
1526
+    // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
1527 1527
     /**
1528 1528
      *  Return the status
1529 1529
      *
@@ -1533,7 +1533,7 @@  discard block
 block discarded – undo
1533 1533
      */
1534 1534
     public function LibStatut($status, $mode = 0)
1535 1535
     {
1536
-		// phpcs:enable
1536
+        // phpcs:enable
1537 1537
         if (empty($this->labelStatus)) {
1538 1538
             global $langs;
1539 1539
             //$langs->load("mrp");
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
         'import_key' => array('type' => 'varchar(14)', 'label' => 'ImportId', 'enabled' => 1, 'visible' => -2, 'position' => 1000, 'notnull' => -1,),
122 122
         'model_pdf' => array('type' => 'varchar(255)', 'label' => 'Model pdf', 'enabled' => 1, 'visible' => 0, 'position' => 1010),
123 123
         'status' => array('type' => 'integer', 'label' => 'Status', 'enabled' => 1, 'visible' => 2, 'position' => 1000, 'default' => '0', 'notnull' => 1, 'index' => 1, 'arrayofkeyval' => array('0' => 'Draft', '1' => 'Validated', '2' => 'InProgress', '3' => 'StatusMOProduced', '9' => 'Canceled')),
124
-        'fk_parent_line' => array('type' => 'integer:MoLine:mrp/class/mo.class.php', 'label' => 'ParentMo', 'enabled' => 1, 'visible' => 0, 'position' => 1020, 'default' => '0', 'notnull' => 0, 'index' => 1,'showoncombobox' => 0),
124
+        'fk_parent_line' => array('type' => 'integer:MoLine:mrp/class/mo.class.php', 'label' => 'ParentMo', 'enabled' => 1, 'visible' => 0, 'position' => 1020, 'default' => '0', 'notnull' => 0, 'index' => 1, 'showoncombobox' => 0),
125 125
     );
126 126
     public $rowid;
127 127
     public $entity;
@@ -330,7 +330,7 @@  discard block
 block discarded – undo
330 330
         }
331 331
 
332 332
         if (!$error) {
333
-            $result = $this->createProduction($user, $notrigger);   // Insert lines from BOM
333
+            $result = $this->createProduction($user, $notrigger); // Insert lines from BOM
334 334
             if ($result <= 0) {
335 335
                 $error++;
336 336
             }
@@ -909,7 +909,7 @@  discard block
 block discarded – undo
909 909
         }
910 910
         $productstatic = new Product($this->db);
911 911
 
912
-        $arrayoflines = $this->fetchLinesLinked('consumed', $idline);   // Get lines consumed under the one to delete
912
+        $arrayoflines = $this->fetchLinesLinked('consumed', $idline); // Get lines consumed under the one to delete
913 913
 
914 914
         $result = 0;
915 915
 
@@ -1796,7 +1796,7 @@  discard block
 block discarded – undo
1796 1796
         $this->tpl['disable_stock_change'] = $line->disable_stock_change;
1797 1797
         $this->tpl['efficiency'] = $line->efficiency;
1798 1798
 
1799
-        global $conf;   // used into template
1799
+        global $conf; // used into template
1800 1800
         $res = include DOL_DOCUMENT_ROOT . '/mrp/tpl/originproductline.tpl.php';
1801 1801
     }
1802 1802
 
Please login to merge, or discard this patch.