Completed
Branch develop (68d67a)
by
unknown
16:20
created
htdocs/partnership/partnership_note.php 1 patch
Braces   +12 added lines, -4 removed lines patch added patch discarded remove patch
@@ -66,10 +66,18 @@
 block discarded – undo
66 66
 //if ($user->socid > 0) accessforbidden();
67 67
 //if ($user->socid > 0) $socid = $user->socid;
68 68
 //$result = restrictedArea($user, 'partnership', $object->id);
69
-if (empty($conf->partnership->enabled)) accessforbidden();
70
-if (empty($permissiontoread)) accessforbidden();
71
-if ($object->id > 0 && !($object->fk_member > 0) && $managedfor == 'member') accessforbidden();
72
-if ($object->id > 0 && !($object->fk_soc > 0) && $managedfor == 'thirdparty') accessforbidden();
69
+if (empty($conf->partnership->enabled)) {
70
+	accessforbidden();
71
+}
72
+if (empty($permissiontoread)) {
73
+	accessforbidden();
74
+}
75
+if ($object->id > 0 && !($object->fk_member > 0) && $managedfor == 'member') {
76
+	accessforbidden();
77
+}
78
+if ($object->id > 0 && !($object->fk_soc > 0) && $managedfor == 'thirdparty') {
79
+	accessforbidden();
80
+}
73 81
 
74 82
 
75 83
 /*
Please login to merge, or discard this patch.
htdocs/partnership/class/partnershiputils.class.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
 	public $error; //!< To return error code (or message)
42 42
 	public $errors = array(); //!< To return several error codes (or messages)
43 43
 
44
-	public $output;	// To store output of some cron methods
44
+	public $output; // To store output of some cron methods
45 45
 
46 46
 
47 47
 	/**
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
 	{
67 67
 		global $conf, $langs, $user;
68 68
 
69
-		$managedfor	= getDolGlobalString('PARTNERSHIP_IS_MANAGED_FOR', 'thirdparty');
69
+		$managedfor = getDolGlobalString('PARTNERSHIP_IS_MANAGED_FOR', 'thirdparty');
70 70
 
71 71
 		if ($managedfor != 'member') {
72 72
 			return 0; // If option 'PARTNERSHIP_IS_MANAGED_FOR' = 'thirdparty', this cron job does nothing.
Please login to merge, or discard this patch.
Braces   +38 added lines, -13 removed lines patch added patch discarded remove patch
@@ -118,7 +118,9 @@  discard block
 block discarded – undo
118 118
 
119 119
 				$obj = $this->db->fetch_object($resql);
120 120
 				if ($obj) {
121
-					if (!empty($partnershipsprocessed[$obj->rowid])) continue;
121
+					if (!empty($partnershipsprocessed[$obj->rowid])) {
122
+						continue;
123
+					}
122 124
 
123 125
 					if ($somethingdoneonpartnership >= $MAXPERCALL) {
124 126
 						dol_syslog("We reach the limit of ".$MAXPERCALL." partnership processed, so we quit loop for this batch doCancelStatusOfMemberPartnership to avoid to reach email quota.", LOG_WARNING);
@@ -140,8 +142,11 @@  discard block
 block discarded – undo
140 142
 							$error++;
141 143
 							$this->error = $object->error;
142 144
 							if (is_array($object->errors) && count($object->errors)) {
143
-								if (is_array($this->errors)) $this->errors = array_merge($this->errors, $object->errors);
144
-								else $this->errors = $object->errors;
145
+								if (is_array($this->errors)) {
146
+									$this->errors = array_merge($this->errors, $object->errors);
147
+								} else {
148
+									$this->errors = $object->errors;
149
+								}
145 150
 							}
146 151
 						} else {
147 152
 							$partnershipsprocessed[$object->id] = $object->ref;
@@ -159,7 +164,9 @@  discard block
 block discarded – undo
159 164
 							// Define output language
160 165
 							$outputlangs = $langs;
161 166
 							$newlang = '';
162
-							if (getDolGlobalInt('MAIN_MULTILANGS') && empty($newlang) && GETPOST('lang_id', 'aZ09')) $newlang = GETPOST('lang_id', 'aZ09');
167
+							if (getDolGlobalInt('MAIN_MULTILANGS') && empty($newlang) && GETPOST('lang_id', 'aZ09')) {
168
+								$newlang = GETPOST('lang_id', 'aZ09');
169
+							}
163 170
 							if (!empty($newlang)) {
164 171
 								$outputlangs = new Translate("", $conf);
165 172
 								$outputlangs->setDefaultLang($newlang);
@@ -184,7 +191,9 @@  discard block
 block discarded – undo
184 191
 							if (!$result || $cmail->error) {
185 192
 								$erroremail .= ($erroremail ? ', ' : '').$cmail->error;
186 193
 								$this->errors[] = $cmail->error;
187
-								if (is_array($cmail->errors) && count($cmail->errors) > 0) $this->errors += $cmail->errors;
194
+								if (is_array($cmail->errors) && count($cmail->errors) > 0) {
195
+									$this->errors += $cmail->errors;
196
+								}
188 197
 							}
189 198
 						}
190 199
 					}
@@ -198,12 +207,16 @@  discard block
 block discarded – undo
198 207
 		if (!$error) {
199 208
 			$this->db->commit();
200 209
 			$this->output = $numofexpiredmembers.' expired partnership members found'."\n";
201
-			if ($erroremail) $this->output .= '. Got errors when sending some email : '.$erroremail;
210
+			if ($erroremail) {
211
+				$this->output .= '. Got errors when sending some email : '.$erroremail;
212
+			}
202 213
 		} else {
203 214
 			$this->db->rollback();
204 215
 			$this->output = "Rollback after error\n";
205 216
 			$this->output .= $numofexpiredmembers.' expired partnership members found'."\n";
206
-			if ($erroremail) $this->output .= '. Got errors when sending some email : '.$erroremail;
217
+			if ($erroremail) {
218
+				$this->output .= '. Got errors when sending some email : '.$erroremail;
219
+			}
207 220
 		}
208 221
 
209 222
 		return ($error ? 1 : 0);
@@ -276,7 +289,9 @@  discard block
 block discarded – undo
276 289
 
277 290
 				$obj = $this->db->fetch_object($resql);
278 291
 				if ($obj) {
279
-					if (!empty($partnershipsprocessed[$obj->rowid])) continue;
292
+					if (!empty($partnershipsprocessed[$obj->rowid])) {
293
+						continue;
294
+					}
280 295
 
281 296
 					if ($somethingdoneonpartnership >= $MAXPERCALL) {
282 297
 						dol_syslog("We reach the limit of ".$MAXPERCALL." partnership processed, so we quit loop for this batch doWarningOfPartnershipIfDolibarrBacklinkNotfound to avoid to reach email quota.", LOG_WARNING);
@@ -321,7 +336,9 @@  discard block
 block discarded – undo
321 336
 								// Define output language
322 337
 								$outputlangs = $langs;
323 338
 								$newlang = '';
324
-								if (getDolGlobalInt('MAIN_MULTILANGS') && empty($newlang) && GETPOST('lang_id', 'aZ09')) $newlang = GETPOST('lang_id', 'aZ09');
339
+								if (getDolGlobalInt('MAIN_MULTILANGS') && empty($newlang) && GETPOST('lang_id', 'aZ09')) {
340
+									$newlang = GETPOST('lang_id', 'aZ09');
341
+								}
325 342
 								if (!empty($newlang)) {
326 343
 									$outputlangs = new Translate("", $conf);
327 344
 									$outputlangs->setDefaultLang($newlang);
@@ -344,7 +361,9 @@  discard block
 block discarded – undo
344 361
 								if (!$result || $cmail->error) {
345 362
 									$erroremail .= ($erroremail ? ', ' : '').$cmail->error;
346 363
 									$this->errors[] = $cmail->error;
347
-									if (is_array($cmail->errors) && count($cmail->errors) > 0) $this->errors += $cmail->errors;
364
+									if (is_array($cmail->errors) && count($cmail->errors) > 0) {
365
+										$this->errors += $cmail->errors;
366
+									}
348 367
 								}
349 368
 							}
350 369
 						} elseif ($tmpcount > 4) { // Cancel Partnership
@@ -378,9 +397,15 @@  discard block
 block discarded – undo
378 397
 			$this->output = "Rollback after error\n";
379 398
 		}
380 399
 		$this->output .= $numofexpiredmembers.' partnership checked'."\n";
381
-		if ($erroremail) $this->output .= '. Got errors when sending some email : '.$erroremail."\n";
382
-		if ($emailnotfound) $this->output .= '. Email not found for some partner : '.$emailnotfound."\n";
383
-		if ($websitenotfound) $this->output .= '. Website not found for some partner : '.$websitenotfound."\n";
400
+		if ($erroremail) {
401
+			$this->output .= '. Got errors when sending some email : '.$erroremail."\n";
402
+		}
403
+		if ($emailnotfound) {
404
+			$this->output .= '. Email not found for some partner : '.$emailnotfound."\n";
405
+		}
406
+		if ($websitenotfound) {
407
+			$this->output .= '. Website not found for some partner : '.$websitenotfound."\n";
408
+		}
384 409
 		$this->output .= "\nSQL used to find partnerships to scan: ".$sql;
385 410
 
386 411
 		return ($error ? 1 : 0);
Please login to merge, or discard this patch.
htdocs/expedition/list.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
 
216 216
 // If massaction is close
217 217
 if ($massaction == 'classifyclose') {
218
-	$error=0;
218
+	$error = 0;
219 219
 	$selectids = GETPOST('toselect', 'array');
220 220
 	foreach ($selectids as $selectid) {
221 221
 		//	$object->fetch($selectid);
@@ -420,7 +420,7 @@  discard block
 block discarded – undo
420 420
 			if ($searchCategoryProductOperator == 0) {
421 421
 				$searchCategoryProductSqlList[] = " EXISTS (SELECT ck.fk_product FROM ".MAIN_DB_PREFIX."categorie_product as ck, ".MAIN_DB_PREFIX."expeditiondet as ed, ".MAIN_DB_PREFIX."commandedet as cd WHERE ed.fk_expedition = e.rowid AND ed.fk_origin_line = cd.rowid AND cd.fk_product = ck.fk_product AND ck.fk_categorie = ".((int) $searchCategoryProduct).")";
422 422
 			} else {
423
-				$listofcategoryid .= ($listofcategoryid ? ', ' : '') .((int) $searchCategoryProduct);
423
+				$listofcategoryid .= ($listofcategoryid ? ', ' : '').((int) $searchCategoryProduct);
424 424
 			}
425 425
 		}
426 426
 	}
@@ -535,7 +535,7 @@  discard block
 block discarded – undo
535 535
 if ($search_type_thirdparty != '' && $search_type_thirdparty > 0) {
536 536
 	$param .= '&search_type_thirdparty='.urlencode($search_type_thirdparty);
537 537
 }
538
-if ($search_datedelivery_start)	{
538
+if ($search_datedelivery_start) {
539 539
 	$param .= '&search_datedelivery_startday='.urlencode(dol_print_date($search_datedelivery_start, '%d')).'&search_datedelivery_startmonth='.urlencode(dol_print_date($search_datedelivery_start, '%m')).'&search_datedelivery_startyear='.urlencode(dol_print_date($search_datedelivery_start, '%Y'));
540 540
 }
541 541
 if ($search_datedelivery_end) {
@@ -891,7 +891,7 @@  discard block
 block discarded – undo
891 891
 
892 892
 	$shipment->id = $obj->rowid;
893 893
 	$shipment->ref = $obj->ref;
894
-	$shipment->shipping_method_id=$obj->fk_shipping_method;
894
+	$shipment->shipping_method_id = $obj->fk_shipping_method;
895 895
 
896 896
 	$companystatic->id = $obj->socid;
897 897
 	$companystatic->ref = $obj->name;
@@ -1027,7 +1027,7 @@  discard block
 block discarded – undo
1027 1027
 		}
1028 1028
 		if (!empty($arrayfields['e.fk_shipping_method']['checked'])) {
1029 1029
 			// Get code using getLabelFromKey
1030
-			$code=$langs->getLabelFromKey($db, $shipment->shipping_method_id, 'c_shipment_mode', 'rowid', 'code');
1030
+			$code = $langs->getLabelFromKey($db, $shipment->shipping_method_id, 'c_shipment_mode', 'rowid', 'code');
1031 1031
 			print '<td class="center tdoverflowmax150" title="'.dol_escape_htmltag($langs->trans("SendingMethod".strtoupper($code))).'">';
1032 1032
 			if ($shipment->shipping_method_id > 0) print $langs->trans("SendingMethod".strtoupper($code));
1033 1033
 			print '</td>';
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1032,7 +1032,9 @@
 block discarded – undo
1032 1032
 			// Get code using getLabelFromKey
1033 1033
 			$code=$langs->getLabelFromKey($db, $shipment->shipping_method_id, 'c_shipment_mode', 'rowid', 'code');
1034 1034
 			print '<td class="center tdoverflowmax150" title="'.dol_escape_htmltag($langs->trans("SendingMethod".strtoupper($code))).'">';
1035
-			if ($shipment->shipping_method_id > 0) print $langs->trans("SendingMethod".strtoupper($code));
1035
+			if ($shipment->shipping_method_id > 0) {
1036
+				print $langs->trans("SendingMethod".strtoupper($code));
1037
+			}
1036 1038
 			print '</td>';
1037 1039
 			if (!$i) {
1038 1040
 				$totalarray['nbfield']++;
Please login to merge, or discard this patch.
htdocs/expedition/class/expeditionlinebatch.class.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@
 block discarded – undo
44 44
 	public $qty;
45 45
 	public $dluo_qty; // deprecated, use qty
46 46
 	public $entrepot_id;
47
-	public $fk_origin_stock;		// rowid in llx_product_batch table
47
+	public $fk_origin_stock; // rowid in llx_product_batch table
48 48
 	public $fk_expeditiondet;
49 49
 
50 50
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -112,7 +112,9 @@
 block discarded – undo
112 112
 		global $user;
113 113
 
114 114
 		$error = 0;
115
-		if (!is_object($f_user)) $f_user = $user;
115
+		if (!is_object($f_user)) {
116
+			$f_user = $user;
117
+		}
116 118
 
117 119
 		$id_line_expdet = (int) $id_line_expdet;
118 120
 
Please login to merge, or discard this patch.
htdocs/debugbar/class/DataCollector/DolPhpCollector.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
 	{
61 61
 		$messages = $this->messages;
62 62
 
63
-		usort($messages, function ($itemA, $itemB) {
63
+		usort($messages, function($itemA, $itemB) {
64 64
 			if ($itemA['time'] === $itemB['time']) {
65 65
 				return 0;
66 66
 			}
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
 			if ($type = $severity & (2 ** $i)) {
120 120
 				$label = $this->friendlyErrorType($type);
121 121
 				$this->messages[] = [
122
-					'message' => $message . ' (' . $fileName . ':' . $line . ')',
122
+					'message' => $message.' ('.$fileName.':'.$line.')',
123 123
 					'message_html' => null,
124 124
 					'is_string' => true,
125 125
 					'label' => $label,
Please login to merge, or discard this patch.
modules/recruitment/doc/doc_generic_recruitmentjobposition_odt.modules.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -289,7 +289,7 @@
 block discarded – undo
289 289
 				dol_mkdir($conf->recruitment->dir_temp);
290 290
 				if (!is_writable($conf->recruitment->dir_temp)) {
291 291
 					$this->error = $langs->transnoentities("ErrorFailedToWriteInTempDirectory", $conf->recruitment->dir_temp);
292
-					dol_syslog('Error in write_file: ' . $this->error, LOG_ERR);
292
+					dol_syslog('Error in write_file: '.$this->error, LOG_ERR);
293 293
 					return -1;
294 294
 				}
295 295
 
Please login to merge, or discard this patch.
htdocs/hrm/evaluation_card.php 2 patches
Spacing   +34 added lines, -34 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 
41 41
 
42 42
 // Load translation files required by the page
43
-$langs->loadLangs(array('hrm', 'other', 'products'));  // why products?
43
+$langs->loadLangs(array('hrm', 'other', 'products')); // why products?
44 44
 
45 45
 // Get parameters
46 46
 $id = GETPOST('id', 'int');
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
 $contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'evaluationcard'; // To manage different context of search
52 52
 $backtopage = GETPOST('backtopage', 'alpha');
53 53
 $backtopageforcancel = GETPOST('backtopageforcancel', 'alpha');
54
-$lineid   = GETPOST('lineid', 'int');
54
+$lineid = GETPOST('lineid', 'int');
55 55
 
56 56
 // Initialize technical objects
57 57
 $object = new Evaluation($db);
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
 	if ($action == 'close') {
170 170
 		// save evaldet lines to user;
171 171
 		$sk = new SkillRank($db);
172
-		$SkillrecordsForActiveUser = $sk->fetchAll('ASC', 'fk_skill', 0, 0, array("customsql"=>"fk_object = ".$object->fk_user ." AND objecttype ='".SkillRank::SKILLRANK_TYPE_USER."'"), 'AND');
172
+		$SkillrecordsForActiveUser = $sk->fetchAll('ASC', 'fk_skill', 0, 0, array("customsql"=>"fk_object = ".$object->fk_user." AND objecttype ='".SkillRank::SKILLRANK_TYPE_USER."'"), 'AND');
173 173
 
174 174
 		$errors = 0;
175 175
 		// we go through the evaldets of the eval
@@ -212,7 +212,7 @@  discard block
 block discarded – undo
212 212
 		}
213 213
 	}
214 214
 
215
-	if ($action == 'reopen' ) {
215
+	if ($action == 'reopen') {
216 216
 		// no update here we just change the evaluation status
217 217
 		$object->setStatut(Evaluation::STATUS_VALIDATED);
218 218
 	}
@@ -259,7 +259,7 @@  discard block
 block discarded – undo
259 259
 
260 260
 // Part to create
261 261
 if ($action == 'create') {
262
-	print load_fiche_titre($langs->trans("NewEval"), '', 'object_' . $object->picto);
262
+	print load_fiche_titre($langs->trans("NewEval"), '', 'object_'.$object->picto);
263 263
 
264 264
 	print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
265 265
 	print '<input type="hidden" name="token" value="'.newToken().'">';
@@ -423,9 +423,9 @@  discard block
 block discarded – undo
423 423
 	print '<div class="underbanner clearboth"></div>';
424 424
 	print '<table class="border centpercent tableforfield">'."\n";
425 425
 
426
-	$object->fields['label']['visible']=0; // Already in banner
427
-	$object->fields['fk_user']['visible']=0; // Already in banner
428
-	$object->fields['fk_job']['visible']=0; // Already in banner
426
+	$object->fields['label']['visible'] = 0; // Already in banner
427
+	$object->fields['fk_user']['visible'] = 0; // Already in banner
428
+	$object->fields['fk_job']['visible'] = 0; // Already in banner
429 429
 	include DOL_DOCUMENT_ROOT.'/core/tpl/commonfields_view.tpl.php';
430 430
 
431 431
 	// Other attributes. Fields from hook formObjectOptions and Extrafields.
@@ -465,7 +465,7 @@  discard block
 block discarded – undo
465 465
 			include DOL_DOCUMENT_ROOT.'/core/tpl/ajaxrow.tpl.php';
466 466
 		}
467 467
 
468
-		$conf->modules_parts['tpl']['hrm']='/hrm/core/tpl/'; // Pour utilisation du tpl hrm sur cet écran
468
+		$conf->modules_parts['tpl']['hrm'] = '/hrm/core/tpl/'; // Pour utilisation du tpl hrm sur cet écran
469 469
 
470 470
 		print '<div class="div-table-responsive-no-min">';
471 471
 		if (!empty($object->lines) || ($object->status == $object::STATUS_DRAFT && $permissiontoadd && $action != 'selectlines' && $action != 'editline')) {
@@ -521,14 +521,14 @@  discard block
 block discarded – undo
521 521
 		$sql .= '  skdet_user.description as "userRankForSkillDesc",';
522 522
 		$sql .= '  skdet_required.description as "required_rank_desc"';
523 523
 
524
-		$sql .= '  FROM ' . MAIN_DB_PREFIX . 'hrm_evaluation as e';
525
-		$sql .= '  LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_evaluationdet as ed ON  e.rowid = ed.fk_evaluation';
526
-		$sql .= '  LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_job as j ON e.fk_job = j.rowid';
527
-		$sql .= '  LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_skill as sk ON ed.fk_skill = sk.rowid';
528
-		$sql .= '  INNER JOIN ' . MAIN_DB_PREFIX . 'hrm_skilldet as skdet_user ON (skdet_user.fk_skill = sk.rowid AND skdet_user.rankorder = ed.rankorder)';
524
+		$sql .= '  FROM '.MAIN_DB_PREFIX.'hrm_evaluation as e';
525
+		$sql .= '  LEFT JOIN '.MAIN_DB_PREFIX.'hrm_evaluationdet as ed ON  e.rowid = ed.fk_evaluation';
526
+		$sql .= '  LEFT JOIN '.MAIN_DB_PREFIX.'hrm_job as j ON e.fk_job = j.rowid';
527
+		$sql .= '  LEFT JOIN '.MAIN_DB_PREFIX.'hrm_skill as sk ON ed.fk_skill = sk.rowid';
528
+		$sql .= '  INNER JOIN '.MAIN_DB_PREFIX.'hrm_skilldet as skdet_user ON (skdet_user.fk_skill = sk.rowid AND skdet_user.rankorder = ed.rankorder)';
529 529
 		//$sql .= "  LEFT JOIN " . MAIN_DB_PREFIX . "hrm_skillrank as skr ON (j.rowid = skr.fk_object AND skr.fk_skill = ed.fk_skill AND skr.objecttype = 'job')";
530
-		$sql .= '  LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_skilldet as skdet_required ON (skdet_required.fk_skill = sk.rowid AND skdet_required.rankorder = ed.required_rank)';
531
-		$sql .= " WHERE e.rowid =" . ((int) $object->id);
530
+		$sql .= '  LEFT JOIN '.MAIN_DB_PREFIX.'hrm_skilldet as skdet_required ON (skdet_required.fk_skill = sk.rowid AND skdet_required.rankorder = ed.required_rank)';
531
+		$sql .= " WHERE e.rowid =".((int) $object->id);
532 532
 
533 533
 		//      echo $sql;
534 534
 
@@ -544,21 +544,21 @@  discard block
 block discarded – undo
544 544
 				$Tab[$num]->skill_id = $obj->fk_skill;
545 545
 				$Tab[$num]->skilllabel = $obj->skilllabel;
546 546
 				$Tab[$num]->description = $obj->description;
547
-				$Tab[$num]->userRankForSkill = '<span title="'.$obj->userRankForSkillDesc.'" class="radio_js_bloc_number TNote_1">' . $obj->userRankForSkill . '</span>';
548
-				$Tab[$num]->required_rank = '<span title="'.$obj->required_rank_desc.'" class="radio_js_bloc_number TNote_1">' . $obj->required_rank . '</span>';
547
+				$Tab[$num]->userRankForSkill = '<span title="'.$obj->userRankForSkillDesc.'" class="radio_js_bloc_number TNote_1">'.$obj->userRankForSkill.'</span>';
548
+				$Tab[$num]->required_rank = '<span title="'.$obj->required_rank_desc.'" class="radio_js_bloc_number TNote_1">'.$obj->required_rank.'</span>';
549 549
 
550 550
 				if ($obj->userRankForSkill > $obj->required_rank) {
551
-					$title=$langs->trans('MaxlevelGreaterThanShort');
551
+					$title = $langs->trans('MaxlevelGreaterThanShort');
552 552
 					$class .= 'veryhappy diffnote';
553 553
 				} elseif ($obj->userRankForSkill == $obj->required_rank) {
554
-					$title=$langs->trans('MaxLevelEqualToShort');
554
+					$title = $langs->trans('MaxLevelEqualToShort');
555 555
 					$class .= 'happy diffnote';
556 556
 				} elseif ($obj->userRankForSkill < $obj->required_rank) {
557
-					$title=$langs->trans('MaxLevelLowerThanShort');
557
+					$title = $langs->trans('MaxLevelLowerThanShort');
558 558
 					$class .= 'sad';
559 559
 				}
560 560
 
561
-				$Tab[$num]->result = '<span title="'.$title.'" class="classfortooltip ' . $class . ' note">&nbsp;</span>';
561
+				$Tab[$num]->result = '<span title="'.$title.'" class="classfortooltip '.$class.' note">&nbsp;</span>';
562 562
 
563 563
 				$num++;
564 564
 			}
@@ -567,24 +567,24 @@  discard block
 block discarded – undo
567 567
 			print '<table class="noborder centpercent">';
568 568
 
569 569
 			print '<tr class="liste_titre">';
570
-			print '<th style="width:auto;text-align:auto" class="liste_titre">' . $langs->trans("TypeSkill") . ' </th>';
571
-			print '<th style="width:auto;text-align:auto" class="liste_titre">' . $langs->trans("Label") . '</th>';
572
-			print '<th style="width:auto;text-align:auto" class="liste_titre">' . $langs->trans("Description") . '</th>';
573
-			print '<th style="width:auto;text-align:center" class="liste_titre">' . $langs->trans("EmployeeRank") . '</th>';
574
-			print '<th style="width:auto;text-align:center" class="liste_titre">' . $langs->trans("RequiredRank") . '</th>';
575
-			print '<th style="width:auto;text-align:auto" class="liste_titre">' . $langs->trans("Result") . ' ' .$form->textwithpicto('', GetLegendSkills(), 1) .'</th>';
570
+			print '<th style="width:auto;text-align:auto" class="liste_titre">'.$langs->trans("TypeSkill").' </th>';
571
+			print '<th style="width:auto;text-align:auto" class="liste_titre">'.$langs->trans("Label").'</th>';
572
+			print '<th style="width:auto;text-align:auto" class="liste_titre">'.$langs->trans("Description").'</th>';
573
+			print '<th style="width:auto;text-align:center" class="liste_titre">'.$langs->trans("EmployeeRank").'</th>';
574
+			print '<th style="width:auto;text-align:center" class="liste_titre">'.$langs->trans("RequiredRank").'</th>';
575
+			print '<th style="width:auto;text-align:auto" class="liste_titre">'.$langs->trans("Result").' '.$form->textwithpicto('', GetLegendSkills(), 1).'</th>';
576 576
 			print '</tr>';
577 577
 
578 578
 			$sk = new Skill($db);
579 579
 			foreach ($Tab as $t) {
580 580
 				$sk->fetch($t->skill_id);
581 581
 				print '<tr>';
582
-				print ' <td>' . Skill::typeCodeToLabel($t->skill_type) . '</td>';
583
-				print ' <td>' . $sk->getNomUrl(1) . '</td>';
584
-				print ' <td>' . $t->description . '</td>';
585
-				print ' <td align="center">' . $t->userRankForSkill . '</td>';
586
-				print ' <td align="center">' . $t->required_rank . '</td>';
587
-				print ' <td>' . $t->result . '</td>';
582
+				print ' <td>'.Skill::typeCodeToLabel($t->skill_type).'</td>';
583
+				print ' <td>'.$sk->getNomUrl(1).'</td>';
584
+				print ' <td>'.$t->description.'</td>';
585
+				print ' <td align="center">'.$t->userRankForSkill.'</td>';
586
+				print ' <td align="center">'.$t->required_rank.'</td>';
587
+				print ' <td>'.$t->result.'</td>';
588 588
 				print '</tr>';
589 589
 			}
590 590
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -97,7 +97,9 @@
 block discarded – undo
97 97
 if (!isModEnabled("hrm")) {
98 98
 	accessforbidden();
99 99
 }
100
-if (!$permissiontoread || ($action === 'create' && !$permissiontoadd)) accessforbidden();
100
+if (!$permissiontoread || ($action === 'create' && !$permissiontoadd)) {
101
+	accessforbidden();
102
+}
101 103
 
102 104
 
103 105
 /*
Please login to merge, or discard this patch.
htdocs/hrm/evaluation_note.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -28,9 +28,9 @@  discard block
 block discarded – undo
28 28
 // Load Dolibarr environment
29 29
 require '../main.inc.php';
30 30
 
31
-require_once DOL_DOCUMENT_ROOT . '/hrm/class/evaluation.class.php';
32
-require_once DOL_DOCUMENT_ROOT . '/hrm/class/job.class.php';
33
-require_once DOL_DOCUMENT_ROOT . '/hrm/lib/hrm_evaluation.lib.php';
31
+require_once DOL_DOCUMENT_ROOT.'/hrm/class/evaluation.class.php';
32
+require_once DOL_DOCUMENT_ROOT.'/hrm/class/job.class.php';
33
+require_once DOL_DOCUMENT_ROOT.'/hrm/lib/hrm_evaluation.lib.php';
34 34
 
35 35
 
36 36
 // Load translation files required by the page
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
 
62 62
 // Permissions
63 63
 $permissionnote   = $user->rights->hrm->evaluation->write; // Used by the include of actions_setnotes.inc.php
64
-$permissiontoread = $user->rights->hrm->evaluation->read;  // Used by the include of actions_addupdatedelete.inc.php
64
+$permissiontoread = $user->rights->hrm->evaluation->read; // Used by the include of actions_addupdatedelete.inc.php
65 65
 
66 66
 // Security check (enable the most restrictive one)
67 67
 //if ($user->socid > 0) accessforbidden();
Please login to merge, or discard this patch.
htdocs/hrm/skill_tab.php 2 patches
Braces   +21 added lines, -7 removed lines patch added patch discarded remove patch
@@ -78,9 +78,15 @@  discard block
 block discarded – undo
78 78
 $permissiontoadd  = $user->hasRight('hrm', 'all', 'write'); // Used by the include of actions_addupdatedelete.inc.php and actions_lineupdown.inc.php
79 79
 
80 80
 // Security check (enable the most restrictive one)
81
-if ($user->socid > 0) accessforbidden();
82
-if (empty($conf->hrm->enabled)) accessforbidden();
83
-if (!$permissiontoread) accessforbidden();
81
+if ($user->socid > 0) {
82
+	accessforbidden();
83
+}
84
+if (empty($conf->hrm->enabled)) {
85
+	accessforbidden();
86
+}
87
+if (!$permissiontoread) {
88
+	accessforbidden();
89
+}
84 90
 
85 91
 
86 92
 /*
@@ -123,10 +129,14 @@  discard block
 block discarded – undo
123 129
 				$skillAdded->fk_object = $id;
124 130
 				$skillAdded->objecttype = $objecttype;
125 131
 				$ret = $skillAdded->create($user);
126
-				if ($ret < 0) setEventMessages($skillAdded->error, null, 'errors');
132
+				if ($ret < 0) {
133
+					setEventMessages($skillAdded->error, null, 'errors');
134
+				}
127 135
 				//else unset($TSkillsToAdd);
128 136
 			}
129
-			if ($ret > 0) setEventMessages($langs->trans("SaveAddSkill"), null);
137
+			if ($ret > 0) {
138
+				setEventMessages($langs->trans("SaveAddSkill"), null);
139
+			}
130 140
 		}
131 141
 	} elseif ($action == 'saveSkill') {
132 142
 		if (!empty($TNote)) {
@@ -383,9 +393,13 @@  discard block
 block discarded – undo
383 393
 	}
384 394
 
385 395
 	print '</table>';
386
-	if ($objecttype != 'user' && $permissiontoadd) print '<td><input class="button pull-right" type="submit" value="' . $langs->trans('SaveRank') . '"></td>';
396
+	if ($objecttype != 'user' && $permissiontoadd) {
397
+		print '<td><input class="button pull-right" type="submit" value="' . $langs->trans('SaveRank') . '"></td>';
398
+	}
387 399
 	print '</div>';
388
-	if ($objecttype != 'user' && $permissiontoadd) print '</form>';
400
+	if ($objecttype != 'user' && $permissiontoadd) {
401
+		print '</form>';
402
+	}
389 403
 
390 404
 
391 405
 	// liste des compétences liées
Please login to merge, or discard this patch.
Spacing   +38 added lines, -38 removed lines patch added patch discarded remove patch
@@ -29,14 +29,14 @@  discard block
 block discarded – undo
29 29
 // Load Dolibarr environment
30 30
 require '../main.inc.php';
31 31
 
32
-require_once DOL_DOCUMENT_ROOT . '/core/class/html.formcompany.class.php';
33
-require_once DOL_DOCUMENT_ROOT . '/core/class/html.formfile.class.php';
34
-require_once DOL_DOCUMENT_ROOT . '/core/class/html.formprojet.class.php';
35
-require_once DOL_DOCUMENT_ROOT . '/user/class/user.class.php';
36
-require_once DOL_DOCUMENT_ROOT . '/hrm/class/job.class.php';
37
-require_once DOL_DOCUMENT_ROOT . '/hrm/class/skill.class.php';
38
-require_once DOL_DOCUMENT_ROOT . '/hrm/class/skillrank.class.php';
39
-require_once DOL_DOCUMENT_ROOT . '/hrm/lib/hrm_skill.lib.php';
32
+require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php';
33
+require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php';
34
+require_once DOL_DOCUMENT_ROOT.'/core/class/html.formprojet.class.php';
35
+require_once DOL_DOCUMENT_ROOT.'/user/class/user.class.php';
36
+require_once DOL_DOCUMENT_ROOT.'/hrm/class/job.class.php';
37
+require_once DOL_DOCUMENT_ROOT.'/hrm/class/skill.class.php';
38
+require_once DOL_DOCUMENT_ROOT.'/hrm/class/skillrank.class.php';
39
+require_once DOL_DOCUMENT_ROOT.'/hrm/lib/hrm_skill.lib.php';
40 40
 
41 41
 // Load translation files required by the page
42 42
 $langs->loadLangs(array('hrm', 'other'));
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
 $hookmanager->initHooks(array('skilltab', 'globalcard')); // Note that conf->hooks_modules contains array
72 72
 
73 73
 // Load object
74
-include DOL_DOCUMENT_ROOT . '/core/actions_fetchobject.inc.php'; // Must be include, not include_once.
74
+include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once.
75 75
 
76 76
 // Permissions
77 77
 $permissiontoread = $user->hasRight('hrm', 'all', 'read');
@@ -103,7 +103,7 @@  discard block
 block discarded – undo
103 103
 			if (empty($id) && (($action != 'add' && $action != 'create') || $cancel)) {
104 104
 				$backtopage = $backurlforlist;
105 105
 			} else {
106
-				$backtopage = DOL_URL_ROOT.'/hrm/skill_list.php?id=' . ($id > 0 ? $id : '__ID__');
106
+				$backtopage = DOL_URL_ROOT.'/hrm/skill_list.php?id='.($id > 0 ? $id : '__ID__');
107 107
 			}
108 108
 		}
109 109
 	}
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
 	} elseif ($action == 'saveSkill') {
132 132
 		if (!empty($TNote)) {
133 133
 			foreach ($TNote as $skillId => $rank) {
134
-				$TSkills = $skill->fetchAll('ASC', 't.rowid', 0, 0, array('customsql' => 'fk_object=' . ((int) $id) . " AND objecttype='" . $db->escape($objecttype) . "' AND fk_skill = " . ((int) $skillId)));
134
+				$TSkills = $skill->fetchAll('ASC', 't.rowid', 0, 0, array('customsql' => 'fk_object='.((int) $id)." AND objecttype='".$db->escape($objecttype)."' AND fk_skill = ".((int) $skillId)));
135 135
 				if (is_array($TSkills) && !empty($TSkills)) {
136 136
 					foreach ($TSkills as $tmpObj) {
137 137
 						$tmpObj->rankorder = $rank;
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
 				}
141 141
 			}
142 142
 			setEventMessages($langs->trans("SaveLevelSkill"), null);
143
-			header("Location: " . DOL_URL_ROOT.'/hrm/skill_tab.php?id=' . $id. '&objecttype=job');
143
+			header("Location: ".DOL_URL_ROOT.'/hrm/skill_tab.php?id='.$id.'&objecttype=job');
144 144
 			exit;
145 145
 		}
146 146
 	} elseif ($action == 'confirm_deleteskill' && $confirm == 'yes') {
@@ -171,11 +171,11 @@  discard block
 block discarded – undo
171 171
 
172 172
 	// view configuration
173 173
 	if ($objecttype == 'job') {
174
-		require_once DOL_DOCUMENT_ROOT . '/hrm/lib/hrm_job.lib.php';
174
+		require_once DOL_DOCUMENT_ROOT.'/hrm/lib/hrm_job.lib.php';
175 175
 		$head = jobPrepareHead($object);
176 176
 		$listLink = dol_buildpath('/hrm/job_list.php', 1);
177 177
 	} elseif ($objecttype == "user") {
178
-		require_once DOL_DOCUMENT_ROOT . "/core/lib/usergroups.lib.php";
178
+		require_once DOL_DOCUMENT_ROOT."/core/lib/usergroups.lib.php";
179 179
 		$object->getRights();
180 180
 		$head = user_prepare_head($object);
181 181
 		$listLink = dol_buildpath('/user/list.php', 1);
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
 	}*/
192 192
 	// Confirmation to delete line
193 193
 	if ($action == 'ask_deleteskill') {
194
-		$formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $object->id . '&objecttype=' . $objecttype . '&lineid=' . $lineid, $langs->trans('DeleteLine'), $langs->trans('ConfirmDeleteLine'), 'confirm_deleteskill', '', 0, 1);
194
+		$formconfirm = $form->formconfirm($_SERVER["PHP_SELF"].'?id='.$object->id.'&objecttype='.$objecttype.'&lineid='.$lineid, $langs->trans('DeleteLine'), $langs->trans('ConfirmDeleteLine'), 'confirm_deleteskill', '', 0, 1);
195 195
 	}
196 196
 	// Clone confirmation
197 197
 	/*if ($action == 'clone') {
@@ -216,15 +216,15 @@  discard block
 block discarded – undo
216 216
 	// Object card
217 217
 	// ------------------------------------------------------------
218 218
 	if ($objecttype == 'job') {
219
-		$linkback = '<a href="' . dol_buildpath('/hrm/job_list.php', 1) . '?restore_lastsearch_values=1' . (!empty($socid) ? '&socid=' . $socid : '') . '">' . $langs->trans("BackToList") . '</a>';
219
+		$linkback = '<a href="'.dol_buildpath('/hrm/job_list.php', 1).'?restore_lastsearch_values=1'.(!empty($socid) ? '&socid='.$socid : '').'">'.$langs->trans("BackToList").'</a>';
220 220
 
221 221
 		$morehtmlref = '<div class="refid">';
222
-		$morehtmlref.= $object->label;
222
+		$morehtmlref .= $object->label;
223 223
 		$morehtmlref .= '</div>';
224 224
 
225 225
 		dol_banner_tab($object, 'id', $linkback, 1, 'rowid', 'rowid', $morehtmlref);
226 226
 	} else {
227
-		$linkback = '<a href="' . $listLink . '?restore_lastsearch_values=1' . (!empty($socid) ? '&socid=' . $socid : '') . '">' . $langs->trans("BackToList") . '</a>';
227
+		$linkback = '<a href="'.$listLink.'?restore_lastsearch_values=1'.(!empty($socid) ? '&socid='.$socid : '').'">'.$langs->trans("BackToList").'</a>';
228 228
 
229 229
 		$morehtmlref = '<a href="'.DOL_URL_ROOT.'/user/vcard.php?id='.$object->id.'&output=file&file='.urlencode(dol_sanitizeFileName($object->getFullName($langs).'.vcf')).'" class="refid" rel="noopener">';
230 230
 		$morehtmlref .= img_picto($langs->trans("Download").' '.$langs->trans("VCard"), 'vcard.png', 'class="valignmiddle marginleftonly paddingrightonly"');
@@ -241,7 +241,7 @@  discard block
 block discarded – undo
241 241
 	$TAllSkills = $static_skill->fetchAll();
242 242
 
243 243
 	// Array format for multiselectarray function
244
-	$TAllSkillsFormatted=array();
244
+	$TAllSkillsFormatted = array();
245 245
 	if (!empty($TAllSkills)) {
246 246
 		foreach ($TAllSkills as $k=>$v) {
247 247
 			$TAllSkillsFormatted[$k] = $v->label;
@@ -249,7 +249,7 @@  discard block
 block discarded – undo
249 249
 	}
250 250
 
251 251
 	// table of skillRank linked to current object
252
-	$TSkillsJob = $skill->fetchAll('ASC', 't.rowid', 0, 0, array('customsql' => 'fk_object=' . ((int) $id) . " AND objecttype='" . $db->escape($objecttype) . "'"));
252
+	$TSkillsJob = $skill->fetchAll('ASC', 't.rowid', 0, 0, array('customsql' => 'fk_object='.((int) $id)." AND objecttype='".$db->escape($objecttype)."'"));
253 253
 
254 254
 	$TAlreadyUsedSkill = array();
255 255
 	if (is_array($TSkillsJob) && !empty($TSkillsJob)) {
@@ -269,11 +269,11 @@  discard block
 block discarded – undo
269 269
 		//$keyforbreak='fieldkeytoswitchonsecondcolumn';	// We change column just before this field
270 270
 		//unset($object->fields['fk_project']);				// Hide field already shown in banner
271 271
 		//unset($object->fields['fk_soc']);					// Hide field already shown in banner
272
-		$object->fields['label']['visible']=0; // Already in banner
273
-		include DOL_DOCUMENT_ROOT . '/core/tpl/commonfields_view.tpl.php';
272
+		$object->fields['label']['visible'] = 0; // Already in banner
273
+		include DOL_DOCUMENT_ROOT.'/core/tpl/commonfields_view.tpl.php';
274 274
 
275 275
 		// Other attributes. Fields from hook formObjectOptions and Extrafields.
276
-		include DOL_DOCUMENT_ROOT . '/core/tpl/extrafields_view.tpl.php';
276
+		include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_view.tpl.php';
277 277
 	} else {
278 278
 		// Login
279 279
 		print '<tr><td class="titlefield">'.$langs->trans("Login").'</td>';
@@ -296,9 +296,9 @@  discard block
 block discarded – undo
296 296
 		}
297 297
 		print '</tr>'."\n";
298 298
 
299
-		$object->fields['label']['visible']=0; // Already in banner
300
-		$object->fields['firstname']['visible']=0; // Already in banner
301
-		$object->fields['lastname']['visible']=0; // Already in banner
299
+		$object->fields['label']['visible'] = 0; // Already in banner
300
+		$object->fields['firstname']['visible'] = 0; // Already in banner
301
+		$object->fields['lastname']['visible'] = 0; // Already in banner
302 302
 		//include DOL_DOCUMENT_ROOT . '/core/tpl/commonfields_view.tpl.php';
303 303
 
304 304
 		// Ref employee
@@ -326,19 +326,19 @@  discard block
 block discarded – undo
326 326
 
327 327
 	if ($objecttype != 'user' && $permissiontoadd) {
328 328
 		// form pour ajouter des compétences
329
-		print '<form name="addSkill" method="post" action="' . $_SERVER['PHP_SELF'] . '">';
330
-		print '<input type="hidden" name="objecttype" value="' . $objecttype . '">';
331
-		print '<input type="hidden" name="id" value="' . $id . '">';
329
+		print '<form name="addSkill" method="post" action="'.$_SERVER['PHP_SELF'].'">';
330
+		print '<input type="hidden" name="objecttype" value="'.$objecttype.'">';
331
+		print '<input type="hidden" name="id" value="'.$id.'">';
332 332
 		print '<input type="hidden" name="action" value="addSkill">';
333 333
 		print '<input type="hidden" name="token" value="'.newToken().'">';
334 334
 		print '<div class="div-table-responsive-no-min">';
335 335
 		print '<table id="tablelines" class="noborder noshadow" width="100%">';
336
-		print '<tr><td style="width:90%">' . $langs->trans('AddSkill') . '</td><td style="width:10%"></td></tr>';
336
+		print '<tr><td style="width:90%">'.$langs->trans('AddSkill').'</td><td style="width:10%"></td></tr>';
337 337
 		print '<tr>';
338 338
 		print '<td>';
339 339
 		print img_picto('', 'shapes', 'class="pictofixedwidth"');
340
-		print $form->multiselectarray('fk_skill', array_diff_key($TAllSkillsFormatted, $TAlreadyUsedSkill), array(), 0, 0, 'widthcentpercentminusx') . '</td>';
341
-		print '<td><input class="button reposition" type="submit" value="' . $langs->trans('Add') . '"></td>';
340
+		print $form->multiselectarray('fk_skill', array_diff_key($TAllSkillsFormatted, $TAlreadyUsedSkill), array(), 0, 0, 'widthcentpercentminusx').'</td>';
341
+		print '<td><input class="button reposition" type="submit" value="'.$langs->trans('Add').'"></td>';
342 342
 		print '</tr>';
343 343
 		print '</table>';
344 344
 		print '</div>';
@@ -349,9 +349,9 @@  discard block
 block discarded – undo
349 349
 	print '<div class="clearboth"></div>';
350 350
 
351 351
 	if ($objecttype != 'user' && $permissiontoadd) {
352
-		print '<form name="saveSkill" method="post" action="' . $_SERVER['PHP_SELF'] . '">';
353
-		print '<input type="hidden" name="objecttype" value="' . $objecttype . '">';
354
-		print '<input type="hidden" name="id" value="' . $id . '">';
352
+		print '<form name="saveSkill" method="post" action="'.$_SERVER['PHP_SELF'].'">';
353
+		print '<input type="hidden" name="objecttype" value="'.$objecttype.'">';
354
+		print '<input type="hidden" name="id" value="'.$id.'">';
355 355
 		print '<input type="hidden" name="token" value="'.newToken().'">';
356 356
 		print '<input type="hidden" name="action" value="saveSkill">';
357 357
 	}
@@ -368,7 +368,7 @@  discard block
 block discarded – undo
368 368
 	}
369 369
 	print '</tr>';
370 370
 	if (!is_array($TSkillsJob) || empty($TSkillsJob)) {
371
-		print '<tr><td><span class="opacitymedium">' . $langs->trans("NoRecordFound") . '</span></td></tr>';
371
+		print '<tr><td><span class="opacitymedium">'.$langs->trans("NoRecordFound").'</span></td></tr>';
372 372
 	} else {
373 373
 		$sk = new Skill($db);
374 374
 		foreach ($TSkillsJob as $skillElement) {
@@ -387,7 +387,7 @@  discard block
 block discarded – undo
387 387
 			if ($objecttype != 'user' && $permissiontoadd) {
388 388
 				print '<td class="linecoledit"></td>';
389 389
 				print '<td class="linecoldelete">';
390
-				print '<a class="reposition" href="' . $_SERVER["PHP_SELF"] . '?id=' . $skillElement->fk_object . '&amp;objecttype=' . $objecttype . '&amp;action=ask_deleteskill&amp;lineid=' . $skillElement->id . '">';
390
+				print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?id='.$skillElement->fk_object.'&amp;objecttype='.$objecttype.'&amp;action=ask_deleteskill&amp;lineid='.$skillElement->id.'">';
391 391
 				print img_delete();
392 392
 				print '</a>';
393 393
 			}
@@ -397,7 +397,7 @@  discard block
 block discarded – undo
397 397
 	}
398 398
 
399 399
 	print '</table>';
400
-	if ($objecttype != 'user' && $permissiontoadd) print '<td><input class="button pull-right" type="submit" value="' . $langs->trans('SaveRank') . '"></td>';
400
+	if ($objecttype != 'user' && $permissiontoadd) print '<td><input class="button pull-right" type="submit" value="'.$langs->trans('SaveRank').'"></td>';
401 401
 	print '</div>';
402 402
 	if ($objecttype != 'user' && $permissiontoadd) print '</form>';
403 403
 
Please login to merge, or discard this patch.