@@ -129,7 +129,7 @@ discard block |
||
| 129 | 129 | $project_name = mb_ereg_replace("([^\w\s\d\-_~,;\[\]\(\).])", '', $project_name); |
| 130 | 130 | $project_name = mb_ereg_replace("([\.]{2,})", '', $project_name); |
| 131 | 131 | //Format: "ZA000001 Project Name.pdf" |
| 132 | - $filename = $prefix.$payment_order->getIDString().' '.$project_name.'.'.$extension; |
|
| 132 | + $filename = $prefix . $payment_order->getIDString() . ' ' . $project_name . '.' . $extension; |
|
| 133 | 133 | |
| 134 | 134 | $data[$filename] = $path; |
| 135 | 135 | |
@@ -146,7 +146,7 @@ discard block |
||
| 146 | 146 | |
| 147 | 147 | return ZIPBinaryFileResponseFacade::createZIPResponseFromFiles( |
| 148 | 148 | $data, |
| 149 | - 'Belege_'.date('Y-m-d_H-i-s').'.zip'); |
|
| 149 | + 'Belege_' . date('Y-m-d_H-i-s') . '.zip'); |
|
| 150 | 150 | } |
| 151 | 151 | |
| 152 | 152 | public function configureCrud(Crud $crud): Crud |
@@ -315,32 +315,32 @@ discard block |
||
| 315 | 315 | ]); |
| 316 | 316 | |
| 317 | 317 | $emailAction = Action::new('sendEmail', 'payment_order.action.email', 'fas fa-envelope') |
| 318 | - ->linkToUrl(function (PaymentOrder $paymentOrder) { |
|
| 318 | + ->linkToUrl(function(PaymentOrder $paymentOrder) { |
|
| 319 | 319 | return $this->mailToGenerator->generateContactMailLink($paymentOrder); |
| 320 | 320 | }) |
| 321 | 321 | ->setCssClass('btn btn-secondary text-dark'); |
| 322 | 322 | |
| 323 | 323 | //Hide action if no contact emails are associated with department |
| 324 | - $emailAction->displayIf(function (PaymentOrder $paymentOrder) { |
|
| 324 | + $emailAction->displayIf(function(PaymentOrder $paymentOrder) { |
|
| 325 | 325 | return null !== $this->mailToGenerator->generateContactMailLink($paymentOrder); |
| 326 | 326 | }); |
| 327 | 327 | |
| 328 | 328 | $hhv_action = Action::new('contactHHV', 'payment_order.action.contact_hhv', 'fas fa-comment-dots') |
| 329 | - ->linkToUrl(function (PaymentOrder $paymentOrder) { |
|
| 329 | + ->linkToUrl(function(PaymentOrder $paymentOrder) { |
|
| 330 | 330 | return $this->mailToGenerator->getHHVMailLink($paymentOrder); |
| 331 | 331 | }) |
| 332 | 332 | ->setCssClass('btn btn-secondary text-dark'); |
| 333 | 333 | |
| 334 | 334 | $resend_confirmation_action = Action::new('resendConfirmation', 'payment_order.action.resend_confirmation', 'fas fa-redo') |
| 335 | 335 | ->linkToCrudAction('resendConfirmationEmail') |
| 336 | - ->displayIf(function (PaymentOrder $paymentOrder) { |
|
| 336 | + ->displayIf(function(PaymentOrder $paymentOrder) { |
|
| 337 | 337 | return $this->isGranted('ROLE_EDIT_PAYMENT_ORDERS') && !$paymentOrder->isConfirmed(); |
| 338 | 338 | }) |
| 339 | 339 | ->setCssClass('btn btn-secondary text-dark'); |
| 340 | 340 | |
| 341 | 341 | $mathematically_correct_action = Action::new('mathematicallyCorrect', 'payment_order.action.mathematically_correct', 'fas fa-check') |
| 342 | 342 | ->linkToCrudAction('checkMathematicallyCorrect') |
| 343 | - ->displayIf(function (PaymentOrder $paymentOrder) { |
|
| 343 | + ->displayIf(function(PaymentOrder $paymentOrder) { |
|
| 344 | 344 | return $this->isGranted('ROLE_PO_MATHEMATICALLY') |
| 345 | 345 | && $paymentOrder->isConfirmed() |
| 346 | 346 | && !$paymentOrder->isMathematicallyCorrect(); |
@@ -349,7 +349,7 @@ discard block |
||
| 349 | 349 | |
| 350 | 350 | $factually_correct_action = Action::new('factuallyCorrect', 'payment_order.action.factually_correct', 'fas fa-check') |
| 351 | 351 | ->linkToCrudAction('checkFactuallyCorrect') |
| 352 | - ->displayIf(function (PaymentOrder $paymentOrder) { |
|
| 352 | + ->displayIf(function(PaymentOrder $paymentOrder) { |
|
| 353 | 353 | return $this->isGranted('ROLE_PO_FACTUALLY') |
| 354 | 354 | && $paymentOrder->isConfirmed() |
| 355 | 355 | && !$paymentOrder->isFactuallyCorrect() |
@@ -359,12 +359,12 @@ discard block |
||
| 359 | 359 | |
| 360 | 360 | $manual_confirmation = Action::new('manual_confirmation', 'payment_order.action.manual_confirmation', 'fas fa-exclamation-triangle') |
| 361 | 361 | ->setCssClass('btn btn-secondary') |
| 362 | - ->linkToRoute('payment_order_manual_confirm', function (PaymentOrder $paymentOrder) { |
|
| 362 | + ->linkToRoute('payment_order_manual_confirm', function(PaymentOrder $paymentOrder) { |
|
| 363 | 363 | return [ |
| 364 | 364 | 'id' => $paymentOrder->getId(), |
| 365 | 365 | ]; |
| 366 | 366 | }) |
| 367 | - ->displayIf(function (PaymentOrder $paymentOrder) { |
|
| 367 | + ->displayIf(function(PaymentOrder $paymentOrder) { |
|
| 368 | 368 | return $this->isGranted('ROLE_MANUAL_CONFIRMATION') |
| 369 | 369 | && !$paymentOrder->isConfirmed(); |
| 370 | 370 | }); |
@@ -377,7 +377,7 @@ discard block |
||
| 377 | 377 | |
| 378 | 378 | $actions->disable(Crud::PAGE_NEW); |
| 379 | 379 | |
| 380 | - if(!$this->isGranted('ROLE_EDIT_PAYMENT_ORDERS')) { |
|
| 380 | + if (!$this->isGranted('ROLE_EDIT_PAYMENT_ORDERS')) { |
|
| 381 | 381 | $actions->disable('batchDelete'); |
| 382 | 382 | } |
| 383 | 383 | |