@@ -427,9 +427,9 @@ discard block |
||
| 427 | 427 | $this->product_custom_code = $objp->customcode; |
| 428 | 428 | $this->product_custom_country_id = $objp->country_id; |
| 429 | 429 | $this->product_custom_country_code = $objp->country_code; |
| 430 | - $this->fk_unit = $objp->fk_unit; |
|
| 430 | + $this->fk_unit = $objp->fk_unit; |
|
| 431 | 431 | |
| 432 | - $this->packaging = $objp->packaging; |
|
| 432 | + $this->packaging = $objp->packaging; |
|
| 433 | 433 | |
| 434 | 434 | $this->date_start = $this->db->jdate($objp->date_start); |
| 435 | 435 | $this->date_end = $this->db->jdate($objp->date_end); |
@@ -655,7 +655,7 @@ discard block |
||
| 655 | 655 | // End call triggers |
| 656 | 656 | |
| 657 | 657 | if (!$error) { |
| 658 | - $sql = "DELETE FROM " . MAIN_DB_PREFIX . "propaldet WHERE rowid = " . ((int) $this->rowid); |
|
| 658 | + $sql = "DELETE FROM ".MAIN_DB_PREFIX."propaldet WHERE rowid = ".((int) $this->rowid); |
|
| 659 | 659 | dol_syslog("PropaleLigne::delete", LOG_DEBUG); |
| 660 | 660 | if ($this->db->query($sql)) { |
| 661 | 661 | // Remove extrafields |
@@ -663,10 +663,10 @@ discard block |
||
| 663 | 663 | $result = $this->deleteExtraFields(); |
| 664 | 664 | if ($result < 0) { |
| 665 | 665 | $error++; |
| 666 | - dol_syslog(get_class($this) . "::delete error -4 " . $this->error, LOG_ERR); |
|
| 666 | + dol_syslog(get_class($this)."::delete error -4 ".$this->error, LOG_ERR); |
|
| 667 | 667 | } |
| 668 | 668 | } else { |
| 669 | - $this->error = $this->db->error() . " sql=" . $sql; |
|
| 669 | + $this->error = $this->db->error()." sql=".$sql; |
|
| 670 | 670 | $error++; |
| 671 | 671 | } |
| 672 | 672 | } |
@@ -37,7 +37,7 @@ discard block |
||
| 37 | 37 | */ |
| 38 | 38 | |
| 39 | 39 | require_once DOL_DOCUMENT_ROOT.'/core/class/commonobjectline.class.php'; |
| 40 | -require_once DOL_DOCUMENT_ROOT.'/core/class/commonorder.class.php'; // Because the CommonOrderLine is still in commonorder.class.php file |
|
| 40 | +require_once DOL_DOCUMENT_ROOT.'/core/class/commonorder.class.php'; // Because the CommonOrderLine is still in commonorder.class.php file |
|
| 41 | 41 | require_once DOL_DOCUMENT_ROOT.'/margin/lib/margins.lib.php'; |
| 42 | 42 | |
| 43 | 43 | |
@@ -223,7 +223,7 @@ discard block |
||
| 223 | 223 | $objp = $this->db->fetch_object($result); |
| 224 | 224 | |
| 225 | 225 | if (!$objp) { |
| 226 | - $this->error = 'OrderLine with id '. $rowid .' not found sql='.$sql; |
|
| 226 | + $this->error = 'OrderLine with id '.$rowid.' not found sql='.$sql; |
|
| 227 | 227 | return 0; |
| 228 | 228 | } |
| 229 | 229 | |
@@ -272,7 +272,7 @@ discard block |
||
| 272 | 272 | $this->product_custom_country_id = $objp->country_id; |
| 273 | 273 | $this->product_custom_country_code = $objp->country_code; |
| 274 | 274 | $this->fk_unit = $objp->fk_unit; |
| 275 | - $this->packaging = $objp->packaging; |
|
| 275 | + $this->packaging = $objp->packaging; |
|
| 276 | 276 | |
| 277 | 277 | $this->date_start = $this->db->jdate($objp->date_start); |
| 278 | 278 | $this->date_end = $this->db->jdate($objp->date_end); |
@@ -317,8 +317,8 @@ discard block |
||
| 317 | 317 | // check if order line is not in a shipment line before deleting |
| 318 | 318 | $sqlCheckShipmentLine = "SELECT"; |
| 319 | 319 | $sqlCheckShipmentLine .= " ed.rowid"; |
| 320 | - $sqlCheckShipmentLine .= " FROM " . MAIN_DB_PREFIX . "expeditiondet ed"; |
|
| 321 | - $sqlCheckShipmentLine .= " WHERE ed.fk_elementdet = " . ((int) $this->id); |
|
| 320 | + $sqlCheckShipmentLine .= " FROM ".MAIN_DB_PREFIX."expeditiondet ed"; |
|
| 321 | + $sqlCheckShipmentLine .= " WHERE ed.fk_elementdet = ".((int) $this->id); |
|
| 322 | 322 | |
| 323 | 323 | $resqlCheckShipmentLine = $this->db->query($sqlCheckShipmentLine); |
| 324 | 324 | if (!$resqlCheckShipmentLine) { |
@@ -331,13 +331,13 @@ discard block |
||
| 331 | 331 | if ($num > 0) { |
| 332 | 332 | $error++; |
| 333 | 333 | $objCheckShipmentLine = $this->db->fetch_object($resqlCheckShipmentLine); |
| 334 | - $this->error = $langs->trans('ErrorRecordAlreadyExists') . ' : ' . $langs->trans('ShipmentLine') . ' ' . $objCheckShipmentLine->rowid; |
|
| 334 | + $this->error = $langs->trans('ErrorRecordAlreadyExists').' : '.$langs->trans('ShipmentLine').' '.$objCheckShipmentLine->rowid; |
|
| 335 | 335 | $this->errors[] = $this->error; |
| 336 | 336 | } |
| 337 | 337 | $this->db->free($resqlCheckShipmentLine); |
| 338 | 338 | } |
| 339 | 339 | if ($error) { |
| 340 | - dol_syslog(__METHOD__ . 'Error ; ' . $this->error, LOG_ERR); |
|
| 340 | + dol_syslog(__METHOD__.'Error ; '.$this->error, LOG_ERR); |
|
| 341 | 341 | return -1; |
| 342 | 342 | } |
| 343 | 343 | |
@@ -353,7 +353,7 @@ discard block |
||
| 353 | 353 | } |
| 354 | 354 | |
| 355 | 355 | if (!$error) { |
| 356 | - $sql = 'DELETE FROM ' . MAIN_DB_PREFIX . "commandedet WHERE rowid = " . ((int) $this->id); |
|
| 356 | + $sql = 'DELETE FROM '.MAIN_DB_PREFIX."commandedet WHERE rowid = ".((int) $this->id); |
|
| 357 | 357 | |
| 358 | 358 | dol_syslog("OrderLine::delete", LOG_DEBUG); |
| 359 | 359 | $resql = $this->db->query($sql); |
@@ -368,7 +368,7 @@ discard block |
||
| 368 | 368 | $result = $this->deleteExtraFields(); |
| 369 | 369 | if ($result < 0) { |
| 370 | 370 | $error++; |
| 371 | - dol_syslog(get_class($this) . "::delete error -4 " . $this->error, LOG_ERR); |
|
| 371 | + dol_syslog(get_class($this)."::delete error -4 ".$this->error, LOG_ERR); |
|
| 372 | 372 | } |
| 373 | 373 | } |
| 374 | 374 | |
@@ -378,8 +378,8 @@ discard block |
||
| 378 | 378 | } |
| 379 | 379 | |
| 380 | 380 | foreach ($this->errors as $errmsg) { |
| 381 | - dol_syslog(get_class($this) . "::delete " . $errmsg, LOG_ERR); |
|
| 382 | - $this->error .= ($this->error ? ', ' . $errmsg : $errmsg); |
|
| 381 | + dol_syslog(get_class($this)."::delete ".$errmsg, LOG_ERR); |
|
| 382 | + $this->error .= ($this->error ? ', '.$errmsg : $errmsg); |
|
| 383 | 383 | } |
| 384 | 384 | $this->db->rollback(); |
| 385 | 385 | return -1 * $error; |
@@ -269,7 +269,7 @@ discard block |
||
| 269 | 269 | } |
| 270 | 270 | } |
| 271 | 271 | |
| 272 | - dolibarr_install_syslog('step5: DATABASE_PWD_ENCRYPTED = ' . getDolGlobalString('DATABASE_PWD_ENCRYPTED').' MAIN_SECURITY_HASH_ALGO = ' . getDolGlobalString('MAIN_SECURITY_HASH_ALGO'), LOG_INFO); |
|
| 272 | + dolibarr_install_syslog('step5: DATABASE_PWD_ENCRYPTED = '.getDolGlobalString('DATABASE_PWD_ENCRYPTED').' MAIN_SECURITY_HASH_ALGO = '.getDolGlobalString('MAIN_SECURITY_HASH_ALGO'), LOG_INFO); |
|
| 273 | 273 | } |
| 274 | 274 | |
| 275 | 275 | // Create user used to create the admin user |
@@ -286,8 +286,8 @@ discard block |
||
| 286 | 286 | $newuser->admin = 1; |
| 287 | 287 | $newuser->entity = 0; |
| 288 | 288 | |
| 289 | - $conf->global->USER_MAIL_REQUIRED = 0; // Force global option to be sure to create a new user with no email |
|
| 290 | - $conf->global->USER_PASSWORD_GENERATED = ''; // To not use any rule for password validation |
|
| 289 | + $conf->global->USER_MAIL_REQUIRED = 0; // Force global option to be sure to create a new user with no email |
|
| 290 | + $conf->global->USER_PASSWORD_GENERATED = ''; // To not use any rule for password validation |
|
| 291 | 291 | |
| 292 | 292 | $result = $newuser->create($createuser, 1); |
| 293 | 293 | if ($result > 0) { |
@@ -470,7 +470,7 @@ discard block |
||
| 470 | 470 | } |
| 471 | 471 | $conf->global->MAIN_VERSION_LAST_UPGRADE = $targetversion; |
| 472 | 472 | } else { |
| 473 | - dolibarr_install_syslog('step5: we run an upgrade to version '.$targetversion.' but database was already upgraded to ' . getDolGlobalString('MAIN_VERSION_LAST_UPGRADE').'. We keep MAIN_VERSION_LAST_UPGRADE as it is.'); |
|
| 473 | + dolibarr_install_syslog('step5: we run an upgrade to version '.$targetversion.' but database was already upgraded to '.getDolGlobalString('MAIN_VERSION_LAST_UPGRADE').'. We keep MAIN_VERSION_LAST_UPGRADE as it is.'); |
|
| 474 | 474 | |
| 475 | 475 | // Force the delete of the flag that say installation is not complete |
| 476 | 476 | dolibarr_install_syslog('step5: remove MAIN_NOT_INSTALLED const after upgrade process (should not exists but this is a security)'); |
@@ -533,7 +533,7 @@ discard block |
||
| 533 | 533 | print '</a></div><br>'; |
| 534 | 534 | } else { |
| 535 | 535 | // If here MAIN_VERSION_LAST_UPGRADE is not empty |
| 536 | - print $langs->trans("VersionLastUpgrade").': <b><span class="ok">' . getDolGlobalString('MAIN_VERSION_LAST_UPGRADE').'</span></b><br>'; |
|
| 536 | + print $langs->trans("VersionLastUpgrade").': <b><span class="ok">'.getDolGlobalString('MAIN_VERSION_LAST_UPGRADE').'</span></b><br>'; |
|
| 537 | 537 | print $langs->trans("VersionProgram").': <b><span class="ok">'.DOL_VERSION.'</span></b><br>'; |
| 538 | 538 | print $langs->trans("MigrationNotFinished").'<br>'; |
| 539 | 539 | print "<br>"; |
@@ -583,7 +583,7 @@ discard block |
||
| 583 | 583 | $morehtml .= '</a></div><br>'; |
| 584 | 584 | } else { |
| 585 | 585 | // If here MAIN_VERSION_LAST_UPGRADE is not empty |
| 586 | - print $langs->trans("VersionLastUpgrade").': <b><span class="okinversed">' . getDolGlobalString('MAIN_VERSION_LAST_UPGRADE').'</span></b><br>'; |
|
| 586 | + print $langs->trans("VersionLastUpgrade").': <b><span class="okinversed">'.getDolGlobalString('MAIN_VERSION_LAST_UPGRADE').'</span></b><br>'; |
|
| 587 | 587 | print '<br>'; |
| 588 | 588 | print $langs->trans("VersionProgram").': <b><span class="okinversed">'.DOL_VERSION.'</span></b>'; |
| 589 | 589 | |