@@ -44,8 +44,7 @@ discard block |
||
44 | 44 | */ |
45 | 45 | protected function getPool() |
46 | 46 | { |
47 | - $poolId = $this->target()->method() === 'home' ? $this->target()->args()[0] : |
|
48 | - (int)$this->bag('pool.round')->get('pool.id'); |
|
47 | + $poolId = $this->target()->method() === 'home' ? $this->target()->args()[0] : (int) $this->bag('pool.round')->get('pool.id'); |
|
49 | 48 | $this->pool = $this->poolService->getPool($poolId); |
50 | 49 | } |
51 | 50 | |
@@ -57,7 +56,7 @@ discard block |
||
57 | 56 | $this->response->html('pool-round-actions', $html); |
58 | 57 | $this->jq('#btn-pool-round-back')->click($this->cl(Pool::class)->rq()->home()); |
59 | 58 | $this->jq('#btn-pool-round-save')->click($this->rq()->saveRound(pm()->form('round-form'))); |
60 | - if($this->pool->pool_round) |
|
59 | + if ($this->pool->pool_round) |
|
61 | 60 | { |
62 | 61 | $this->jq('#btn-pool-round-delete')->click($this->rq()->deleteRound() |
63 | 62 | ->confirm(trans('tontine.pool_round.questions.delete'))); |
@@ -65,7 +64,7 @@ discard block |
||
65 | 64 | |
66 | 65 | $defaultLabel = trans('tontine.pool_round.labels.default'); |
67 | 66 | $startSession = !$this->pool->pool_round ? $defaultLabel : $this->pool->start_date; |
68 | - $endSession = !$this->pool->pool_round ? $defaultLabel : $this->pool->end_date; |
|
67 | + $endSession = !$this->pool->pool_round ? $defaultLabel : $this->pool->end_date; |
|
69 | 68 | $this->response->html('pool-round-start-session-title', |
70 | 69 | trans('tontine.pool_round.titles.start_session', ['session' => $startSession])); |
71 | 70 | $this->response->html('pool-round-end-session-title', |
@@ -75,12 +74,12 @@ discard block |
||
75 | 74 | private function getSessionPageNumber(SessionModel $session): int |
76 | 75 | { |
77 | 76 | $sessionCount = $this->sessionService->getTontineSessionCount($session, true, false); |
78 | - return (int)($sessionCount / $this->tenantService->getLimit()) + 1; |
|
77 | + return (int) ($sessionCount / $this->tenantService->getLimit()) + 1; |
|
79 | 78 | } |
80 | 79 | |
81 | 80 | public function home(int $poolId) |
82 | 81 | { |
83 | - if(!$this->pool) |
|
82 | + if (!$this->pool) |
|
84 | 83 | { |
85 | 84 | return $this->response; |
86 | 85 | } |
@@ -97,7 +96,7 @@ discard block |
||
97 | 96 | |
98 | 97 | $startPageNumber = 1; |
99 | 98 | $endPageNumber = 1; |
100 | - if($this->pool->pool_round !== null) |
|
99 | + if ($this->pool->pool_round !== null) |
|
101 | 100 | { |
102 | 101 | // Go to the pages of the round start and end sessions. |
103 | 102 | $startPageNumber = $this->getSessionPageNumber($this->pool->pool_round->start_session); |
@@ -172,7 +171,7 @@ discard block |
||
172 | 171 | |
173 | 172 | public function showStartSessionPage() |
174 | 173 | { |
175 | - if(!$this->pool->pool_round) |
|
174 | + if (!$this->pool->pool_round) |
|
176 | 175 | { |
177 | 176 | return $this->response; |
178 | 177 | } |
@@ -185,7 +184,7 @@ discard block |
||
185 | 184 | |
186 | 185 | public function showEndSessionPage() |
187 | 186 | { |
188 | - if(!$this->pool->pool_round) |
|
187 | + if (!$this->pool->pool_round) |
|
189 | 188 | { |
190 | 189 | return $this->response; |
191 | 190 | } |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | $this->response->html('section-title', trans('tontine.menus.planning')); |
51 | 51 | $this->response->html('content-home-sessions', $html); |
52 | 52 | |
53 | - if(!$round) |
|
53 | + if (!$round) |
|
54 | 54 | { |
55 | 55 | return $this->response; |
56 | 56 | } |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | 'title' => trans('common.actions.cancel'), |
101 | 101 | 'class' => 'btn btn-tertiary', |
102 | 102 | 'click' => 'close', |
103 | - ],[ |
|
103 | + ], [ |
|
104 | 104 | 'title' => trans('common.actions.save'), |
105 | 105 | 'class' => 'btn btn-primary', |
106 | 106 | 'click' => $this->rq()->create(pm()->form('session-form')), |
@@ -131,11 +131,11 @@ discard block |
||
131 | 131 | 'title' => trans('common.actions.cancel'), |
132 | 132 | 'class' => 'btn btn-tertiary', |
133 | 133 | 'click' => 'close', |
134 | - ],[ |
|
134 | + ], [ |
|
135 | 135 | 'title' => trans('common.actions.year'), |
136 | 136 | 'class' => 'btn btn-primary', |
137 | 137 | 'click' => $this->rq()->years(), |
138 | - ],[ |
|
138 | + ], [ |
|
139 | 139 | 'title' => trans('common.actions.save'), |
140 | 140 | 'class' => 'btn btn-primary', |
141 | 141 | 'click' => $this->rq()->createList(pm()->form('session-list')), |
@@ -164,12 +164,12 @@ discard block |
||
164 | 164 | private function parseSessionList(string $sessions): array |
165 | 165 | { |
166 | 166 | $sessions = array_map(function($value) { |
167 | - if(!($value = trim($value, " \t\n\r;"))) |
|
167 | + if (!($value = trim($value, " \t\n\r;"))) |
|
168 | 168 | { |
169 | 169 | return []; |
170 | 170 | } |
171 | 171 | $values = explode(";", $value); |
172 | - if(count($values) !== 2) |
|
172 | + if (count($values) !== 2) |
|
173 | 173 | { |
174 | 174 | return []; // Todo: throw an exception |
175 | 175 | } |
@@ -186,7 +186,7 @@ discard block |
||
186 | 186 | |
187 | 187 | // Check uniqueness of session dates |
188 | 188 | $sessionDates = array_unique(array_map(fn($session) => $session['date'], $sessions)); |
189 | - if(count($sessions) !== count($sessionDates)) |
|
189 | + if (count($sessions) !== count($sessionDates)) |
|
190 | 190 | { |
191 | 191 | throw new MessageException(trans('tontine.session.errors.date_dup')); |
192 | 192 | } |
@@ -219,7 +219,7 @@ discard block |
||
219 | 219 | 'title' => trans('common.actions.cancel'), |
220 | 220 | 'class' => 'btn btn-tertiary', |
221 | 221 | 'click' => 'close', |
222 | - ],[ |
|
222 | + ], [ |
|
223 | 223 | 'title' => trans('common.actions.save'), |
224 | 224 | 'class' => 'btn btn-primary', |
225 | 225 | 'click' => $this->rq()->update($session->id, pm()->form('session-form')), |
@@ -257,7 +257,7 @@ discard block |
||
257 | 257 | 'title' => trans('common.actions.cancel'), |
258 | 258 | 'class' => 'btn btn-tertiary', |
259 | 259 | 'click' => 'close', |
260 | - ],[ |
|
260 | + ], [ |
|
261 | 261 | 'title' => trans('common.actions.save'), |
262 | 262 | 'class' => 'btn btn-primary', |
263 | 263 | 'click' => $this->rq()->saveVenue($session->id, pm()->form('session-form')), |
@@ -47,8 +47,7 @@ discard block |
||
47 | 47 | $pools = $this->poolService->getRoundPools(); |
48 | 48 | $poolLabels = $pools->keyBy('id')->map(function($pool) { |
49 | 49 | return $pool->title . ' - ' . ($pool->deposit_fixed ? |
50 | - $this->localeService->formatMoney($pool->amount) : |
|
51 | - trans('tontine.labels.types.libre')); |
|
50 | + $this->localeService->formatMoney($pool->amount) : trans('tontine.labels.types.libre')); |
|
52 | 51 | }); |
53 | 52 | $html = $this->render('pages.planning.subscription.home', [ |
54 | 53 | 'pools' => $poolLabels, |
@@ -61,7 +60,7 @@ discard block |
||
61 | 60 | $this->jq('#btn-pool-select')->click($this->rq()->pool($selectPoolId)); |
62 | 61 | |
63 | 62 | $pool = $pools->firstWhere('id', $poolId) ?? ($pools->count() > 0 ? $pools[0] : null); |
64 | - if(($pool)) |
|
63 | + if (($pool)) |
|
65 | 64 | { |
66 | 65 | return $this->show($pool); |
67 | 66 | } |
@@ -93,7 +92,7 @@ discard block |
||
93 | 92 | public function planning(int $poolId) |
94 | 93 | { |
95 | 94 | $pool = $this->poolService->getPool($poolId); |
96 | - if(!$pool || !$pool->remit_planned) |
|
95 | + if (!$pool || !$pool->remit_planned) |
|
97 | 96 | { |
98 | 97 | return $this->response; |
99 | 98 | } |
@@ -118,7 +117,7 @@ discard block |
||
118 | 117 | public function beneficiaries(int $poolId) |
119 | 118 | { |
120 | 119 | $pool = $this->poolService->getPool($poolId); |
121 | - if(!$pool || !$pool->remit_planned) |
|
120 | + if (!$pool || !$pool->remit_planned) |
|
122 | 121 | { |
123 | 122 | return $this->response; |
124 | 123 | } |
@@ -150,12 +149,12 @@ discard block |
||
150 | 149 | int $currSubscriptionId) |
151 | 150 | { |
152 | 151 | $pool = $this->poolService->getPool($poolId); |
153 | - if(!$pool || !$pool->remit_planned || $pool->remit_auction) |
|
152 | + if (!$pool || !$pool->remit_planned || $pool->remit_auction) |
|
154 | 153 | { |
155 | 154 | return $this->response; |
156 | 155 | } |
157 | 156 | |
158 | - if(!$this->subscriptionService->saveBeneficiary($pool, $sessionId, |
|
157 | + if (!$this->subscriptionService->saveBeneficiary($pool, $sessionId, |
|
159 | 158 | $currSubscriptionId, $nextSubscriptionId)) |
160 | 159 | { |
161 | 160 | $message = trans('tontine.beneficiary.errors.cant_change'); |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | |
77 | 77 | public function showSession(int $sessionId) |
78 | 78 | { |
79 | - if(!($session = $this->sessionService->getSession($sessionId))) |
|
79 | + if (!($session = $this->sessionService->getSession($sessionId))) |
|
80 | 80 | { |
81 | 81 | return $this->response; |
82 | 82 | } |
@@ -86,11 +86,11 @@ discard block |
||
86 | 86 | |
87 | 87 | public function showMember(int $sessionId, int $memberId) |
88 | 88 | { |
89 | - if(!($session = $this->sessionService->getSession($sessionId))) |
|
89 | + if (!($session = $this->sessionService->getSession($sessionId))) |
|
90 | 90 | { |
91 | 91 | return $this->response; |
92 | 92 | } |
93 | - if(!($member = $this->memberService->getMember($memberId))) |
|
93 | + if (!($member = $this->memberService->getMember($memberId))) |
|
94 | 94 | { |
95 | 95 | return $this->response; |
96 | 96 | } |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | $this->target()->args()[0] : $this->bag('meeting')->get('pool.id'); |
47 | 47 | $this->pool = $this->poolService->getPool($poolId); |
48 | 48 | |
49 | - if(!$this->session || !$this->pool || $this->session->disabled($this->pool)) |
|
49 | + if (!$this->session || !$this->pool || $this->session->disabled($this->pool)) |
|
50 | 50 | { |
51 | 51 | $this->notify->error(trans('tontine.session.errors.disabled'), trans('common.titles.error')); |
52 | 52 | $this->pool = null; |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | */ |
113 | 113 | public function addDeposit(int $receivableId) |
114 | 114 | { |
115 | - if($this->session->closed) |
|
115 | + if ($this->session->closed) |
|
116 | 116 | { |
117 | 117 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
118 | 118 | return $this->response; |
@@ -131,21 +131,20 @@ discard block |
||
131 | 131 | */ |
132 | 132 | public function editAmount(int $receivableId) |
133 | 133 | { |
134 | - if($this->session->closed) |
|
134 | + if ($this->session->closed) |
|
135 | 135 | { |
136 | 136 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
137 | 137 | return $this->response; |
138 | 138 | } |
139 | 139 | $receivable = $this->depositService->getReceivable($this->pool, $this->session, $receivableId); |
140 | - if(!$receivable || !$receivable->deposit) |
|
140 | + if (!$receivable || !$receivable->deposit) |
|
141 | 141 | { |
142 | 142 | return $this->page(); |
143 | 143 | } |
144 | 144 | |
145 | 145 | $html = $this->render('pages.meeting.deposit.libre.edit', [ |
146 | 146 | 'id' => $receivable->id, |
147 | - 'amount' => !$receivable->deposit ? '' : |
|
148 | - $this->localeService->getMoneyValue($receivable->deposit->amount), |
|
147 | + 'amount' => !$receivable->deposit ? '' : $this->localeService->getMoneyValue($receivable->deposit->amount), |
|
149 | 148 | ]); |
150 | 149 | $fieldId = 'receivable-' . $receivable->id; |
151 | 150 | $this->response->html($fieldId, $html); |
@@ -166,22 +165,21 @@ discard block |
||
166 | 165 | */ |
167 | 166 | public function saveAmount(int $receivableId, string $amount) |
168 | 167 | { |
169 | - if($this->session->closed) |
|
168 | + if ($this->session->closed) |
|
170 | 169 | { |
171 | 170 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
172 | 171 | return $this->response; |
173 | 172 | } |
174 | 173 | $amount = str_replace(',', '.', trim($amount)); |
175 | - if($amount !== '' && filter_var($amount, FILTER_VALIDATE_FLOAT) === false) |
|
174 | + if ($amount !== '' && filter_var($amount, FILTER_VALIDATE_FLOAT) === false) |
|
176 | 175 | { |
177 | 176 | $this->notify->error(trans('meeting.errors.amount.invalid', ['amount' => $amount])); |
178 | 177 | return $this->response; |
179 | 178 | } |
180 | - $amount = $amount === '' ? 0 : $this->localeService->convertMoneyToInt((float)$amount); |
|
179 | + $amount = $amount === '' ? 0 : $this->localeService->convertMoneyToInt((float) $amount); |
|
181 | 180 | |
182 | 181 | $amount > 0 ? |
183 | - $this->depositService->saveDepositAmount($this->pool, $this->session, $receivableId, $amount): |
|
184 | - $this->depositService->deleteDeposit($this->pool, $this->session, $receivableId); |
|
182 | + $this->depositService->saveDepositAmount($this->pool, $this->session, $receivableId, $amount) : $this->depositService->deleteDeposit($this->pool, $this->session, $receivableId); |
|
185 | 183 | |
186 | 184 | return $this->page(); |
187 | 185 | } |
@@ -193,7 +191,7 @@ discard block |
||
193 | 191 | */ |
194 | 192 | public function delDeposit(int $receivableId) |
195 | 193 | { |
196 | - if($this->session->closed) |
|
194 | + if ($this->session->closed) |
|
197 | 195 | { |
198 | 196 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
199 | 197 | return $this->response; |
@@ -209,12 +207,12 @@ discard block |
||
209 | 207 | */ |
210 | 208 | public function addAllDeposits() |
211 | 209 | { |
212 | - if($this->session->closed) |
|
210 | + if ($this->session->closed) |
|
213 | 211 | { |
214 | 212 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
215 | 213 | return $this->response; |
216 | 214 | } |
217 | - if(!$this->pool->deposit_fixed) |
|
215 | + if (!$this->pool->deposit_fixed) |
|
218 | 216 | { |
219 | 217 | return $this->response; |
220 | 218 | } |
@@ -229,12 +227,12 @@ discard block |
||
229 | 227 | */ |
230 | 228 | public function delAllDeposits() |
231 | 229 | { |
232 | - if($this->session->closed) |
|
230 | + if ($this->session->closed) |
|
233 | 231 | { |
234 | 232 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
235 | 233 | return $this->response; |
236 | 234 | } |
237 | - if(!$this->pool->deposit_fixed) |
|
235 | + if (!$this->pool->deposit_fixed) |
|
238 | 236 | { |
239 | 237 | return $this->response; |
240 | 238 | } |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | $this->target()->args()[0] : $this->bag('meeting')->get('pool.id'); |
54 | 54 | $this->pool = $this->poolService->getPool($poolId); |
55 | 55 | |
56 | - if(!$this->session || !$this->pool || $this->session->disabled($this->pool)) |
|
56 | + if (!$this->session || !$this->pool || $this->session->disabled($this->pool)) |
|
57 | 57 | { |
58 | 58 | $this->notify->error(trans('tontine.session.errors.disabled'), trans('common.titles.error')); |
59 | 59 | $this->pool = null; |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | ]); |
74 | 74 | $this->response->html('meeting-remitments', $html); |
75 | 75 | |
76 | - if(!$this->pool->remit_planned) |
|
76 | + if (!$this->pool->remit_planned) |
|
77 | 77 | { |
78 | 78 | $this->jq('#btn-add-remitment')->click($this->rq()->addRemitment(0)); |
79 | 79 | } |
@@ -104,12 +104,12 @@ discard block |
||
104 | 104 | */ |
105 | 105 | public function createRemitment(int $payableId) |
106 | 106 | { |
107 | - if($this->session->closed) |
|
107 | + if ($this->session->closed) |
|
108 | 108 | { |
109 | 109 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
110 | 110 | return $this->response; |
111 | 111 | } |
112 | - if(!$this->pool->remit_planned || $this->pool->remit_auction) |
|
112 | + if (!$this->pool->remit_planned || $this->pool->remit_auction) |
|
113 | 113 | { |
114 | 114 | // Only when remitments are planned and without auctions. |
115 | 115 | return $this->response; |
@@ -122,7 +122,7 @@ discard block |
||
122 | 122 | |
123 | 123 | public function addRemitment(int $payableId) |
124 | 124 | { |
125 | - if($this->session->closed) |
|
125 | + if ($this->session->closed) |
|
126 | 126 | { |
127 | 127 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
128 | 128 | return $this->response; |
@@ -143,7 +143,7 @@ discard block |
||
143 | 143 | 'title' => trans('common.actions.cancel'), |
144 | 144 | 'class' => 'btn btn-tertiary', |
145 | 145 | 'click' => 'close', |
146 | - ],[ |
|
146 | + ], [ |
|
147 | 147 | 'title' => trans('common.actions.save'), |
148 | 148 | 'class' => 'btn btn-primary', |
149 | 149 | 'click' => $this->rq()->saveRemitment(pm()->form('remitment-form')), |
@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | */ |
160 | 160 | public function saveRemitment(array $formValues) |
161 | 161 | { |
162 | - if($this->session->closed) |
|
162 | + if ($this->session->closed) |
|
163 | 163 | { |
164 | 164 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
165 | 165 | $this->dialog->hide(); |
@@ -189,7 +189,7 @@ discard block |
||
189 | 189 | */ |
190 | 190 | public function deleteRemitment(int $payableId) |
191 | 191 | { |
192 | - if($this->session->closed) |
|
192 | + if ($this->session->closed) |
|
193 | 193 | { |
194 | 194 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
195 | 195 | return $this->response; |
@@ -82,7 +82,7 @@ discard block |
||
82 | 82 | */ |
83 | 83 | public function addRefund() |
84 | 84 | { |
85 | - if($this->session->closed) |
|
85 | + if ($this->session->closed) |
|
86 | 86 | { |
87 | 87 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
88 | 88 | return $this->response; |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | 'title' => trans('common.actions.cancel'), |
96 | 96 | 'class' => 'btn btn-tertiary', |
97 | 97 | 'click' => 'close', |
98 | - ],[ |
|
98 | + ], [ |
|
99 | 99 | 'title' => trans('common.actions.save'), |
100 | 100 | 'class' => 'btn btn-primary', |
101 | 101 | 'click' => $this->rq()->createRefund(pm()->form('refund-form')), |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | */ |
112 | 112 | public function createRefund(array $formValues) |
113 | 113 | { |
114 | - if($this->session->closed) |
|
114 | + if ($this->session->closed) |
|
115 | 115 | { |
116 | 116 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
117 | 117 | return $this->response; |
@@ -135,7 +135,7 @@ discard block |
||
135 | 135 | */ |
136 | 136 | public function deleteRefund(int $refundId) |
137 | 137 | { |
138 | - if($this->session->closed) |
|
138 | + if ($this->session->closed) |
|
139 | 139 | { |
140 | 140 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
141 | 141 | return $this->response; |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | */ |
93 | 93 | public function createRefund(string $debtId) |
94 | 94 | { |
95 | - if($this->session->closed) |
|
95 | + if ($this->session->closed) |
|
96 | 96 | { |
97 | 97 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
98 | 98 | return $this->response; |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | */ |
110 | 110 | public function deleteRefund(int $debtId) |
111 | 111 | { |
112 | - if($this->session->closed) |
|
112 | + if ($this->session->closed) |
|
113 | 113 | { |
114 | 114 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
115 | 115 | return $this->response; |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | $chargeId = $this->target()->method() === 'home' ? |
61 | 61 | $this->target()->args()[0] : $this->bag('meeting')->get('charge.id'); |
62 | 62 | $this->charge = $this->chargeService->getCharge($chargeId); |
63 | - if($this->session !== null && $this->charge !== null) |
|
63 | + if ($this->session !== null && $this->charge !== null) |
|
64 | 64 | { |
65 | 65 | $this->target = $this->targetService->getTarget($this->charge, $this->session); |
66 | 66 | } |
@@ -96,7 +96,7 @@ discard block |
||
96 | 96 | */ |
97 | 97 | public function page(int $pageNumber = 0) |
98 | 98 | { |
99 | - if($this->target === null) |
|
99 | + if ($this->target === null) |
|
100 | 100 | { |
101 | 101 | return $this->response; |
102 | 102 | } |
@@ -136,16 +136,16 @@ discard block |
||
136 | 136 | */ |
137 | 137 | public function add() |
138 | 138 | { |
139 | - if($this->session->closed) |
|
139 | + if ($this->session->closed) |
|
140 | 140 | { |
141 | 141 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
142 | 142 | return $this->response; |
143 | 143 | } |
144 | - if($this->session === null || $this->charge === null) |
|
144 | + if ($this->session === null || $this->charge === null) |
|
145 | 145 | { |
146 | 146 | return $this->response; |
147 | 147 | } |
148 | - if($this->target !== null) |
|
148 | + if ($this->target !== null) |
|
149 | 149 | { |
150 | 150 | return $this->response; |
151 | 151 | } |
@@ -158,7 +158,7 @@ discard block |
||
158 | 158 | 'title' => trans('common.actions.cancel'), |
159 | 159 | 'class' => 'btn btn-tertiary', |
160 | 160 | 'click' => 'close', |
161 | - ],[ |
|
161 | + ], [ |
|
162 | 162 | 'title' => trans('common.actions.save'), |
163 | 163 | 'class' => 'btn btn-primary', |
164 | 164 | 'click' => $this->rq()->create(pm()->form('target-form')), |
@@ -177,16 +177,16 @@ discard block |
||
177 | 177 | */ |
178 | 178 | public function create(array $formValues) |
179 | 179 | { |
180 | - if($this->session->closed) |
|
180 | + if ($this->session->closed) |
|
181 | 181 | { |
182 | 182 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
183 | 183 | return $this->response; |
184 | 184 | } |
185 | - if($this->session === null || $this->charge === null) |
|
185 | + if ($this->session === null || $this->charge === null) |
|
186 | 186 | { |
187 | 187 | return $this->response; |
188 | 188 | } |
189 | - if($this->target !== null) |
|
189 | + if ($this->target !== null) |
|
190 | 190 | { |
191 | 191 | return $this->response; |
192 | 192 | } |
@@ -208,12 +208,12 @@ discard block |
||
208 | 208 | */ |
209 | 209 | public function edit() |
210 | 210 | { |
211 | - if($this->session->closed) |
|
211 | + if ($this->session->closed) |
|
212 | 212 | { |
213 | 213 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
214 | 214 | return $this->response; |
215 | 215 | } |
216 | - if($this->target === null) |
|
216 | + if ($this->target === null) |
|
217 | 217 | { |
218 | 218 | return $this->response; |
219 | 219 | } |
@@ -227,7 +227,7 @@ discard block |
||
227 | 227 | 'title' => trans('common.actions.cancel'), |
228 | 228 | 'class' => 'btn btn-tertiary', |
229 | 229 | 'click' => 'close', |
230 | - ],[ |
|
230 | + ], [ |
|
231 | 231 | 'title' => trans('common.actions.save'), |
232 | 232 | 'class' => 'btn btn-primary', |
233 | 233 | 'click' => $this->rq()->update(pm()->form('target-form')), |
@@ -247,12 +247,12 @@ discard block |
||
247 | 247 | */ |
248 | 248 | public function update(array $formValues) |
249 | 249 | { |
250 | - if($this->session->closed) |
|
250 | + if ($this->session->closed) |
|
251 | 251 | { |
252 | 252 | $this->notify->warning(trans('meeting.warnings.session.closed')); |
253 | 253 | return $this->response; |
254 | 254 | } |
255 | - if($this->target === null) |
|
255 | + if ($this->target === null) |
|
256 | 256 | { |
257 | 257 | return $this->response; |
258 | 258 | } |
@@ -274,11 +274,11 @@ discard block |
||
274 | 274 | */ |
275 | 275 | public function remove() |
276 | 276 | { |
277 | - if($this->session === null || $this->charge === null) |
|
277 | + if ($this->session === null || $this->charge === null) |
|
278 | 278 | { |
279 | 279 | return $this->response; |
280 | 280 | } |
281 | - if($this->target === null) |
|
281 | + if ($this->target === null) |
|
282 | 282 | { |
283 | 283 | return $this->response; |
284 | 284 | } |