Completed
Branch develop (a68b00)
by
unknown
17:52
created
htdocs/accountancy/supplier/list.php 1 patch
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 $search_date_endday = GETPOST('search_date_endday', 'int');
71 71
 $search_date_endmonth = GETPOST('search_date_endmonth', 'int');
72 72
 $search_date_endyear = GETPOST('search_date_endyear', 'int');
73
-$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear);	// Use tzserver
73
+$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear); // Use tzserver
74 74
 $search_date_end = dol_mktime(23, 59, 59, $search_date_endmonth, $search_date_endday, $search_date_endyear);
75 75
 $search_country = GETPOST('search_country', 'alpha');
76 76
 $search_tvaintra = GETPOST('search_tvaintra', 'alpha');
@@ -261,20 +261,20 @@  discard block
 block discarded – undo
261 261
 $sql .= " FROM ".MAIN_DB_PREFIX."facture_fourn as f";
262 262
 $sql .= " INNER JOIN ".MAIN_DB_PREFIX."societe as s ON s.rowid = f.fk_soc";
263 263
 if (!empty($conf->global->MAIN_COMPANY_PERENTITY_SHARED)) {
264
-	$sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "societe_perentity as spe ON spe.fk_soc = s.rowid AND spe.entity = " . ((int) $conf->entity);
264
+	$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe_perentity as spe ON spe.fk_soc = s.rowid AND spe.entity = ".((int) $conf->entity);
265 265
 }
266 266
 $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_country as co ON co.rowid = s.fk_pays ";
267 267
 $sql .= " INNER JOIN ".MAIN_DB_PREFIX."facture_fourn_det as l ON f.rowid = l.fk_facture_fourn";
268 268
 $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product as p ON p.rowid = l.fk_product";
269 269
 if (!empty($conf->global->MAIN_PRODUCT_PERENTITY_SHARED)) {
270
-	$sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "product_perentity as ppe ON ppe.fk_product = p.rowid AND ppe.entity = " . ((int) $conf->entity);
270
+	$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_perentity as ppe ON ppe.fk_product = p.rowid AND ppe.entity = ".((int) $conf->entity);
271 271
 }
272 272
 $alias_societe_perentity = empty($conf->global->MAIN_COMPANY_PERENTITY_SHARED) ? "s" : "spe";
273 273
 $alias_product_perentity = empty($conf->global->MAIN_PRODUCT_PERENTITY_SHARED) ? "p" : "ppe";
274
-$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa  ON " . $alias_product_perentity . ".accountancy_code_buy = aa.account_number         AND aa.active = 1  AND aa.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa.entity = ".$conf->entity;
275
-$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa2 ON " . $alias_product_perentity . ".accountancy_code_buy_intra = aa2.account_number  AND aa2.active = 1 AND aa2.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa2.entity = ".$conf->entity;
276
-$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa3 ON " . $alias_product_perentity . ".accountancy_code_buy_export = aa3.account_number AND aa3.active = 1 AND aa3.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa3.entity = ".$conf->entity;
277
-$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa4 ON " . $alias_societe_perentity . ".accountancy_code_buy = aa4.account_number        AND aa4.active = 1 AND aa4.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa4.entity = ".$conf->entity;
274
+$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa  ON ".$alias_product_perentity.".accountancy_code_buy = aa.account_number         AND aa.active = 1  AND aa.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa.entity = ".$conf->entity;
275
+$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa2 ON ".$alias_product_perentity.".accountancy_code_buy_intra = aa2.account_number  AND aa2.active = 1 AND aa2.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa2.entity = ".$conf->entity;
276
+$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa3 ON ".$alias_product_perentity.".accountancy_code_buy_export = aa3.account_number AND aa3.active = 1 AND aa3.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa3.entity = ".$conf->entity;
277
+$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa4 ON ".$alias_societe_perentity.".accountancy_code_buy = aa4.account_number        AND aa4.active = 1 AND aa4.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa4.entity = ".$conf->entity;
278 278
 $sql .= " WHERE f.fk_statut > 0 AND l.fk_code_ventilation <= 0";
279 279
 $sql .= " AND l.product_type <= 2";
280 280
 // Define begin binding date
@@ -468,7 +468,7 @@  discard block
 block discarded – undo
468 468
 	print_barre_liste($langs->trans("InvoiceLines"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num_lines, $nbtotalofrecords, 'title_accountancy', 0, '', '', $limit);
469 469
 
470 470
 	if ($massaction == 'set_default_account') {
471
-		$formquestion[]=array('type' => 'other',
471
+		$formquestion[] = array('type' => 'other',
472 472
 				'name' => 'set_default_account',
473 473
 				'label' => $langs->trans("AccountancyCode"),
474 474
 				'value' => $formaccounting->select_account('', 'default_account', 1, array(), 0, 0, 'maxwidth200 maxwidthonsmartphone', 'cachewithshowemptyone'));
@@ -570,7 +570,7 @@  discard block
 block discarded – undo
570 570
 		$thirdpartystatic->email = $objp->email;
571 571
 		$thirdpartystatic->country_code = $objp->country_code;
572 572
 		$thirdpartystatic->tva_intra = $objp->tva_intra;
573
-		$thirdpartystatic->code_compta_product = $objp->company_code_buy;		// The accounting account for product stored on thirdparty object (for level3 suggestion)
573
+		$thirdpartystatic->code_compta_product = $objp->company_code_buy; // The accounting account for product stored on thirdparty object (for level3 suggestion)
574 574
 
575 575
 		$product_static->ref = $objp->product_ref;
576 576
 		$product_static->id = $objp->product_id;
@@ -612,16 +612,16 @@  discard block
 block discarded – undo
612 612
 
613 613
 		$suggestedid = 0;
614 614
 
615
-		$return=$accountingAccount->getAccountingCodeToBind($mysoc, $thirdpartystatic, $product_static, $facturefourn_static, $facturefourn_static_det, $accountingAccountArray, 'supplier');
616
-		if (!is_array($return) && $return<0) {
615
+		$return = $accountingAccount->getAccountingCodeToBind($mysoc, $thirdpartystatic, $product_static, $facturefourn_static, $facturefourn_static_det, $accountingAccountArray, 'supplier');
616
+		if (!is_array($return) && $return < 0) {
617 617
 			setEventMessage($accountingAccount->error, 'errors');
618 618
 		} else {
619
-			$suggestedid=$return['suggestedid'];
620
-			$suggestedaccountingaccountfor=$return['suggestedaccountingaccountfor'];
621
-			$suggestedaccountingaccountbydefaultfor=$return['suggestedaccountingaccountbydefaultfor'];
622
-			$code_buy_l=$return['code_l'];
623
-			$code_buy_p=$return['code_p'];
624
-			$code_buy_t=$return['code_t'];
619
+			$suggestedid = $return['suggestedid'];
620
+			$suggestedaccountingaccountfor = $return['suggestedaccountingaccountfor'];
621
+			$suggestedaccountingaccountbydefaultfor = $return['suggestedaccountingaccountbydefaultfor'];
622
+			$code_buy_l = $return['code_l'];
623
+			$code_buy_p = $return['code_p'];
624
+			$code_buy_t = $return['code_t'];
625 625
 		}
626 626
 		//var_dump($return);
627 627
 
@@ -693,7 +693,7 @@  discard block
 block discarded – undo
693 693
 		//if ($objp->vat_tx_l != $objp->vat_tx_p && price2num($objp->vat_tx_p) && price2num($objp->vat_tx_l)) {	// Note: having a vat rate of 0 is often the normal case when sells is intra b2b or to export
694 694
 		//	$code_vat_differ = 'warning bold';
695 695
 		//}
696
-		print '<td class="right'.($code_vat_differ?' '.$code_vat_differ:'').'">';
696
+		print '<td class="right'.($code_vat_differ ? ' '.$code_vat_differ : '').'">';
697 697
 		print vatrate($facturefourn_static_det->tva_tx.($facturefourn_static_det->vat_src_code ? ' ('.$facturefourn_static_det->vat_src_code.')' : ''), false, 0, 0, 1);
698 698
 		print '</td>';
699 699
 
@@ -767,7 +767,7 @@  discard block
 block discarded – undo
767 767
 		if (!empty($toselect)) {
768 768
 			$ischecked = 0;
769 769
 			if (in_array($objp->rowid."_".$i, $toselect)) {
770
-				$ischecked=1;
770
+				$ischecked = 1;
771 771
 			}
772 772
 		}
773 773
 
Please login to merge, or discard this patch.
htdocs/accountancy/expensereport/lines.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
 $search_date_endday = GETPOST('search_date_endday', 'int');
56 56
 $search_date_endmonth = GETPOST('search_date_endmonth', 'int');
57 57
 $search_date_endyear = GETPOST('search_date_endyear', 'int');
58
-$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear);	// Use tzserver
58
+$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear); // Use tzserver
59 59
 $search_date_end = dol_mktime(23, 59, 59, $search_date_endmonth, $search_date_endday, $search_date_endyear);
60 60
 
61 61
 // Load variable for pagination
@@ -428,7 +428,7 @@  discard block
 block discarded – undo
428 428
 		$i++;
429 429
 	}
430 430
 	if ($num_lines == 0) {
431
-		$colspan=10;
431
+		$colspan = 10;
432 432
 		if (!empty($conf->global->ACCOUNTANCY_USE_EXPENSE_REPORT_VALIDATION_DATE)) {
433 433
 			$colspan++;
434 434
 		}
Please login to merge, or discard this patch.
htdocs/fichinter/stats/index.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -288,7 +288,7 @@
 block discarded – undo
288 288
 	print '<tr class="oddeven" height="24">';
289 289
 	print '<td class="center"><a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&amp;mode='.$mode.($socid > 0 ? '&socid='.$socid : '').($userid > 0 ? '&userid='.$userid : '').'">'.$year.'</a></td>';
290 290
 	print '<td class="right">'.$val['nb'].'</td>';
291
-	print '<td class="right opacitylow" style="'.((!isset($val['nb_diff']) || $val['nb_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.(isset($val['nb_diff']) ? round($val['nb_diff']): "0").'%</td>';
291
+	print '<td class="right opacitylow" style="'.((!isset($val['nb_diff']) || $val['nb_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.(isset($val['nb_diff']) ? round($val['nb_diff']) : "0").'%</td>';
292 292
 	print '<td class="right">'.price(price2num($val['total'], 'MT'), 1).'</td>';
293 293
 	print '<td class="right opacitylow" style="'.((!isset($val['total_diff']) || $val['total_diff'] >= 0) ? 'color: green;' : 'color: red;').'">'.(isset($val['total_diff']) ? round($val['total_diff']) : "0").'%</td>';
294 294
 	print '<td class="right">'.price(price2num($val['avg'], 'MT'), 1).'</td>';
Please login to merge, or discard this patch.
htdocs/fichinter/card-rec.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -357,7 +357,7 @@
 block discarded – undo
357 357
 		if (isModEnabled('contrat')) {
358 358
 			$formcontract = new FormContract($db);
359 359
 			print "<tr><td>".$langs->trans("Contract")."</td><td>";
360
-			$contractid = GETPOST('contractid') ? GETPOST('contractid') : (!empty($object->fk_contract) ? $object->fk_contract : 0) ;
360
+			$contractid = GETPOST('contractid') ? GETPOST('contractid') : (!empty($object->fk_contract) ? $object->fk_contract : 0);
361 361
 			$numcontract = $formcontract->select_contract($object->thirdparty->id, $contractid, 'contracttid');
362 362
 			print "</td></tr>";
363 363
 		}
Please login to merge, or discard this patch.
htdocs/fourn/facture/card.php 2 patches
Braces   +6 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3640,9 +3640,12 @@
 block discarded – undo
3640 3640
 
3641 3641
 				$parameters = array();
3642 3642
 				$reshook = $hookmanager->executeHooks('formAddObjectLine', $parameters, $object, $action); // Note that $action and $object may have been modified by hook
3643
-				if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
3644
-				if (empty($reshook))
3645
-					$object->formAddObjectLine(1, $societe, $mysoc);
3643
+				if ($reshook < 0) {
3644
+					setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
3645
+				}
3646
+				if (empty($reshook)) {
3647
+									$object->formAddObjectLine(1, $societe, $mysoc);
3648
+				}
3646 3649
 			}
3647 3650
 		}
3648 3651
 
Please login to merge, or discard this patch.
Spacing   +44 added lines, -44 removed lines patch added patch discarded remove patch
@@ -720,7 +720,7 @@  discard block
 block discarded – undo
720 720
 			$error++;
721 721
 		}
722 722
 
723
-		$dateinvoice = dol_mktime(0, 0, 0, GETPOST('remonth', 'int'), GETPOST('reday', 'int'), GETPOST('reyear', 'int'), 'tzserver');	// If we enter the 02 january, we need to save the 02 january for server
723
+		$dateinvoice = dol_mktime(0, 0, 0, GETPOST('remonth', 'int'), GETPOST('reday', 'int'), GETPOST('reyear', 'int'), 'tzserver'); // If we enter the 02 january, we need to save the 02 january for server
724 724
 		$datedue = dol_mktime(0, 0, 0, GETPOST('echmonth', 'int'), GETPOST('echday', 'int'), GETPOST('echyear', 'int'), 'tzserver');
725 725
 		//var_dump($dateinvoice.' '.dol_print_date($dateinvoice, 'dayhour'));
726 726
 		//var_dump(dol_now('tzuserrel').' '.dol_get_last_hour(dol_now('tzuserrel')).' '.dol_print_date(dol_now('tzuserrel'),'dayhour').' '.dol_print_date(dol_get_last_hour(dol_now('tzuserrel')), 'dayhour'));
@@ -758,7 +758,7 @@  discard block
 block discarded – undo
758 758
 				$object->ref = GETPOST('ref', 'alphanohtml');
759 759
 				$object->ref_supplier = GETPOST('ref_supplier', 'alpha');
760 760
 				$object->socid = GETPOST('socid', 'int');
761
-				$object->libelle = GETPOST('label', 'alphanohtml');	// deprecated
761
+				$object->libelle = GETPOST('label', 'alphanohtml'); // deprecated
762 762
 				$object->label = GETPOST('label', 'alphanohtml');
763 763
 				$object->date = $dateinvoice;
764 764
 				$object->date_echeance = $datedue;
@@ -976,27 +976,27 @@  discard block
 block discarded – undo
976 976
 				$tmpproject = GETPOST('projectid', 'int');
977 977
 
978 978
 				// Creation invoice
979
+				$object->socid = GETPOST('socid', 'int');
980
+				$object->type = GETPOST('type', 'alphanohtml');
981
+				$object->ref = GETPOST('ref', 'alphanohtml');
982
+				$object->ref_supplier = GETPOST('ref_supplier', 'alphanohtml');
979 983
 				$object->socid				= GETPOST('socid', 'int');
980
-				$object->type				= GETPOST('type', 'alphanohtml');
981
-				$object->ref				= GETPOST('ref', 'alphanohtml');
982
-				$object->ref_supplier		= GETPOST('ref_supplier', 'alphanohtml');
983
-				$object->socid				= GETPOST('socid', 'int');
984
-				$object->libelle			= GETPOST('label', 'alphanohtml');	// deprecated
984
+				$object->libelle = GETPOST('label', 'alphanohtml'); // deprecated
985 985
 				$object->label				= GETPOST('label', 'alphanohtml');
986
-				$object->date				= $dateinvoice;
987
-				$object->date_echeance		= $datedue;
988
-				$object->note_public		= GETPOST('note_public', 'restricthtml');
989
-				$object->note_private		= GETPOST('note_private', 'restricthtml');
986
+				$object->date = $dateinvoice;
987
+				$object->date_echeance = $datedue;
988
+				$object->note_public = GETPOST('note_public', 'restricthtml');
989
+				$object->note_private = GETPOST('note_private', 'restricthtml');
990 990
 				$object->cond_reglement_id	= GETPOST('cond_reglement_id');
991 991
 				$object->mode_reglement_id	= GETPOST('mode_reglement_id');
992 992
 				$object->fk_account			= GETPOST('fk_account', 'int');
993 993
 				$object->vat_reverse_charge	= GETPOST('vat_reverse_charge') == 'on' ? 1 : 0;
994 994
 				$object->fk_project			= ($tmpproject > 0) ? $tmpproject : null;
995
-				$object->fk_incoterms		= GETPOST('incoterm_id', 'int');
995
+				$object->fk_incoterms = GETPOST('incoterm_id', 'int');
996 996
 				$object->location_incoterms	= GETPOST('location_incoterms', 'alpha');
997 997
 				$object->multicurrency_code	= GETPOST('multicurrency_code', 'alpha');
998
-				$object->multicurrency_tx	= GETPOST('originmulticurrency_tx', 'int');
999
-				$object->transport_mode_id	= GETPOST('transport_mode_id');
998
+				$object->multicurrency_tx = GETPOST('originmulticurrency_tx', 'int');
999
+				$object->transport_mode_id = GETPOST('transport_mode_id');
1000 1000
 
1001 1001
 				// Auto calculation of date due if not filled by user
1002 1002
 				if (empty($object->date_echeance)) {
@@ -1335,7 +1335,7 @@  discard block
 block discarded – undo
1335 1335
 		// Edit line
1336 1336
 		$db->begin();
1337 1337
 
1338
-		if (! $object->fetch($id) > 0) {
1338
+		if (!$object->fetch($id) > 0) {
1339 1339
 			dol_print_error($db);
1340 1340
 		}
1341 1341
 		$object->fetch_thirdparty();
@@ -1479,7 +1479,7 @@  discard block
 block discarded – undo
1479 1479
 			$idprod = GETPOST('idprod', 'int');
1480 1480
 		}
1481 1481
 
1482
-		$tva_tx = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0);		// Can be '1.2' or '1.2 (CODE)'
1482
+		$tva_tx = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0); // Can be '1.2' or '1.2 (CODE)'
1483 1483
 
1484 1484
 		$price_ht = price2num(GETPOST('price_ht'), 'MU', 2);
1485 1485
 		$price_ht_devise = price2num(GETPOST('multicurrency_price_ht'), 'CU', 2);
@@ -2246,7 +2246,7 @@  discard block
 block discarded – undo
2246 2246
 
2247 2247
 		$sql = 'SELECT r.rowid, r.titre as title, r.total_ttc';
2248 2248
 		$sql .= ' FROM '.MAIN_DB_PREFIX.'facture_fourn_rec as r';
2249
-		$sql .= ' WHERE r.fk_soc = '. (int) $invoice_predefined->socid;
2249
+		$sql .= ' WHERE r.fk_soc = '.(int) $invoice_predefined->socid;
2250 2250
 
2251 2251
 		$resql = $db->query($sql);
2252 2252
 		if ($resql) {
@@ -2304,7 +2304,7 @@  discard block
 block discarded – undo
2304 2304
 
2305 2305
 	// Standard invoice
2306 2306
 	print '<div class="tagtr listofinvoicetype"><div class="tagtd listofinvoicetype">';
2307
-	$tmp = '<input type="radio" id="radio_standard" name="type" value="0"'.(GETPOST('type', 'int')? '' : 'checked').'> ';
2307
+	$tmp = '<input type="radio" id="radio_standard" name="type" value="0"'.(GETPOST('type', 'int') ? '' : 'checked').'> ';
2308 2308
 	$desc = $form->textwithpicto($tmp.'<label for="radio_standard">'.$langs->trans("InvoiceStandardAsk").'</label>', $langs->transnoentities("InvoiceStandardDesc"), 1, 'help', '', 0, 3);
2309 2309
 	print $desc;
2310 2310
 	print '</div></div>';
@@ -2313,7 +2313,7 @@  discard block
 block discarded – undo
2313 2313
 		// Deposit - Down payment
2314 2314
 		if (empty($conf->global->INVOICE_DISABLE_DEPOSIT)) {
2315 2315
 			print '<div class="tagtr listofinvoicetype"><div class="tagtd listofinvoicetype">';
2316
-			$tmp='<input type="radio" id="radio_deposit" name="type" value="3"' . (GETPOST('type') == 3 ? ' checked' : '') . '> ';
2316
+			$tmp = '<input type="radio" id="radio_deposit" name="type" value="3"'.(GETPOST('type') == 3 ? ' checked' : '').'> ';
2317 2317
 			print '<script type="text/javascript">
2318 2318
 			jQuery(document).ready(function() {
2319 2319
     			jQuery("#typestandardinvoice, #valuestandardinvoice").click(function() {
@@ -2359,7 +2359,7 @@  discard block
 block discarded – undo
2359 2359
 				print $form->selectarray('typedeposit', $arraylist, GETPOST('typedeposit', 'aZ09'), 0, 0, 0, '', 1);
2360 2360
 				print '</td>';
2361 2361
 				print '<td class="nowrap" style="padding-left: 5px">';
2362
-				print '<span class="opacitymedium paddingleft">'.$langs->trans("AmountOrPercent").'</span><input type="text" id="valuedeposit" name="valuedeposit" class="width75 right" value="' . GETPOST('valuedeposit', 'int') . '"/>';
2362
+				print '<span class="opacitymedium paddingleft">'.$langs->trans("AmountOrPercent").'</span><input type="text" id="valuedeposit" name="valuedeposit" class="width75 right" value="'.GETPOST('valuedeposit', 'int').'"/>';
2363 2363
 				print '</td>';
2364 2364
 			}
2365 2365
 			print '</tr></table>';
@@ -2514,7 +2514,7 @@  discard block
 block discarded – undo
2514 2514
 			if (empty($conf->global->INVOICE_CREDIT_NOTE_STANDALONE)) {
2515 2515
 				$tmp = '<input type="radio" name="type" id="radio_creditnote" value="0" disabled> ';
2516 2516
 			} else {
2517
-				$tmp='<input type="radio" name="type" id="radio_creditnote" value="2"> ';
2517
+				$tmp = '<input type="radio" name="type" id="radio_creditnote" value="2"> ';
2518 2518
 			}
2519 2519
 			$text = $tmp.$langs->trans("InvoiceAvoir").' ';
2520 2520
 			$text .= '<span class="opacitymedium">('.$langs->trans("YouMustCreateInvoiceFromSupplierThird").')</span> ';
@@ -2597,7 +2597,7 @@  discard block
 block discarded – undo
2597 2597
 
2598 2598
 	// Vat reverse-charge by default
2599 2599
 	if (!empty($conf->global->ACCOUNTING_FORCE_ENABLE_VAT_REVERSE_CHARGE)) {
2600
-		print '<tr><td>' . $langs->trans('VATReverseCharge') . '</td><td>';
2600
+		print '<tr><td>'.$langs->trans('VATReverseCharge').'</td><td>';
2601 2601
 		// Try to propose to use VAT reverse charge even if the VAT reverse charge is not activated in the supplier card, if this corresponds to the context of use, the activation is proposed
2602 2602
 		if ($vat_reverse_charge == 1 || $societe->vat_reverse_charge == 1 || ($societe->country_code != 'FR' && isInEEC($societe) && !empty($societe->tva_intra))) {
2603 2603
 			$vat_reverse_charge = 1;
@@ -2605,7 +2605,7 @@  discard block
 block discarded – undo
2605 2605
 			$vat_reverse_charge = 0;
2606 2606
 		}
2607 2607
 
2608
-		print '<input type="checkbox" name="vat_reverse_charge"'. (!empty($vat_reverse_charge) ? ' checked ' : '') . '>';
2608
+		print '<input type="checkbox" name="vat_reverse_charge"'.(!empty($vat_reverse_charge) ? ' checked ' : '').'>';
2609 2609
 		print '</td></tr>';
2610 2610
 	}
2611 2611
 
@@ -3113,7 +3113,7 @@  discard block
 block discarded – undo
3113 3113
 				$facavoir->fetch($id);
3114 3114
 				$invoicecredits[] = $facavoir->getNomUrl(1);
3115 3115
 			}
3116
-			print ' <span class="opacitymediumbycolor paddingleft">'.$langs->transnoentities("InvoiceHasAvoir") . (count($invoicecredits) ? ' ' : '') . implode(',', $invoicecredits);
3116
+			print ' <span class="opacitymediumbycolor paddingleft">'.$langs->transnoentities("InvoiceHasAvoir").(count($invoicecredits) ? ' ' : '').implode(',', $invoicecredits);
3117 3117
 			print '</span>';
3118 3118
 		}
3119 3119
 		if (isset($objectidnext) && $objectidnext > 0) {
@@ -3309,12 +3309,12 @@  discard block
 block discarded – undo
3309 3309
 				print '<input type="hidden" name="action" value="setvatreversecharge">';
3310 3310
 				print '<input type="hidden" name="token" value="'.newToken().'">';
3311 3311
 
3312
-				print '<input type="checkbox" name="vat_reverse_charge"' . ($object->vat_reverse_charge == '1' ? ' checked ' : '') . '>';
3312
+				print '<input type="checkbox" name="vat_reverse_charge"'.($object->vat_reverse_charge == '1' ? ' checked ' : '').'>';
3313 3313
 
3314 3314
 				print '<input type="submit" class="button valignmiddle" value="'.$langs->trans("Modify").'">';
3315 3315
 				print '</form>';
3316 3316
 			} else {
3317
-				print '<input type="checkbox" name="vat_reverse_charge"'. ($object->vat_reverse_charge == '1' ? ' checked ' : '') . ' disabled>';
3317
+				print '<input type="checkbox" name="vat_reverse_charge"'.($object->vat_reverse_charge == '1' ? ' checked ' : '').' disabled>';
3318 3318
 			}
3319 3319
 			print '</td></tr>';
3320 3320
 		}
@@ -3375,15 +3375,15 @@  discard block
 block discarded – undo
3375 3375
 		print '<table class="border tableforfield centpercent">';
3376 3376
 
3377 3377
 		print '<tr>';
3378
-		print '<td class="titlefieldmiddle">' . $langs->trans('AmountHT') . '</td>';
3379
-		print '<td class="nowrap amountcard right">' . price($object->total_ht, '', $langs, 0, -1, -1, $conf->currency) . '</td>';
3378
+		print '<td class="titlefieldmiddle">'.$langs->trans('AmountHT').'</td>';
3379
+		print '<td class="nowrap amountcard right">'.price($object->total_ht, '', $langs, 0, -1, -1, $conf->currency).'</td>';
3380 3380
 		if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) {
3381
-			print '<td class="nowrap amountcard right">' . price($object->multicurrency_total_ht, '', $langs, 0, -1, -1, $object->multicurrency_code) . '</td>';
3381
+			print '<td class="nowrap amountcard right">'.price($object->multicurrency_total_ht, '', $langs, 0, -1, -1, $object->multicurrency_code).'</td>';
3382 3382
 		}
3383 3383
 		print '</tr>';
3384 3384
 
3385 3385
 		print '<tr>';
3386
-		print '<td>' . $langs->trans('AmountVAT') . '</td>';
3386
+		print '<td>'.$langs->trans('AmountVAT').'</td>';
3387 3387
 		print '<td class="nowrap amountcard right">';
3388 3388
 		if (GETPOST('calculationrule')) {
3389 3389
 			$calculationrule = GETPOST('calculationrule', 'alpha');
@@ -3397,40 +3397,40 @@  discard block
 block discarded – undo
3397 3397
 		}
3398 3398
 		// Show link for "recalculate"
3399 3399
 		if ($object->getVentilExportCompta() == 0) {
3400
-			$s = '<span class="hideonsmartphone opacitymedium">' . $langs->trans("ReCalculate") . ' </span>';
3401
-			$s .= '<a href="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=calculate&calculationrule=totalofround">' . $langs->trans("Mode1") . '</a>';
3400
+			$s = '<span class="hideonsmartphone opacitymedium">'.$langs->trans("ReCalculate").' </span>';
3401
+			$s .= '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=calculate&calculationrule=totalofround">'.$langs->trans("Mode1").'</a>';
3402 3402
 			$s .= ' / ';
3403
-			$s .= '<a href="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=calculate&calculationrule=roundoftotal">' . $langs->trans("Mode2") . '</a>';
3403
+			$s .= '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=calculate&calculationrule=roundoftotal">'.$langs->trans("Mode2").'</a>';
3404 3404
 			print '<div class="inline-block">';
3405
-			print $form->textwithtooltip($s, $langs->trans("CalculationRuleDesc", $calculationrulenum) . '<br>' . $langs->trans("CalculationRuleDescSupplier"), 2, 1, img_picto('', 'help'), '', 3, '', 0, 'recalculate');
3405
+			print $form->textwithtooltip($s, $langs->trans("CalculationRuleDesc", $calculationrulenum).'<br>'.$langs->trans("CalculationRuleDescSupplier"), 2, 1, img_picto('', 'help'), '', 3, '', 0, 'recalculate');
3406 3406
 			print '&nbsp; &nbsp; &nbsp; &nbsp;';
3407 3407
 			print '</div>';
3408 3408
 		}
3409 3409
 		print price($object->total_tva, 1, $langs, 0, -1, -1, $conf->currency);
3410 3410
 		print '</td>';
3411 3411
 		if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) {
3412
-			print '<td class="nowrap amountcard right">' . price($object->multicurrency_total_tva, '', $langs, 0, -1, -1, $object->multicurrency_code) . '</td>';
3412
+			print '<td class="nowrap amountcard right">'.price($object->multicurrency_total_tva, '', $langs, 0, -1, -1, $object->multicurrency_code).'</td>';
3413 3413
 		}
3414 3414
 		print '</tr>';
3415 3415
 
3416 3416
 		if ($societe->localtax1_assuj == "1") { //Localtax1
3417 3417
 			print '<tr>';
3418
-			print '<td>' . $langs->transcountry("AmountLT1", $societe->country_code) . '</td>';
3419
-			print '<td class="nowrap amountcard right">' . price($object->total_localtax1, 1, $langs, 0, -1, -1, $conf->currency) . '</td>';
3418
+			print '<td>'.$langs->transcountry("AmountLT1", $societe->country_code).'</td>';
3419
+			print '<td class="nowrap amountcard right">'.price($object->total_localtax1, 1, $langs, 0, -1, -1, $conf->currency).'</td>';
3420 3420
 			print '</tr>';
3421 3421
 		}
3422 3422
 		if ($societe->localtax2_assuj == "1") { //Localtax2
3423 3423
 			print '<tr>';
3424
-			print '<td>' . $langs->transcountry("AmountLT2", $societe->country_code) . '</td>';
3425
-			print '<td class="nowrap amountcard right">' . price($object->total_localtax2, 1, $langs, 0, -1, -1, $conf->currency) . '</td>';
3424
+			print '<td>'.$langs->transcountry("AmountLT2", $societe->country_code).'</td>';
3425
+			print '<td class="nowrap amountcard right">'.price($object->total_localtax2, 1, $langs, 0, -1, -1, $conf->currency).'</td>';
3426 3426
 			print '</tr>';
3427 3427
 		}
3428 3428
 
3429 3429
 		print '<tr>';
3430
-		print '<td>' . $langs->trans('AmountTTC') . '</td>';
3431
-		print '<td class="nowrap amountcard right">' . price($object->total_ttc, '', $langs, 0, -1, -1, $conf->currency) . '</td>';
3430
+		print '<td>'.$langs->trans('AmountTTC').'</td>';
3431
+		print '<td class="nowrap amountcard right">'.price($object->total_ttc, '', $langs, 0, -1, -1, $conf->currency).'</td>';
3432 3432
 		if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) {
3433
-			print '<td class="nowrap amountcard right">' . price($object->multicurrency_total_ttc, '', $langs, 0, -1, -1, $object->multicurrency_code) . '</td>';
3433
+			print '<td class="nowrap amountcard right">'.price($object->multicurrency_total_ttc, '', $langs, 0, -1, -1, $object->multicurrency_code).'</td>';
3434 3434
 		}
3435 3435
 		print '</tr>';
3436 3436
 
@@ -3736,7 +3736,7 @@  discard block
 block discarded – undo
3736 3736
 				print '<tr><td colspan="'.$nbcols.'" class="right">';
3737 3737
 				print '<span class="opacitymedium">';
3738 3738
 				print $langs->trans('RemainderToPayBackMulticurrency');
3739
-				if ($resteapayeraffiche> 0) {
3739
+				if ($resteapayeraffiche > 0) {
3740 3740
 					print ' ('.$langs->trans('NegativeIfExcessRefunded').')';
3741 3741
 				}
3742 3742
 				print '</span>';
@@ -3965,7 +3965,7 @@  discard block
 block discarded – undo
3965 3965
 				}
3966 3966
 
3967 3967
 				// Clone as predefined / Create template
3968
-				if (($object->type ==  FactureFournisseur::TYPE_STANDARD || $object->type == FactureFournisseur::TYPE_DEPOSIT) && $object->statut == 0 && $usercancreate) {
3968
+				if (($object->type == FactureFournisseur::TYPE_STANDARD || $object->type == FactureFournisseur::TYPE_DEPOSIT) && $object->statut == 0 && $usercancreate) {
3969 3969
 					if (!$objectidnext && count($object->lines) > 0) {
3970 3970
 						print '<a class="butAction" href="'.DOL_URL_ROOT.'/fourn/facture/card-rec.php?facid='.$object->id.'&amp;action=create">'.$langs->trans("ChangeIntoRepeatableInvoice").'</a>';
3971 3971
 					}
Please login to merge, or discard this patch.
htdocs/fourn/paiement/document.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -126,7 +126,7 @@
 block discarded – undo
126 126
 	$morehtmlref .= '<br>'.$object->thirdparty->getNomUrl(1);
127 127
 
128 128
 	// Amount
129
-	$morehtmlref .= '<br>'.$langs->trans('Amount').' : '. price($object->amount, '', $langs, 0, 0, -1, $conf->currency);
129
+	$morehtmlref .= '<br>'.$langs->trans('Amount').' : '.price($object->amount, '', $langs, 0, 0, -1, $conf->currency);
130 130
 
131 131
 	$allow_delete = 1;
132 132
 	// Bank account
Please login to merge, or discard this patch.
htdocs/fourn/commande/card.php 2 patches
Braces   +9 added lines, -5 removed lines patch added patch discarded remove patch
@@ -687,8 +687,9 @@  discard block
 block discarded – undo
687 687
 				$newlang = '';
688 688
 				if (getDolGlobalInt('MAIN_MULTILANGS') && empty($newlang)) {
689 689
 					$newlang = $object->thirdparty->default_lang;
690
-					if (GETPOST('lang_id', 'aZ09'))
691
-						$newlang = GETPOST('lang_id', 'aZ09');
690
+					if (GETPOST('lang_id', 'aZ09')) {
691
+											$newlang = GETPOST('lang_id', 'aZ09');
692
+					}
692 693
 				}
693 694
 				if (!empty($newlang)) {
694 695
 					$outputlangs = new Translate("", $conf);
@@ -2427,9 +2428,12 @@  discard block
 block discarded – undo
2427 2428
 
2428 2429
 			$parameters = array();
2429 2430
 			$reshook = $hookmanager->executeHooks('formAddObjectLine', $parameters, $object, $action); // Note that $action and $object may have been modified by hook
2430
-			if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
2431
-			if (empty($reshook))
2432
-				$object->formAddObjectLine(1, $societe, $mysoc);
2431
+			if ($reshook < 0) {
2432
+				setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
2433
+			}
2434
+			if (empty($reshook)) {
2435
+							$object->formAddObjectLine(1, $societe, $mysoc);
2436
+			}
2433 2437
 		}
2434 2438
 	}
2435 2439
 	print '</table>';
Please login to merge, or discard this patch.
Spacing   +28 added lines, -28 removed lines patch added patch discarded remove patch
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
 $result = restrictedArea($user, 'fournisseur', $object, 'commande_fournisseur', 'commande', 'fk_soc', 'rowid', $isdraft);
138 138
 
139 139
 // Common permissions
140
-$usercanread	= ($user->hasRight("fournisseur", "commande", "lire") || $user->hasRight("supplier_order", "lire"));
140
+$usercanread = ($user->hasRight("fournisseur", "commande", "lire") || $user->hasRight("supplier_order", "lire"));
141 141
 $usercancreate	= ($user->hasRight("fournisseur", "commande", "creer") || $user->hasRight("supplier_order", "creer"));
142 142
 $usercandelete	= (($user->hasRight("fournisseur", "commande", "supprimer") || $user->hasRight("supplier_order", "supprimer")) || ($usercancreate && isset($object->statut) && $object->statut == $object::STATUS_DRAFT));
143 143
 
@@ -145,9 +145,9 @@  discard block
 block discarded – undo
145 145
 $usercanvalidate = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($usercancreate)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->hasRight("fournisseur", "supplier_order_advance", "validate")));
146 146
 
147 147
 // Additional area permissions
148
-$usercanapprove			= $user->hasRight("fournisseur", "commande", "approuver");
149
-$usercanapprovesecond	= $user->hasRight("fournisseur", "commande", "approve2");
150
-$usercanorder			= $user->hasRight("fournisseur", "commande", "commander");
148
+$usercanapprove = $user->hasRight("fournisseur", "commande", "approuver");
149
+$usercanapprovesecond = $user->hasRight("fournisseur", "commande", "approve2");
150
+$usercanorder = $user->hasRight("fournisseur", "commande", "commander");
151 151
 if (empty($conf->reception->enabled)) {
152 152
 	$usercanreceive = $user->hasRight("fournisseur", "commande", "receptionner");
153 153
 } else {
@@ -156,8 +156,8 @@  discard block
 block discarded – undo
156 156
 
157 157
 // Permissions for includes
158 158
 $permissionnote		= $usercancreate; // Used by the include of actions_setnotes.inc.php
159
-$permissiondellink	= $usercancreate; // Used by the include of actions_dellink.inc.php
160
-$permissiontoedit	= $usercancreate; // Used by the include of actions_lineupdown.inc.php
159
+$permissiondellink = $usercancreate; // Used by the include of actions_dellink.inc.php
160
+$permissiontoedit = $usercancreate; // Used by the include of actions_lineupdown.inc.php
161 161
 $permissiontoadd	= $usercancreate; // Used by the include of actions_addupdatedelete.inc.php
162 162
 
163 163
 // Project permission
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
 }
181 181
 
182 182
 if (empty($reshook)) {
183
-	$backurlforlist = DOL_URL_ROOT.'/fourn/commande/list.php'.($socid > 0 ? '?socid='.((int) $socid)  : '');
183
+	$backurlforlist = DOL_URL_ROOT.'/fourn/commande/list.php'.($socid > 0 ? '?socid='.((int) $socid) : '');
184 184
 
185 185
 	if (empty($backtopage) || ($cancel && empty($id))) {
186 186
 		if (empty($backtopage) || ($cancel && strpos($backtopage, '__ID__'))) {
@@ -435,7 +435,7 @@  discard block
 block discarded – undo
435 435
 			$idprod = GETPOST('idprod', 'int');
436 436
 		}
437 437
 
438
-		$tva_tx = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0);		// Can be '1.2' or '1.2 (CODE)'
438
+		$tva_tx = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0); // Can be '1.2' or '1.2 (CODE)'
439 439
 
440 440
 		$price_ht = price2num(GETPOST('price_ht'), 'MU', 2);
441 441
 		$price_ht_devise = price2num(GETPOST('multicurrency_price_ht'), 'CU', 2);
@@ -553,7 +553,7 @@  discard block
 block discarded – undo
553 553
 
554 554
 				//If text set in desc is the same as product descpription (as now it's preloaded) whe add it only one time
555 555
 				if (trim($product_desc) == trim($desc) && !empty($conf->global->PRODUIT_AUTOFILL_DESC)) {
556
-					$product_desc='';
556
+					$product_desc = '';
557 557
 				}
558 558
 
559 559
 				if (!empty($product_desc) && !empty($conf->global->MAIN_NO_CONCAT_DESCRIPTION)) {
@@ -1743,7 +1743,7 @@  discard block
 block discarded – undo
1743 1743
 	// Payment term
1744 1744
 	print '<tr><td class="nowrap">'.$langs->trans('PaymentConditionsShort').'</td><td>';
1745 1745
 	print img_picto('', 'payment', 'class="pictofixedwidth"');
1746
-	print $form->getSelectConditionsPaiements((GETPOSTISSET('cond_reglement_id') &&  GETPOST('cond_reglement_id') != 0) ? GETPOST('cond_reglement_id') : $cond_reglement_id, 'cond_reglement_id', -1, 1);
1746
+	print $form->getSelectConditionsPaiements((GETPOSTISSET('cond_reglement_id') && GETPOST('cond_reglement_id') != 0) ? GETPOST('cond_reglement_id') : $cond_reglement_id, 'cond_reglement_id', -1, 1);
1747 1747
 	print '</td></tr>';
1748 1748
 
1749 1749
 	// Payment mode
@@ -1991,7 +1991,7 @@  discard block
 block discarded – undo
1991 1991
 				'morecss' => 'minwidth300'
1992 1992
 			)
1993 1993
 		);
1994
-		$formconfirm  = $form->formconfirm($_SERVER['PHP_SELF']."?id=$object->id", $langs->trans("DenyingThisOrder"), $langs->trans("ConfirmDenyingThisOrder", $object->ref), "confirm_refuse", $formquestion, 0, 1);
1994
+		$formconfirm = $form->formconfirm($_SERVER['PHP_SELF']."?id=$object->id", $langs->trans("DenyingThisOrder"), $langs->trans("ConfirmDenyingThisOrder", $object->ref), "confirm_refuse", $formquestion, 0, 1);
1995 1995
 	}
1996 1996
 
1997 1997
 	// Confirmation of cancellation
@@ -2320,40 +2320,40 @@  discard block
 block discarded – undo
2320 2320
 
2321 2321
 	print '<tr>';
2322 2322
 	// Amount HT
2323
-	print '<td class="titlefieldmiddle">' . $langs->trans('AmountHT') . '</td>';
2324
-	print '<td class="nowrap amountcard right">' . price($object->total_ht, '', $langs, 0, -1, -1, $conf->currency) . '</td>';
2323
+	print '<td class="titlefieldmiddle">'.$langs->trans('AmountHT').'</td>';
2324
+	print '<td class="nowrap amountcard right">'.price($object->total_ht, '', $langs, 0, -1, -1, $conf->currency).'</td>';
2325 2325
 	if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) {
2326 2326
 		// Multicurrency Amount HT
2327
-		print '<td class="nowrap amountcard right">' . price($object->multicurrency_total_ht, '', $langs, 0, -1, -1, $object->multicurrency_code) . '</td>';
2327
+		print '<td class="nowrap amountcard right">'.price($object->multicurrency_total_ht, '', $langs, 0, -1, -1, $object->multicurrency_code).'</td>';
2328 2328
 	}
2329 2329
 	print '</tr>';
2330 2330
 
2331 2331
 	print '<tr>';
2332 2332
 	// Amount VAT
2333
-	print '<td class="titlefieldmiddle">' . $langs->trans('AmountVAT') . '</td>';
2334
-	print '<td class="nowrap amountcard right">' . price($object->total_tva, '', $langs, 0, -1, -1, $conf->currency) . '</td>';
2333
+	print '<td class="titlefieldmiddle">'.$langs->trans('AmountVAT').'</td>';
2334
+	print '<td class="nowrap amountcard right">'.price($object->total_tva, '', $langs, 0, -1, -1, $conf->currency).'</td>';
2335 2335
 	if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) {
2336 2336
 		// Multicurrency Amount VAT
2337
-		print '<td class="nowrap amountcard right">' . price($object->multicurrency_total_tva, '', $langs, 0, -1, -1, $object->multicurrency_code) . '</td>';
2337
+		print '<td class="nowrap amountcard right">'.price($object->multicurrency_total_tva, '', $langs, 0, -1, -1, $object->multicurrency_code).'</td>';
2338 2338
 	}
2339 2339
 	print '</tr>';
2340 2340
 
2341 2341
 	// Amount Local Taxes
2342 2342
 	if ($mysoc->localtax1_assuj == "1" || $object->total_localtax1 != 0) {
2343 2343
 		print '<tr>';
2344
-		print '<td class="titlefieldmiddle">' . $langs->transcountry("AmountLT1", $mysoc->country_code) . '</td>';
2345
-		print '<td class="nowrap amountcard right">' . price($object->total_localtax1, '', $langs, 0, -1, -1, $conf->currency) . '</td>';
2344
+		print '<td class="titlefieldmiddle">'.$langs->transcountry("AmountLT1", $mysoc->country_code).'</td>';
2345
+		print '<td class="nowrap amountcard right">'.price($object->total_localtax1, '', $langs, 0, -1, -1, $conf->currency).'</td>';
2346 2346
 		if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) {
2347
-			print '<td class="nowrap amountcard right">' . price($object->total_localtax1, '', $langs, 0, -1, -1, $object->multicurrency_code) . '</td>';
2347
+			print '<td class="nowrap amountcard right">'.price($object->total_localtax1, '', $langs, 0, -1, -1, $object->multicurrency_code).'</td>';
2348 2348
 		}
2349 2349
 		print '</tr>';
2350 2350
 
2351 2351
 		if ($mysoc->localtax2_assuj == "1" || $object->total_localtax2 != 0) {
2352 2352
 			print '<tr>';
2353
-			print '<td>' . $langs->transcountry("AmountLT2", $mysoc->country_code) . '</td>';
2354
-			print '<td class="nowrap amountcard right">' . price($object->total_localtax2, '', $langs, 0, -1, -1, $conf->currency) . '</td>';
2353
+			print '<td>'.$langs->transcountry("AmountLT2", $mysoc->country_code).'</td>';
2354
+			print '<td class="nowrap amountcard right">'.price($object->total_localtax2, '', $langs, 0, -1, -1, $conf->currency).'</td>';
2355 2355
 			if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) {
2356
-				print '<td class="nowrap amountcard right">' . price($object->total_localtax2, '', $langs, 0, -1, -1, $object->multicurrency_code) . '</td>';
2356
+				print '<td class="nowrap amountcard right">'.price($object->total_localtax2, '', $langs, 0, -1, -1, $object->multicurrency_code).'</td>';
2357 2357
 			}
2358 2358
 			print '</tr>';
2359 2359
 		}
@@ -2361,16 +2361,16 @@  discard block
 block discarded – undo
2361 2361
 
2362 2362
 	$alert = '';
2363 2363
 	if (!empty($conf->global->ORDER_MANAGE_MIN_AMOUNT) && $object->total_ht < $object->thirdparty->supplier_order_min_amount) {
2364
-		$alert = ' ' . img_warning($langs->trans('OrderMinAmount') . ': ' . price($object->thirdparty->supplier_order_min_amount));
2364
+		$alert = ' '.img_warning($langs->trans('OrderMinAmount').': '.price($object->thirdparty->supplier_order_min_amount));
2365 2365
 	}
2366 2366
 
2367 2367
 	print '<tr>';
2368 2368
 	// Amount TTC
2369
-	print '<td>' . $langs->trans('AmountTTC') . '</td>';
2370
-	print '<td class="nowrap amountcard right">' . price($object->total_ttc, '', $langs, 0, -1, -1, $conf->currency) . $alert . '</td>';
2369
+	print '<td>'.$langs->trans('AmountTTC').'</td>';
2370
+	print '<td class="nowrap amountcard right">'.price($object->total_ttc, '', $langs, 0, -1, -1, $conf->currency).$alert.'</td>';
2371 2371
 	if (isModEnabled("multicurrency") && ($object->multicurrency_code && $object->multicurrency_code != $conf->currency)) {
2372 2372
 		// Multicurrency Amount TTC
2373
-		print '<td class="nowrap amountcard right">' . price($object->multicurrency_total_ttc, '', $langs, 0, -1, -1, $object->multicurrency_code) . '</td>';
2373
+		print '<td class="nowrap amountcard right">'.price($object->multicurrency_total_ttc, '', $langs, 0, -1, -1, $object->multicurrency_code).'</td>';
2374 2374
 	}
2375 2375
 	print '</tr>';
2376 2376
 
@@ -2696,7 +2696,7 @@  discard block
 block discarded – undo
2696 2696
 			$action = 'presend';
2697 2697
 		}
2698 2698
 
2699
-		if ($action != 'createorder' && $action != 'presend' ) {
2699
+		if ($action != 'createorder' && $action != 'presend') {
2700 2700
 			print '<div class="fichecenter"><div class="fichehalfleft">';
2701 2701
 
2702 2702
 			// Generated documents
Please login to merge, or discard this patch.
htdocs/supplier_proposal/list.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
 $search_date_endday = GETPOST('search_date_endday', 'int');
75 75
 $search_date_endmonth = GETPOST('search_date_endmonth', 'int');
76 76
 $search_date_endyear = GETPOST('search_date_endyear', 'int');
77
-$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear);	// Use tzserver
77
+$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear); // Use tzserver
78 78
 $search_date_end = dol_mktime(23, 59, 59, $search_date_endmonth, $search_date_endday, $search_date_endyear);
79 79
 $search_date_valid_startday = GETPOST('search_date_valid_startday', 'int');
80 80
 $search_date_valid_startmonth = GETPOST('search_date_valid_startmonth', 'int');
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
 $search_date_valid_endday = GETPOST('search_date_valid_endday', 'int');
83 83
 $search_date_valid_endmonth = GETPOST('search_date_valid_endmonth', 'int');
84 84
 $search_date_valid_endyear = GETPOST('search_date_valid_endyear', 'int');
85
-$search_date_valid_start = dol_mktime(0, 0, 0, $search_date_valid_startmonth, $search_date_valid_startday, $search_date_valid_startyear);	// Use tzserver
85
+$search_date_valid_start = dol_mktime(0, 0, 0, $search_date_valid_startmonth, $search_date_valid_startday, $search_date_valid_startyear); // Use tzserver
86 86
 $search_date_valid_end = dol_mktime(23, 59, 59, $search_date_valid_endmonth, $search_date_valid_endday, $search_date_valid_endyear);
87 87
 $search_type_thirdparty = GETPOST("search_type_thirdparty", 'int');
88 88
 $search_montant_ht = GETPOST('search_montant_ht', 'alpha');
@@ -442,7 +442,7 @@  discard block
 block discarded – undo
442 442
 			if ($searchCategoryProductOperator == 0) {
443 443
 				$searchCategoryProductSqlList[] = " EXISTS (SELECT ck.fk_product FROM ".MAIN_DB_PREFIX."categorie_product as ck, ".MAIN_DB_PREFIX."supplier_proposaldet as sd WHERE sd.fk_supplier_proposal = sp.rowid AND sd.fk_product = ck.fk_product AND ck.fk_categorie = ".((int) $searchCategoryProduct).")";
444 444
 			} else {
445
-				$listofcategoryid .= ($listofcategoryid ? ', ' : '') .((int) $searchCategoryProduct);
445
+				$listofcategoryid .= ($listofcategoryid ? ', ' : '').((int) $searchCategoryProduct);
446 446
 			}
447 447
 		}
448 448
 	}
Please login to merge, or discard this patch.
htdocs/ecm/dir_add_card.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
  *	\brief		Main page for ECM section area
24 24
  */
25 25
 
26
-if (! defined('DISABLE_JS_GRAHP')) define('DISABLE_JS_GRAPH', 1);
26
+if (!defined('DISABLE_JS_GRAHP')) define('DISABLE_JS_GRAPH', 1);
27 27
 
28 28
 // Load Dolibarr environment
29 29
 require '../main.inc.php';
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,9 @@
 block discarded – undo
23 23
  *	\brief		Main page for ECM section area
24 24
  */
25 25
 
26
-if (! defined('DISABLE_JS_GRAHP')) define('DISABLE_JS_GRAPH', 1);
26
+if (! defined('DISABLE_JS_GRAHP')) {
27
+	define('DISABLE_JS_GRAPH', 1);
28
+}
27 29
 
28 30
 // Load Dolibarr environment
29 31
 require '../main.inc.php';
Please login to merge, or discard this patch.