Completed
Push — master ( 9a8c1f...f14102 )
by Laurent
02:31
created
class/missions/FlightMission.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@
 block discarded – undo
64 64
         Assert::string($kilometersComment);
65 65
         Assert::integerish($numberOfKilometers);
66 66
 
67
-        $this->id = (int)$id;
67
+        $this->id = (int) $id;
68 68
         $this->startPoint = $startPoint;
69 69
         $this->endPoint = $endPoint;
70 70
         $this->kilometersComment = $kilometersComment;
Please login to merge, or discard this patch.
class/missions/PilotMissions.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
         Assert::nullOrString($pilotLastname);
47 47
         Assert::nullOrString($pilotFirstname);
48 48
 
49
-        $this->pilotId = (int)$pilotId;
49
+        $this->pilotId = (int) $pilotId;
50 50
         $this->pilotFirstname = $pilotFirstname;
51 51
         $this->pilotLastname = $pilotLastname;
52 52
 
@@ -59,9 +59,9 @@  discard block
 block discarded – undo
59 59
      * @param int $numberOfFlights
60 60
      * @param int $numberOfKilometers
61 61
      */
62
-    public function addQuarter($quarter, $numberOfFlights, $numberOfKilometers){
62
+    public function addQuarter($quarter, $numberOfFlights, $numberOfKilometers) {
63 63
         Assert::integerish($quarter);
64
-        $quarter = (int)$quarter;
64
+        $quarter = (int) $quarter;
65 65
 
66 66
         Assert::keyNotExists($this->quarterMissions, $quarter);
67 67
 
@@ -119,13 +119,13 @@  discard block
 block discarded – undo
119 119
      *
120 120
      * @return QuarterMission
121 121
      */
122
-    private function getQuarterMission($quarter){
122
+    private function getQuarterMission($quarter) {
123 123
         Assert::integer($quarter);
124 124
         Assert::greaterThan($quarter, 0);
125 125
         Assert::lessThanEq($quarter, 4);
126 126
 
127
-        if(!isset($this->quarterMissions[$quarter])){
128
-            return new QuarterMission($quarter,0,0);
127
+        if (!isset($this->quarterMissions[$quarter])) {
128
+            return new QuarterMission($quarter, 0, 0);
129 129
         }
130 130
 
131 131
         return $this->quarterMissions[$quarter];
@@ -136,6 +136,6 @@  discard block
 block discarded – undo
136 136
      */
137 137
     public function getPilotName()
138 138
     {
139
-        return $this->pilotFirstname.' '.$this->pilotLastname;
139
+        return $this->pilotFirstname . ' ' . $this->pilotLastname;
140 140
     }
141 141
 }
142 142
\ No newline at end of file
Please login to merge, or discard this patch.
generateExpenseNote.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -87,9 +87,9 @@  discard block
 block discarded – undo
87 87
     try {
88 88
         $command = new CreateExpenseNoteCommand($year, $quarter, $userValidatorId, $privateNote, $publicNote);
89 89
         $commandHandler->__invoke($command);
90
-    } catch(PeriodNotFinishedException $e){
90
+    } catch (PeriodNotFinishedException $e) {
91 91
         dol_htmloutput_errors("Le quadri n'est pas encore fini !");
92
-    } catch(\Exception $e){
92
+    } catch (\Exception $e) {
93 93
         dol_syslog($e->getMessage(), LOG_ERR);
94 94
         dol_htmloutput_errors('Error : ' . $e->getMessage());
95 95
     }
@@ -105,15 +105,15 @@  discard block
 block discarded – undo
105 105
 $form = new Form($db);
106 106
 
107 107
 $tabLinks = [];
108
-foreach($flightYears as $currentFlightYear){
108
+foreach ($flightYears as $currentFlightYear) {
109 109
     $tabLinks[] = [
110
-        DOL_URL_ROOT."/flightlog/generateExpenseNote.php?year=".$currentFlightYear,
110
+        DOL_URL_ROOT . "/flightlog/generateExpenseNote.php?year=" . $currentFlightYear,
111 111
         $currentFlightYear,
112
-        "tab_".$currentFlightYear
112
+        "tab_" . $currentFlightYear
113 113
     ];
114 114
 }
115 115
 
116
-dol_fiche_head($tabLinks, "tab_".$year);
116
+dol_fiche_head($tabLinks, "tab_" . $year);
117 117
 
118 118
 ?>
119 119
     <form method="POST">
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
         <select name="quarter" id="field_quarter">
135 135
             <option value="1" <?= ($year == $currentYear && $currentQuarter <= 1) ? 'disabled="disabled"' : "" ?>>1</option>
136 136
             <option value="2" <?= ($year == $currentYear && $currentQuarter <= 2) ? 'disabled="disabled"' : "" ?>>2</option>
137
-            <option value="3" <?= ($year == $currentYear && $currentQuarter <= 3) ? 'disabled="disabled"': "" ?>>3</option>
137
+            <option value="3" <?= ($year == $currentYear && $currentQuarter <= 3) ? 'disabled="disabled"' : "" ?>>3</option>
138 138
             <option value="4" <?= ($year == $currentYear && $currentQuarter <= 4) ? 'disabled="disabled"' : "" ?>>4</option>
139 139
         </select>
140 140
         <br/>
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
         <label><?= $langs->trans("Validateur de la note de frais")?></label><br/>
144 144
         <?php
145 145
             $include_users = $object->fetch_users_approver_expensereport();
146
-            print $form->select_dolusers($user->id,"fk_user_validator",1,"",0,$include_users);
146
+            print $form->select_dolusers($user->id, "fk_user_validator", 1, "", 0, $include_users);
147 147
         ?>
148 148
         <br/>
149 149
 
Please login to merge, or discard this patch.
readFlights.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -266,7 +266,7 @@  discard block
 block discarded – undo
266 266
 print '<td>' . $totalT3 . '</td>';
267 267
 print '<td></td>';
268 268
 
269
-print '<td>' . $totalT4. '</td>';
269
+print '<td>' . $totalT4 . '</td>';
270 270
 print '<td></td>';
271 271
 
272 272
 print '<td>' . $totalT5 . '</td>';
@@ -292,7 +292,7 @@  discard block
 block discarded – undo
292 292
 //table km
293 293
 $tauxRemb = isset($conf->global->BBC_FLIGHT_LOG_TAUX_REMB_KM) ? $conf->global->BBC_FLIGHT_LOG_TAUX_REMB_KM : 0;
294 294
 $year = GETPOST("year", 'int');
295
-if(empty($year)){
295
+if (empty($year)) {
296 296
     $year = date('Y');
297 297
 }
298 298
 
Please login to merge, or discard this patch.
lib/flightLog.lib.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -108,7 +108,7 @@
 block discarded – undo
108 108
 }
109 109
 
110 110
 /**
111
- * @param null $year
111
+ * @param integer $year
112 112
  * @param null $pilotId
113 113
  * @param null $quarter
114 114
  * @param bool $groupBy
Please login to merge, or discard this patch.