Completed
Branch develop (cec3a6)
by
unknown
19:26
created
htdocs/core/lib/fichinter.lib.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -122,7 +122,7 @@  discard block
 block discarded – undo
122 122
 
123 123
 	$head[$h][0] = DOL_URL_ROOT.'/fichinter/agenda.php?id='.$object->id;
124 124
 	$head[$h][1] = $langs->trans('Events');
125
-	if (isModEnabled('agenda')&& ($user->hasRight('agenda', 'myactions', 'read') || $user->hasRight('agenda', 'allactions', 'read'))) {
125
+	if (isModEnabled('agenda') && ($user->hasRight('agenda', 'myactions', 'read') || $user->hasRight('agenda', 'allactions', 'read'))) {
126 126
 		$nbEvent = 0;
127 127
 		// Enable caching of thirdparty count actioncomm
128 128
 		require_once DOL_DOCUMENT_ROOT.'/core/lib/memory.lib.php';
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
 			} else {
143 143
 				dol_syslog('Failed to count actioncomm '.$db->lasterror(), LOG_ERR);
144 144
 			}
145
-			dol_setcache($cachekey, $nbEvent, 120);		// If setting cache fails, this is not a problem, so we do not test result.
145
+			dol_setcache($cachekey, $nbEvent, 120); // If setting cache fails, this is not a problem, so we do not test result.
146 146
 		}
147 147
 
148 148
 		$head[$h][1] .= '/';
Please login to merge, or discard this patch.
htdocs/core/lib/contract.lib.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
 
100 100
 	$head[$h][0] = DOL_URL_ROOT.'/contrat/agenda.php?id='.$object->id;
101 101
 	$head[$h][1] = $langs->trans("Events");
102
-	if (isModEnabled('agenda')&& ($user->hasRight('agenda', 'myactions', 'read') || $user->hasRight('agenda', 'allactions', 'read'))) {
102
+	if (isModEnabled('agenda') && ($user->hasRight('agenda', 'myactions', 'read') || $user->hasRight('agenda', 'allactions', 'read'))) {
103 103
 		$nbEvent = 0;
104 104
 		// Enable caching of thirdparty count actioncomm
105 105
 		require_once DOL_DOCUMENT_ROOT.'/core/lib/memory.lib.php';
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
 			} else {
120 120
 				dol_syslog('Failed to count actioncomm '.$db->lasterror(), LOG_ERR);
121 121
 			}
122
-			dol_setcache($cachekey, $nbEvent, 120);		// If setting cache fails, this is not a problem, so we do not test result.
122
+			dol_setcache($cachekey, $nbEvent, 120); // If setting cache fails, this is not a problem, so we do not test result.
123 123
 		}
124 124
 
125 125
 		$head[$h][1] .= '/';
Please login to merge, or discard this patch.
htdocs/core/lib/order.lib.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
 
132 132
 	$head[$h][0] = DOL_URL_ROOT.'/commande/agenda.php?id='.$object->id;
133 133
 	$head[$h][1] = $langs->trans("Events");
134
-	if (isModEnabled('agenda')&& ($user->hasRight('agenda', 'myactions', 'read') || $user->hasRight('agenda', 'allactions', 'read'))) {
134
+	if (isModEnabled('agenda') && ($user->hasRight('agenda', 'myactions', 'read') || $user->hasRight('agenda', 'allactions', 'read'))) {
135 135
 		$nbEvent = 0;
136 136
 		// Enable caching of thirdparty count actioncomm
137 137
 		require_once DOL_DOCUMENT_ROOT.'/core/lib/memory.lib.php';
@@ -151,7 +151,7 @@  discard block
 block discarded – undo
151 151
 			} else {
152 152
 				dol_syslog('Failed to count actioncomm '.$db->lasterror(), LOG_ERR);
153 153
 			}
154
-			dol_setcache($cachekey, $nbEvent, 120);		// If setting cache fails, this is not a problem, so we do not test result.
154
+			dol_setcache($cachekey, $nbEvent, 120); // If setting cache fails, this is not a problem, so we do not test result.
155 155
 		}
156 156
 
157 157
 		$head[$h][1] .= '/';
Please login to merge, or discard this patch.
htdocs/core/lib/member.lib.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
 	// Show agenda tab
129 129
 	$head[$h][0] = DOL_URL_ROOT.'/adherents/agenda.php?id='.$object->id;
130 130
 	$head[$h][1] = $langs->trans("Events");
131
-	if (isModEnabled('agenda')&& ($user->hasRight('agenda', 'myactions', 'read') || $user->hasRight('agenda', 'allactions', 'read'))) {
131
+	if (isModEnabled('agenda') && ($user->hasRight('agenda', 'myactions', 'read') || $user->hasRight('agenda', 'allactions', 'read'))) {
132 132
 		$nbEvent = 0;
133 133
 		// Enable caching of thirdparty count actioncomm
134 134
 		require_once DOL_DOCUMENT_ROOT.'/core/lib/memory.lib.php';
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
 			} else {
148 148
 				dol_syslog('Failed to count actioncomm '.$db->lasterror(), LOG_ERR);
149 149
 			}
150
-			dol_setcache($cachekey, $nbEvent, 120);		// If setting cache fails, this is not a problem, so we do not test result.
150
+			dol_setcache($cachekey, $nbEvent, 120); // If setting cache fails, this is not a problem, so we do not test result.
151 151
 		}
152 152
 
153 153
 		$head[$h][1] .= '/';
Please login to merge, or discard this patch.
htdocs/core/lib/ajax.lib.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -552,11 +552,11 @@  discard block
 block discarded – undo
552 552
 	$out = '';
553 553
 
554 554
 	if (is_array($events) && count($events)) {   // If an array of js events to do were provided.
555
-		$out = '<!-- JS code to manage event for id = ' . $htmlname . ' -->
555
+		$out = '<!-- JS code to manage event for id = '.$htmlname.' -->
556 556
 	<script>
557 557
 		$(document).ready(function () {
558 558
 			jQuery("#'.$htmlname.'").change(function () {
559
-				var obj = '.json_encode($events) . ';
559
+				var obj = '.json_encode($events).';
560 560
 		   		$.each(obj, function(key,values) {
561 561
 	    			if (values.method.length) {
562 562
 	    				runJsCodeForEvent'.$htmlname.'(values);
@@ -675,9 +675,9 @@  discard block
 block discarded – undo
675 675
 						confirmConstantAction("del", url, code, input, input.alert.del, entity, yesButton, noButton, strict, userid, token);
676 676
 					} else {';
677 677
 		if (empty($setzeroinsteadofdel)) {
678
-			$out .=' 	delConstant(url, code, input, entity, 0, '.((int) $forcereload).', userid, token);';
678
+			$out .= ' 	delConstant(url, code, input, entity, 0, '.((int) $forcereload).', userid, token);';
679 679
 		} else {
680
-			$out .=' 	setConstant(url, code, input, entity, 0, '.((int) $forcereload).', userid, token, 0);';
680
+			$out .= ' 	setConstant(url, code, input, entity, 0, '.((int) $forcereload).', userid, token, 0);';
681 681
 		}
682 682
 		$out .= '	}
683 683
 				});
Please login to merge, or discard this patch.
htdocs/core/modules/ticket/doc/doc_generic_ticket_odt.modules.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -162,7 +162,7 @@  discard block
 block discarded – undo
162 162
 		$maxfilesizearray = getMaxFileSizeArray();
163 163
 		$maxmin = $maxfilesizearray['maxmin'];
164 164
 		if ($maxmin > 0) {
165
-			$texte .= '<input type="hidden" name="MAX_FILE_SIZE" value="'.($maxmin * 1024).'">';	// MAX_FILE_SIZE must precede the field type=file
165
+			$texte .= '<input type="hidden" name="MAX_FILE_SIZE" value="'.($maxmin * 1024).'">'; // MAX_FILE_SIZE must precede the field type=file
166 166
 		}
167 167
 		$texte .= ' <input type="file" name="uploadfile">';
168 168
 		$texte .= '<input type="hidden" value="TICKET_ADDON_PDF_ODT_PATH" name="keyforuploaddir">';
@@ -253,7 +253,7 @@  discard block
 block discarded – undo
253 253
 				$newfiletmp = preg_replace('/template_/i', '', $newfiletmp);
254 254
 				$newfiletmp = preg_replace('/modele_/i', '', $newfiletmp);
255 255
 
256
-				$newfiletmp = $objectref . '_' . $newfiletmp;
256
+				$newfiletmp = $objectref.'_'.$newfiletmp;
257 257
 
258 258
 				// Get extension (ods or odt)
259 259
 				$newfileformat = substr($newfile, strrpos($newfile, '.') + 1);
@@ -262,11 +262,11 @@  discard block
 block discarded – undo
262 262
 					if ($format == '1') {
263 263
 						$format = '%Y%m%d%H%M%S';
264 264
 					}
265
-					$filename = $newfiletmp . '-' . dol_print_date(dol_now(), $format) . '.' . $newfileformat;
265
+					$filename = $newfiletmp.'-'.dol_print_date(dol_now(), $format).'.'.$newfileformat;
266 266
 				} else {
267
-					$filename = $newfiletmp . '.' . $newfileformat;
267
+					$filename = $newfiletmp.'.'.$newfileformat;
268 268
 				}
269
-				$file = $dir . '/' . $filename;
269
+				$file = $dir.'/'.$filename;
270 270
 				//print "newdir=".$dir;
271 271
 				//print "newfile=".$newfile;
272 272
 				//print "file=".$file;
@@ -275,7 +275,7 @@  discard block
 block discarded – undo
275 275
 				dol_mkdir($conf->ticket->dir_temp);
276 276
 				if (!is_writable($conf->ticket->dir_temp)) {
277 277
 					$this->error = $langs->transnoentities("ErrorFailedToWriteInTempDirectory", $conf->ticket->dir_temp);
278
-					dol_syslog('Error in write_file: ' . $this->error, LOG_ERR);
278
+					dol_syslog('Error in write_file: '.$this->error, LOG_ERR);
279 279
 					return -1;
280 280
 				}
281 281
 
Please login to merge, or discard this patch.
htdocs/core/modules/ticket/mod_ticket_universal.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@
 block discarded – undo
33 33
 	 *  Dolibarr version of the loaded document
34 34
 	 *  @var string
35 35
 	 */
36
-	public $version = 'dolibarr';  // 'development', 'experimental', 'dolibarr'
36
+	public $version = 'dolibarr'; // 'development', 'experimental', 'dolibarr'
37 37
 
38 38
 	/**
39 39
 	 *  @var string Error code (or message)
Please login to merge, or discard this patch.
htdocs/core/modules/modApi.class.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -141,11 +141,11 @@  discard block
 block discarded – undo
141 141
 
142 142
 		// Add here list of permission defined by an id, a label, a boolean and two constant strings.
143 143
 		// Example:
144
-		$this->rights[$r][0] = $this->numero + $r;	// Permission id (must not be already used)
145
-		$this->rights[$r][1] = 'Generate/modify users API key';	// Permission label
146
-		$this->rights[$r][3] = 0; 					// Permission by default for new user (0/1)
147
-		$this->rights[$r][4] = 'apikey';				// In php code, permission will be checked by test if ($user->rights->permkey->level1->level2)
148
-		$this->rights[$r][5] = 'generate';				// In php code, permission will be checked by test if ($user->rights->permkey->level1->level2)
144
+		$this->rights[$r][0] = $this->numero + $r; // Permission id (must not be already used)
145
+		$this->rights[$r][1] = 'Generate/modify users API key'; // Permission label
146
+		$this->rights[$r][3] = 0; // Permission by default for new user (0/1)
147
+		$this->rights[$r][4] = 'apikey'; // In php code, permission will be checked by test if ($user->rights->permkey->level1->level2)
148
+		$this->rights[$r][5] = 'generate'; // In php code, permission will be checked by test if ($user->rights->permkey->level1->level2)
149 149
 		$r++;
150 150
 
151 151
 
@@ -229,7 +229,7 @@  discard block
 block discarded – undo
229 229
 	{
230 230
 		// Remove old constants with entity fields different of 0
231 231
 		$sql = array(
232
-			"DELETE FROM ".MAIN_DB_PREFIX."const WHERE name = ".$this->db->encrypt('MAIN_MODULE_API'),		// API can't be enabled per environment. Why ?
232
+			"DELETE FROM ".MAIN_DB_PREFIX."const WHERE name = ".$this->db->encrypt('MAIN_MODULE_API'), // API can't be enabled per environment. Why ?
233 233
 			"DELETE FROM ".MAIN_DB_PREFIX."const WHERE name = ".$this->db->encrypt('API_PRODUCTION_MODE')	// Not in production mode by default at activation
234 234
 		);
235 235
 
Please login to merge, or discard this patch.
htdocs/core/modules/modExpedition.class.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -246,7 +246,7 @@
 block discarded – undo
246 246
 		$this->export_fields_array[$r] = array(
247 247
 			's.rowid'=>"IdCompany", 's.nom'=>'ThirdParty', 's.address'=>'Address', 's.zip'=>'Zip', 's.town'=>'Town', 'd.nom'=>'State', 'co.label'=>'Country',
248 248
 			'co.code'=>'CountryCode', 's.phone'=>'Phone', 's.siren'=>'ProfId1', 's.siret'=>'ProfId2', 's.ape'=>'ProfId3', 's.idprof4'=>'ProfId4', 's.idprof5'=>'ProfId5',
249
-			's.idprof6'=>'ProfId6', 'c.rowid'=>"Id", 'c.ref'=>"Ref", 'c.ref_customer'=>"RefCustomer", 'c.fk_soc'=>"IdCompany", 'c.date_creation'=>"DateCreation",  'c.date_valid'=>"DateValidation",
249
+			's.idprof6'=>'ProfId6', 'c.rowid'=>"Id", 'c.ref'=>"Ref", 'c.ref_customer'=>"RefCustomer", 'c.fk_soc'=>"IdCompany", 'c.date_creation'=>"DateCreation", 'c.date_valid'=>"DateValidation",
250 250
 			'c.date_delivery'=>"DateDeliveryPlanned", 'c.tracking_number'=>"TrackingNumber", 'c.height'=>"Height", 'c.width'=>"Width", 'c.size'=>"Depth",
251 251
 			'c.size_units'=>'SizeUnits', 'c.weight'=>"Weight", 'c.weight_units'=>"WeightUnits", 'c.fk_statut'=>'Status', 'c.note_public'=>"NotePublic",
252 252
 			'ed.rowid'=>'LineId', 'cd.description'=>'Description', 'ed.qty'=>"Qty", 'p.rowid'=>'ProductId', 'p.ref'=>'ProductRef', 'p.label'=>'ProductLabel',
Please login to merge, or discard this patch.