Passed
Push — master ( 0f9140...c4489d )
by Alxarafe
22:27
created
dolibarr/htdocs/home/home.php 1 patch
Spacing   +95 added lines, -95 removed lines patch added patch discarded remove patch
@@ -29,9 +29,9 @@  discard block
 block discarded – undo
29 29
  */
30 30
 define('NOCSRFCHECK', 1); // This is main home and login page. We must be able to go on it from another web site.
31 31
 
32
-require DOL_BASE_PATH . '/main.inc.php';
32
+require DOL_BASE_PATH.'/main.inc.php';
33 33
 
34
-require_once DOL_DOCUMENT_ROOT . '/core/class/html.formother.class.php';
34
+require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
35 35
 
36 36
 // If not defined, we select menu "home"
37 37
 $_GET['mainmenu'] = GETPOST('mainmenu', 'aZ09') ? GETPOST('mainmenu', 'aZ09') : 'home';
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
 // Check if company name is defined (first install)
47 47
 if (!isset($conf->global->MAIN_INFO_SOCIETE_NOM) || empty($conf->global->MAIN_INFO_SOCIETE_NOM)) {
48 48
     //header("Location: " . DOL_URL_ROOT . "/admin/index.php?mainmenu=home&leftmenu=setup&mesg=setupnotcomplete");
49
-    header('Location: ' . BASE_URI . '?controller=admin&method=index&mainmenu=home&leftmenu=setup&mesg=setupnotcomplete');
49
+    header('Location: '.BASE_URI.'?controller=admin&method=index&mainmenu=home&leftmenu=setup&mesg=setupnotcomplete');
50 50
     exit;
51 51
 }
52 52
 /*
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
   }
61 61
  */
62 62
 if (GETPOST('addbox')) { // Add box (when submit is done from a form when ajax disabled)
63
-    require_once DOL_DOCUMENT_ROOT . '/core/class/infobox.class.php';
63
+    require_once DOL_DOCUMENT_ROOT.'/core/class/infobox.class.php';
64 64
     $zone = GETPOST('areacode', 'aZ09');
65 65
     $userid = GETPOST('userid', 'int');
66 66
     $boxorder = GETPOST('boxorder', 'aZ09');
@@ -84,15 +84,15 @@  discard block
 block discarded – undo
84 84
 }
85 85
 
86 86
 // Title
87
-$title = $langs->trans("HomeArea") . ' - Dolibarr ' . DOL_VERSION;
87
+$title = $langs->trans("HomeArea").' - Dolibarr '.DOL_VERSION;
88 88
 if (!empty($conf->global->MAIN_APPLICATION_TITLE))
89 89
  {
90
-    $title = $langs->trans("HomeArea") . ' - ' . $conf->global->MAIN_APPLICATION_TITLE;
90
+    $title = $langs->trans("HomeArea").' - '.$conf->global->MAIN_APPLICATION_TITLE;
91 91
 }
92 92
 
93 93
 llxHeader('', $title);
94 94
 
95
-$resultboxes = FormOther::getBoxesArea($user, "0");    // Load $resultboxes (selectboxlist + boxactivated + boxlista + boxlistb)
95
+$resultboxes = FormOther::getBoxesArea($user, "0"); // Load $resultboxes (selectboxlist + boxactivated + boxlista + boxlistb)
96 96
 
97 97
 print load_fiche_titre($langs->trans("HomeArea"), $resultboxes['selectboxlist'], 'title_home');
98 98
 
@@ -126,16 +126,16 @@  discard block
 block discarded – undo
126 126
 
127 127
 if (empty($user->societe_id)) {
128 128
     $boxstat .= '<div class="box">';
129
-    $boxstat .= '<table summary="' . dol_escape_htmltag($langs->trans("DolibarrStateBoard")) . '" class="noborder boxtable boxtablenobottom nohover" width="100%">';
129
+    $boxstat .= '<table summary="'.dol_escape_htmltag($langs->trans("DolibarrStateBoard")).'" class="noborder boxtable boxtablenobottom nohover" width="100%">';
130 130
     $boxstat .= '<tr class="liste_titre">';
131
-    $boxstat .= '<th class="liste_titre">' . $langs->trans("DolibarrStateBoard") . '</th>';
131
+    $boxstat .= '<th class="liste_titre">'.$langs->trans("DolibarrStateBoard").'</th>';
132 132
     $boxstat .= '</tr>';
133 133
     $boxstat .= '<tr class="impair"><td class="tdboxstats nohover flexcontainer">';
134 134
 
135 135
     $object = new stdClass();
136 136
     $parameters = array();
137 137
     $action = '';
138
-    $reshook = $hookmanager->executeHooks('addStatisticLine', $parameters, $object, $action);    // Note that $action and $object may have been modified by some hooks
138
+    $reshook = $hookmanager->executeHooks('addStatisticLine', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
139 139
     $boxstat .= $hookmanager->resPrint;
140 140
 
141 141
     if (empty($reshook)) {
@@ -163,25 +163,25 @@  discard block
 block discarded – undo
163 163
         );
164 164
         // Class file containing the method load_state_board for each line
165 165
         $includes = array(
166
-            DOL_DOCUMENT_ROOT . "/user/class/user.class.php",
167
-            DOL_DOCUMENT_ROOT . "/societe/class/client.class.php",
168
-            DOL_DOCUMENT_ROOT . "/societe/class/client.class.php",
169
-            DOL_DOCUMENT_ROOT . "/fourn/class/fournisseur.class.php",
170
-            DOL_DOCUMENT_ROOT . "/contact/class/contact.class.php",
171
-            DOL_DOCUMENT_ROOT . "/adherents/class/adherent.class.php",
172
-            DOL_DOCUMENT_ROOT . "/product/class/product.class.php",
173
-            DOL_DOCUMENT_ROOT . "/product/class/product.class.php",
174
-            DOL_DOCUMENT_ROOT . "/comm/propal/class/propal.class.php",
175
-            DOL_DOCUMENT_ROOT . "/commande/class/commande.class.php",
176
-            DOL_DOCUMENT_ROOT . "/compta/facture/class/facture.class.php",
177
-            DOL_DOCUMENT_ROOT . "/contrat/class/contrat.class.php",
178
-            DOL_DOCUMENT_ROOT . "/fichinter/class/fichinter.class.php",
179
-            DOL_DOCUMENT_ROOT . "/fourn/class/fournisseur.commande.class.php",
180
-            DOL_DOCUMENT_ROOT . "/fourn/class/fournisseur.facture.class.php",
181
-            DOL_DOCUMENT_ROOT . "/supplier_proposal/class/supplier_proposal.class.php",
182
-            DOL_DOCUMENT_ROOT . "/projet/class/project.class.php",
183
-            DOL_DOCUMENT_ROOT . "/expensereport/class/expensereport.class.php",
184
-            DOL_DOCUMENT_ROOT . "/don/class/don.class.php"
166
+            DOL_DOCUMENT_ROOT."/user/class/user.class.php",
167
+            DOL_DOCUMENT_ROOT."/societe/class/client.class.php",
168
+            DOL_DOCUMENT_ROOT."/societe/class/client.class.php",
169
+            DOL_DOCUMENT_ROOT."/fourn/class/fournisseur.class.php",
170
+            DOL_DOCUMENT_ROOT."/contact/class/contact.class.php",
171
+            DOL_DOCUMENT_ROOT."/adherents/class/adherent.class.php",
172
+            DOL_DOCUMENT_ROOT."/product/class/product.class.php",
173
+            DOL_DOCUMENT_ROOT."/product/class/product.class.php",
174
+            DOL_DOCUMENT_ROOT."/comm/propal/class/propal.class.php",
175
+            DOL_DOCUMENT_ROOT."/commande/class/commande.class.php",
176
+            DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php",
177
+            DOL_DOCUMENT_ROOT."/contrat/class/contrat.class.php",
178
+            DOL_DOCUMENT_ROOT."/fichinter/class/fichinter.class.php",
179
+            DOL_DOCUMENT_ROOT."/fourn/class/fournisseur.commande.class.php",
180
+            DOL_DOCUMENT_ROOT."/fourn/class/fournisseur.facture.class.php",
181
+            DOL_DOCUMENT_ROOT."/supplier_proposal/class/supplier_proposal.class.php",
182
+            DOL_DOCUMENT_ROOT."/projet/class/project.class.php",
183
+            DOL_DOCUMENT_ROOT."/expensereport/class/expensereport.class.php",
184
+            DOL_DOCUMENT_ROOT."/don/class/don.class.php"
185 185
         );
186 186
         // Name class containing the method load_state_board for each line
187 187
         $classes = array('User',
@@ -292,25 +292,25 @@  discard block
 block discarded – undo
292 292
           );
293 293
          */
294 294
         $links = array(
295
-            BASE_URI . '/?controller=user&method=list',
296
-            BASE_URI . '/?controller=societe&method=list&type=c&mainmenu=companies',
297
-            BASE_URI . '/?controller=societe&method=list&type=p&mainmenu=companies',
298
-            BASE_URI . '/?controller=societe&method=list&type=f&mainmenu=companies',
299
-            BASE_URI . '/?controller=contact&method=list&mainmenu=companies',
300
-            BASE_URI . '/?controller=adherents&method=list&statut=1&mainmenu=members',
301
-            BASE_URI . '/?controller=product&method=list&type=0&mainmenu=products',
302
-            BASE_URI . '/?controller=product&method=list&type=1&mainmenu=products',
303
-            BASE_URI . '/?controller=comm/propal&method=list&mainmenu=commercial&leftmenu=propals',
304
-            BASE_URI . '/?controller=commande&method=list&mainmenu=commercial&leftmenu=orders',
305
-            BASE_URI . '/?controller=compta/facture&method=list&mainmenu=billing&leftmenu=customers_bills',
306
-            BASE_URI . '/?controller=contrat&method=list&mainmenu=commercial&leftmenu=contracts',
307
-            BASE_URI . '/?controller=fichinter&method=list&mainmenu=commercial&leftmenu=ficheinter',
308
-            BASE_URI . '/?controller=fourn/commande&method=list&mainmenu=commercial&leftmenu=orders_suppliers',
309
-            BASE_URI . '/?controller=fourn/facture&method=list&mainmenu=billing&leftmenu=suppliers_bills',
310
-            BASE_URI . '/?controller=supplier_proposal&method=list&mainmenu=commercial&leftmenu=',
311
-            BASE_URI . '/?controller=projet&method=list&mainmenu=project',
312
-            BASE_URI . '/?controller=expensereport&method=list&mainmenu=hrm&leftmenu=expensereport',
313
-            BASE_URI . '/?controller=don&method=list&leftmenu=donations'
295
+            BASE_URI.'/?controller=user&method=list',
296
+            BASE_URI.'/?controller=societe&method=list&type=c&mainmenu=companies',
297
+            BASE_URI.'/?controller=societe&method=list&type=p&mainmenu=companies',
298
+            BASE_URI.'/?controller=societe&method=list&type=f&mainmenu=companies',
299
+            BASE_URI.'/?controller=contact&method=list&mainmenu=companies',
300
+            BASE_URI.'/?controller=adherents&method=list&statut=1&mainmenu=members',
301
+            BASE_URI.'/?controller=product&method=list&type=0&mainmenu=products',
302
+            BASE_URI.'/?controller=product&method=list&type=1&mainmenu=products',
303
+            BASE_URI.'/?controller=comm/propal&method=list&mainmenu=commercial&leftmenu=propals',
304
+            BASE_URI.'/?controller=commande&method=list&mainmenu=commercial&leftmenu=orders',
305
+            BASE_URI.'/?controller=compta/facture&method=list&mainmenu=billing&leftmenu=customers_bills',
306
+            BASE_URI.'/?controller=contrat&method=list&mainmenu=commercial&leftmenu=contracts',
307
+            BASE_URI.'/?controller=fichinter&method=list&mainmenu=commercial&leftmenu=ficheinter',
308
+            BASE_URI.'/?controller=fourn/commande&method=list&mainmenu=commercial&leftmenu=orders_suppliers',
309
+            BASE_URI.'/?controller=fourn/facture&method=list&mainmenu=billing&leftmenu=suppliers_bills',
310
+            BASE_URI.'/?controller=supplier_proposal&method=list&mainmenu=commercial&leftmenu=',
311
+            BASE_URI.'/?controller=projet&method=list&mainmenu=project',
312
+            BASE_URI.'/?controller=expensereport&method=list&mainmenu=hrm&leftmenu=expensereport',
313
+            BASE_URI.'/?controller=don&method=list&leftmenu=donations'
314 314
         );
315 315
         // Translation lang files
316 316
         $langfile = array("users",
@@ -355,10 +355,10 @@  discard block
 block discarded – undo
355 355
                     $langs->load($langfile[$key]);
356 356
                 $text = $langs->trans($titres[$key]);
357 357
                 //$sep=($conf->dol_use_jmobile?'<br>':' ');
358
-                $boxstat .= '<a href="' . $links[$key] . '" class="boxstatsindicator thumbstat nobold nounderline">';
358
+                $boxstat .= '<a href="'.$links[$key].'" class="boxstatsindicator thumbstat nobold nounderline">';
359 359
                 $boxstat .= '<div class="boxstats">';
360
-                $boxstat .= '<span class="boxstatstext" title="' . dol_escape_htmltag($text) . '">' . $text . '</span><br>';
361
-                $boxstat .= '<span class="boxstatsindicator">' . img_object("", $icons[$key], 'class="inline-block"') . ' ' . ($board->nb[$val] ? $board->nb[$val] : 0) . '</span>';
360
+                $boxstat .= '<span class="boxstatstext" title="'.dol_escape_htmltag($text).'">'.$text.'</span><br>';
361
+                $boxstat .= '<span class="boxstatsindicator">'.img_object("", $icons[$key], 'class="inline-block"').' '.($board->nb[$val] ? $board->nb[$val] : 0).'</span>';
362 362
                 $boxstat .= '</div>';
363 363
                 $boxstat .= '</a>';
364 364
             }
@@ -392,11 +392,11 @@  discard block
 block discarded – undo
392 392
 $dashboardlines = array();
393 393
 
394 394
 // Do not include sections without management permission
395
-require_once DOL_DOCUMENT_ROOT . '/core/class/workboardresponse.class.php';
395
+require_once DOL_DOCUMENT_ROOT.'/core/class/workboardresponse.class.php';
396 396
 
397 397
 // Number of actions to do (late)
398 398
 if (!empty($conf->agenda->enabled) && $user->rights->agenda->myactions->read) {
399
-    include_once DOL_DOCUMENT_ROOT . '/comm/action/class/actioncomm.class.php';
399
+    include_once DOL_DOCUMENT_ROOT.'/comm/action/class/actioncomm.class.php';
400 400
     $board = new ActionComm($db);
401 401
 
402 402
     $dashboardlines[] = $board->load_board($user);
@@ -404,21 +404,21 @@  discard block
 block discarded – undo
404 404
 
405 405
 // Number of project opened
406 406
 if (!empty($conf->projet->enabled) && $user->rights->projet->lire) {
407
-    include_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php';
407
+    include_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
408 408
     $board = new Project($db);
409 409
     $dashboardlines[] = $board->load_board($user);
410 410
 }
411 411
 
412 412
 // Number of tasks to do (late)
413 413
 if (!empty($conf->projet->enabled) && empty($conf->global->PROJECT_HIDE_TASKS) && $user->rights->projet->lire) {
414
-    include_once DOL_DOCUMENT_ROOT . '/projet/class/task.class.php';
414
+    include_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
415 415
     $board = new Task($db);
416 416
     $dashboardlines[] = $board->load_board($user);
417 417
 }
418 418
 
419 419
 // Number of commercial proposals opened (expired)
420 420
 if (!empty($conf->propal->enabled) && $user->rights->propale->lire) {
421
-    include_once DOL_DOCUMENT_ROOT . '/comm/propal/class/propal.class.php';
421
+    include_once DOL_DOCUMENT_ROOT.'/comm/propal/class/propal.class.php';
422 422
     $board = new Propal($db);
423 423
     $dashboardlines[] = $board->load_board($user, "opened");
424 424
     // Number of commercial proposals CLOSED signed (billed)
@@ -427,7 +427,7 @@  discard block
 block discarded – undo
427 427
 
428 428
 // Number of commercial proposals opened (expired)
429 429
 if (!empty($conf->supplier_proposal->enabled) && $user->rights->supplier_proposal->lire) {
430
-    include_once DOL_DOCUMENT_ROOT . '/supplier_proposal/class/supplier_proposal.class.php';
430
+    include_once DOL_DOCUMENT_ROOT.'/supplier_proposal/class/supplier_proposal.class.php';
431 431
     $board = new SupplierProposal($db);
432 432
     $dashboardlines[] = $board->load_board($user, "opened");
433 433
     // Number of commercial proposals CLOSED signed (billed)
@@ -436,21 +436,21 @@  discard block
 block discarded – undo
436 436
 
437 437
 // Number of customer orders a deal
438 438
 if (!empty($conf->commande->enabled) && $user->rights->commande->lire) {
439
-    include_once DOL_DOCUMENT_ROOT . '/commande/class/commande.class.php';
439
+    include_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php';
440 440
     $board = new Commande($db);
441 441
     $dashboardlines[] = $board->load_board($user);
442 442
 }
443 443
 
444 444
 // Number of suppliers orders a deal
445 445
 if (!empty($conf->supplier_order->enabled) && $user->rights->fournisseur->commande->lire) {
446
-    include_once DOL_DOCUMENT_ROOT . '/fourn/class/fournisseur.commande.class.php';
446
+    include_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.commande.class.php';
447 447
     $board = new CommandeFournisseur($db);
448 448
     $dashboardlines[] = $board->load_board($user);
449 449
 }
450 450
 
451 451
 // Number of services enabled (delayed)
452 452
 if (!empty($conf->contrat->enabled) && $user->rights->contrat->lire) {
453
-    include_once DOL_DOCUMENT_ROOT . '/contrat/class/contrat.class.php';
453
+    include_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php';
454 454
     $board = new Contrat($db);
455 455
     $dashboardlines[] = $board->load_board($user, "inactives");
456 456
     // Number of active services (expired)
@@ -458,23 +458,23 @@  discard block
 block discarded – undo
458 458
 }
459 459
 // Number of invoices customers (has paid)
460 460
 if (!empty($conf->facture->enabled) && $user->rights->facture->lire) {
461
-    include_once DOL_DOCUMENT_ROOT . '/compta/facture/class/facture.class.php';
461
+    include_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
462 462
     $board = new Facture($db);
463 463
     $dashboardlines[] = $board->load_board($user);
464 464
 }
465 465
 
466 466
 // Number of supplier invoices (has paid)
467 467
 if (!empty($conf->supplier_invoice->enabled) && !empty($user->rights->fournisseur->facture->lire)) {
468
-    include_once DOL_DOCUMENT_ROOT . '/fourn/class/fournisseur.facture.class.php';
468
+    include_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php';
469 469
     $board = new FactureFournisseur($db);
470 470
     $dashboardlines[] = $board->load_board($user);
471 471
 }
472 472
 
473 473
 // Number of transactions to conciliate
474 474
 if (!empty($conf->banque->enabled) && $user->rights->banque->lire && !$user->societe_id) {
475
-    include_once DOL_DOCUMENT_ROOT . '/compta/bank/class/account.class.php';
475
+    include_once DOL_DOCUMENT_ROOT.'/compta/bank/class/account.class.php';
476 476
     $board = new Account($db);
477
-    $nb = $board::countAccountToReconcile();    // Get nb of account to reconciliate
477
+    $nb = $board::countAccountToReconcile(); // Get nb of account to reconciliate
478 478
     if ($nb > 0) {
479 479
         $dashboardlines[] = $board->load_board($user);
480 480
     }
@@ -482,28 +482,28 @@  discard block
 block discarded – undo
482 482
 
483 483
 // Number of cheque to send
484 484
 if (!empty($conf->banque->enabled) && $user->rights->banque->lire && !$user->societe_id && empty($conf->global->BANK_DISABLE_CHECK_DEPOSIT)) {
485
-    include_once DOL_DOCUMENT_ROOT . '/compta/paiement/cheque/class/remisecheque.class.php';
485
+    include_once DOL_DOCUMENT_ROOT.'/compta/paiement/cheque/class/remisecheque.class.php';
486 486
     $board = new RemiseCheque($db);
487 487
     $dashboardlines[] = $board->load_board($user);
488 488
 }
489 489
 
490 490
 // Number of foundation members
491 491
 if (!empty($conf->adherent->enabled) && $user->rights->adherent->lire && !$user->societe_id) {
492
-    include_once DOL_DOCUMENT_ROOT . '/adherents/class/adherent.class.php';
492
+    include_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php';
493 493
     $board = new Adherent($db);
494 494
     $dashboardlines[] = $board->load_board($user);
495 495
 }
496 496
 
497 497
 // Number of expense reports to approve
498 498
 if (!empty($conf->expensereport->enabled) && $user->rights->expensereport->approve) {
499
-    include_once DOL_DOCUMENT_ROOT . '/expensereport/class/expensereport.class.php';
499
+    include_once DOL_DOCUMENT_ROOT.'/expensereport/class/expensereport.class.php';
500 500
     $board = new ExpenseReport($db);
501 501
     $dashboardlines[] = $board->load_board($user, 'toapprove');
502 502
 }
503 503
 
504 504
 // Number of expense reports to pay
505 505
 if (!empty($conf->expensereport->enabled) && $user->rights->expensereport->to_paid) {
506
-    include_once DOL_DOCUMENT_ROOT . '/expensereport/class/expensereport.class.php';
506
+    include_once DOL_DOCUMENT_ROOT.'/expensereport/class/expensereport.class.php';
507 507
     $board = new ExpenseReport($db);
508 508
     $dashboardlines[] = $board->load_board($user, 'topay');
509 509
 }
@@ -511,7 +511,7 @@  discard block
 block discarded – undo
511 511
 $object = new stdClass();
512 512
 $parameters = array();
513 513
 $action = '';
514
-$reshook = $hookmanager->executeHooks('addOpenElementsDashboardLine', $parameters, $object, $action);    // Note that $action and $object may have been modified by some hooks
514
+$reshook = $hookmanager->executeHooks('addOpenElementsDashboardLine', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
515 515
 if ($reshook == 0) {
516 516
     $dashboardlines = array_merge($dashboardlines, $hookmanager->resArray);
517 517
 }
@@ -541,22 +541,22 @@  discard block
 block discarded – undo
541 541
 //var_dump($totallate);
542 542
 $boxwork = '';
543 543
 $boxwork .= '<div class="box">';
544
-$boxwork .= '<table summary="' . dol_escape_htmltag($langs->trans("WorkingBoard")) . '" class="noborder boxtable boxtablenobottom boxworkingboard" width="100%">' . "\n";
544
+$boxwork .= '<table summary="'.dol_escape_htmltag($langs->trans("WorkingBoard")).'" class="noborder boxtable boxtablenobottom boxworkingboard" width="100%">'."\n";
545 545
 $boxwork .= '<tr class="liste_titre">';
546
-$boxwork .= '<th class="liste_titre">' . $langs->trans("DolibarrWorkBoard") . '</th>';
547
-$boxwork .= '</tr>' . "\n";
546
+$boxwork .= '<th class="liste_titre">'.$langs->trans("DolibarrWorkBoard").'</th>';
547
+$boxwork .= '</tr>'."\n";
548 548
 
549 549
 if ($showweather) {
550 550
     $boxwork .= '<tr class="nohover">';
551
-    $boxwork .= '<td class="nohover' . ($conf->global->MAIN_DISABLE_METEO == 2 ? ' hideonsmartphone' : '') . ' center valignmiddle">';
551
+    $boxwork .= '<td class="nohover'.($conf->global->MAIN_DISABLE_METEO == 2 ? ' hideonsmartphone' : '').' center valignmiddle">';
552 552
     $text = '';
553 553
     if ($totallate > 0)
554 554
     {
555
-        $text = $langs->transnoentitiesnoconv("WarningYouHaveAtLeastOneTaskLate") . ' (' . $langs->transnoentitiesnoconv("NActionsLate", $totallate . (!empty($conf->global->MAIN_USE_METEO_WITH_PERCENTAGE) ? '%' : '')) . ')';
555
+        $text = $langs->transnoentitiesnoconv("WarningYouHaveAtLeastOneTaskLate").' ('.$langs->transnoentitiesnoconv("NActionsLate", $totallate.(!empty($conf->global->MAIN_USE_METEO_WITH_PERCENTAGE) ? '%' : '')).')';
556 556
     } else {
557 557
         $text = $langs->transnoentitiesnoconv("NoItemLate");
558 558
     }
559
-    $text .= '. ' . $langs->transnoentitiesnoconv("LateDesc");
559
+    $text .= '. '.$langs->transnoentitiesnoconv("LateDesc");
560 560
     //$text.=$form->textwithpicto('',$langs->trans("LateDesc"));
561 561
     $options = 'height="64px"';
562 562
     $boxwork .= showWeather($totallate, $text, $options);
@@ -576,23 +576,23 @@  discard block
 block discarded – undo
576 576
         }
577 577
 
578 578
         $textlate = $langs->trans("NActionsLate", $board->nbtodolate);
579
-        $textlate .= ' (' . $langs->trans("Late") . ' = ' . $langs->trans("DateReference") . ' > ' . $langs->trans("DateToday") . ' ' . (ceil($board->warning_delay) >= 0 ? '+' : '') . ceil($board->warning_delay) . ' ' . $langs->trans("days") . ')';
579
+        $textlate .= ' ('.$langs->trans("Late").' = '.$langs->trans("DateReference").' > '.$langs->trans("DateToday").' '.(ceil($board->warning_delay) >= 0 ? '+' : '').ceil($board->warning_delay).' '.$langs->trans("days").')';
580 580
 
581 581
         $boxwork .= '<div class="boxstatsindicator thumbstat150 nobold nounderline"><div class="boxstats130 boxstatsborder">';
582 582
         $boxwork .= '<div class="boxstatscontent">';
583 583
         $sep = ($conf->dol_use_jmobile ? '<br>' : ' ');
584
-        $boxwork .= '<span class="boxstatstext" title="' . dol_escape_htmltag($board->label) . '">' . $board->img . ' ' . $board->label . '</span><br>';
585
-        $boxwork .= '<a class="valignmiddle dashboardlineindicator" href="' . $board->url . '"><span class="dashboardlineindicator' . (($board->nbtodo == 0) ? ' dashboardlineok' : '') . '">' . $board->nbtodo . '</span></a>';
584
+        $boxwork .= '<span class="boxstatstext" title="'.dol_escape_htmltag($board->label).'">'.$board->img.' '.$board->label.'</span><br>';
585
+        $boxwork .= '<a class="valignmiddle dashboardlineindicator" href="'.$board->url.'"><span class="dashboardlineindicator'.(($board->nbtodo == 0) ? ' dashboardlineok' : '').'">'.$board->nbtodo.'</span></a>';
586 586
         if ($board->total > 0 && !empty($conf->global->MAIN_WORKBOARD_SHOW_TOTAL_WO_TAX)) {
587
-            $boxwork .= '&nbsp;/&nbsp;<a class="valignmiddle dashboardlineindicator" href="' . $board->url . '"><span class="dashboardlineindicator' . (($board->nbtodo == 0) ? ' dashboardlineok' : '') . '">' . price($board->total) . '</span></a>';
587
+            $boxwork .= '&nbsp;/&nbsp;<a class="valignmiddle dashboardlineindicator" href="'.$board->url.'"><span class="dashboardlineindicator'.(($board->nbtodo == 0) ? ' dashboardlineok' : '').'">'.price($board->total).'</span></a>';
588 588
         }
589 589
         $boxwork .= '</div>';
590 590
         if ($board->nbtodolate > 0) {
591 591
             $boxwork .= '<div class="dashboardlinelatecoin nowrap">';
592
-            $boxwork .= '<a title="' . dol_escape_htmltag($textlate) . '" class="valignmiddle dashboardlineindicatorlate' . ($board->nbtodolate > 0 ? ' dashboardlineko' : ' dashboardlineok') . '" href="' . ((!$board->url_late) ? $board->url : $board->url_late ) . '">';
592
+            $boxwork .= '<a title="'.dol_escape_htmltag($textlate).'" class="valignmiddle dashboardlineindicatorlate'.($board->nbtodolate > 0 ? ' dashboardlineko' : ' dashboardlineok').'" href="'.((!$board->url_late) ? $board->url : $board->url_late).'">';
593 593
             //$boxwork .= img_picto($textlate, "warning_white", 'class="valigntextbottom"').'';
594
-            $boxwork .= img_picto($textlate, "warning_white", 'class="inline-block hideonsmartphone valigntextbottom"') . '';
595
-            $boxwork .= '<span class="dashboardlineindicatorlate' . ($board->nbtodolate > 0 ? ' dashboardlineko' : ' dashboardlineok') . '">';
594
+            $boxwork .= img_picto($textlate, "warning_white", 'class="inline-block hideonsmartphone valigntextbottom"').'';
595
+            $boxwork .= '<span class="dashboardlineindicatorlate'.($board->nbtodolate > 0 ? ' dashboardlineko' : ' dashboardlineok').'">';
596 596
             $boxwork .= $board->nbtodolate;
597 597
             $boxwork .= '</span>';
598 598
             $boxwork .= '</a>';
@@ -621,7 +621,7 @@  discard block
 block discarded – undo
621 621
 
622 622
 $boxwork .= '</td></tr>';
623 623
 
624
-$boxwork .= '</table>';   // End table array of working board
624
+$boxwork .= '</table>'; // End table array of working board
625 625
 $boxwork .= '</div>';
626 626
 
627 627
 print '</div></div></div><div class="clearboth"></div>';
@@ -667,11 +667,11 @@  discard block
 block discarded – undo
667 667
     $message = '';
668 668
 
669 669
     // Check if install lock file is present
670
-    $lockfile = DOL_DATA_ROOT . '/install.lock';
671
-    if (!empty($lockfile) && !file_exists($lockfile) && is_dir(DOL_DOCUMENT_ROOT . "/install")) {
670
+    $lockfile = DOL_DATA_ROOT.'/install.lock';
671
+    if (!empty($lockfile) && !file_exists($lockfile) && is_dir(DOL_DOCUMENT_ROOT."/install")) {
672 672
         $langs->load("errors");
673 673
         //if (! empty($message)) $message.='<br>';
674
-        $message .= info_admin($langs->trans("WarningLockFileDoesNotExists", DOL_DATA_ROOT) . ' ' . $langs->trans("WarningUntilDirRemoved", DOL_DOCUMENT_ROOT . "/install"), 0, 0, '1', 'clearboth');
674
+        $message .= info_admin($langs->trans("WarningLockFileDoesNotExists", DOL_DATA_ROOT).' '.$langs->trans("WarningUntilDirRemoved", DOL_DOCUMENT_ROOT."/install"), 0, 0, '1', 'clearboth');
675 675
     }
676 676
 
677 677
     // Conf files must be in read only mode
@@ -679,7 +679,7 @@  discard block
 block discarded – undo
679 679
         $langs->load("errors");
680 680
         //$langs->load("other");
681 681
         //if (! empty($message)) $message.='<br>';
682
-        $message .= info_admin($langs->transnoentities("WarningConfFileMustBeReadOnly") . ' ' . $langs->trans("WarningUntilDirRemoved", DOL_DOCUMENT_ROOT . "/install"), 0, 0, '1', 'clearboth');
682
+        $message .= info_admin($langs->transnoentities("WarningConfFileMustBeReadOnly").' '.$langs->trans("WarningUntilDirRemoved", DOL_DOCUMENT_ROOT."/install"), 0, 0, '1', 'clearboth');
683 683
     }
684 684
 
685 685
     if ($message) {
@@ -714,20 +714,20 @@  discard block
 block discarded – undo
714 714
     $used_conf = !empty($conf->global->MAIN_USE_METEO_WITH_PERCENTAGE) ? 'MAIN_METEO_PERCENTAGE_LEVEL' : 'MAIN_METEO_LEVEL';
715 715
 
716 716
     $level0 = $offset;
717
-    if (!empty($conf->global->{$used_conf . '0'})) {
718
-        $level0 = $conf->global->{$used_conf . '0'};
717
+    if (!empty($conf->global->{$used_conf.'0'})) {
718
+        $level0 = $conf->global->{$used_conf.'0'};
719 719
     }
720 720
     $level1 = $offset + 1 * $factor;
721
-    if (!empty($conf->global->{$used_conf . '1'})) {
722
-        $level1 = $conf->global->{$used_conf . '1'};
721
+    if (!empty($conf->global->{$used_conf.'1'})) {
722
+        $level1 = $conf->global->{$used_conf.'1'};
723 723
     }
724 724
     $level2 = $offset + 2 * $factor;
725
-    if (!empty($conf->global->{$used_conf . '2'})) {
726
-        $level2 = $conf->global->{$used_conf . '2'};
725
+    if (!empty($conf->global->{$used_conf.'2'})) {
726
+        $level2 = $conf->global->{$used_conf.'2'};
727 727
     }
728 728
     $level3 = $offset + 3 * $factor;
729
-    if (!empty($conf->global->{$used_conf . '3'})) {
730
-        $level3 = $conf->global->{$used_conf . '3'};
729
+    if (!empty($conf->global->{$used_conf.'3'})) {
730
+        $level3 = $conf->global->{$used_conf.'3'};
731 731
     }
732 732
 
733 733
     if ($totallate <= $level0)
Please login to merge, or discard this patch.
Helpers/AlixarDispatcher.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
         parent::__construct();
16 16
 
17 17
         $this->searchDir['Alixar'] = constant('BASE_PATH');
18
-        $this->searchDir['Plugins'] = constant('BASE_PATH') . '/plugins';
18
+        $this->searchDir['Plugins'] = constant('BASE_PATH').'/plugins';
19 19
 
20 20
         $this->path = null;
21 21
 
@@ -35,8 +35,8 @@  discard block
 block discarded – undo
35 35
          * Copyright (C) 2018 Alxarafe <[email protected]>
36 36
          */
37 37
 
38
-        define('DOL_BASE_PATH', BASE_PATH . '/dolibarr/htdocs');
39
-        define('DOL_BASE_URI', BASE_URI . '/dolibarr/htdocs');
38
+        define('DOL_BASE_PATH', BASE_PATH.'/dolibarr/htdocs');
39
+        define('DOL_BASE_URI', BASE_URI.'/dolibarr/htdocs');
40 40
         define('DOL_DOCUMENT_ROOT', DOL_BASE_PATH);
41 41
 
42 42
         define('CORE_FOLDER', '/core');
@@ -50,15 +50,15 @@  discard block
 block discarded – undo
50 50
         define('CACHE_FOLDER', '/../cache');
51 51
         //define('VENDOR_FOLDER', BASE_URI . '/vendor');
52 52
 
53
-        define('CORE_PATH', BASE_PATH . CORE_FOLDER);
54
-        define('CONFIG_PATH', BASE_PATH . CONFIG_FOLDER);
55
-        define('CONTROLLERS_PATH', BASE_PATH . CONTROLLERS_FOLDER);
56
-        define('HELPERS_PATH', BASE_PATH . HELPERS_FOLDER);
57
-        define('MODELS_PATH', BASE_PATH . MODELS_FOLDER);
58
-        define('SKINS_PATH', BASE_PATH . SKINS_FOLDER);
59
-        define('TEMPLATES_PATH', BASE_PATH . TEMPLATES_FOLDER);
60
-        define('PLUGINS_PATH', BASE_PATH . PLUGINS_FOLDER);
61
-        define('CACHE_PATH', BASE_PATH . CACHE_FOLDER);
53
+        define('CORE_PATH', BASE_PATH.CORE_FOLDER);
54
+        define('CONFIG_PATH', BASE_PATH.CONFIG_FOLDER);
55
+        define('CONTROLLERS_PATH', BASE_PATH.CONTROLLERS_FOLDER);
56
+        define('HELPERS_PATH', BASE_PATH.HELPERS_FOLDER);
57
+        define('MODELS_PATH', BASE_PATH.MODELS_FOLDER);
58
+        define('SKINS_PATH', BASE_PATH.SKINS_FOLDER);
59
+        define('TEMPLATES_PATH', BASE_PATH.TEMPLATES_FOLDER);
60
+        define('PLUGINS_PATH', BASE_PATH.PLUGINS_FOLDER);
61
+        define('CACHE_PATH', BASE_PATH.CACHE_FOLDER);
62 62
         //define('VENDOR_PATH', BASE_PATH . VENDOR_FOLDER);
63 63
 
64 64
         /**
Please login to merge, or discard this patch.