Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
kohinos-tav
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
6
Merge Requests
6
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
agplv3
kohinos-tav
Commits
e0cdca17
Commit
e0cdca17
authored
Sep 30, 2024
by
Yvon Kerdoncuff
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cosmetic
parent
856eb656
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
7 deletions
+12
-7
PaymentController.php
src/Controller/PaymentController.php
+12
-7
No files found.
src/Controller/PaymentController.php
View file @
e0cdca17
...
@@ -32,13 +32,14 @@ class PaymentController extends AbstractController
...
@@ -32,13 +32,14 @@ class PaymentController extends AbstractController
protected
$guardHandler
;
protected
$guardHandler
;
protected
$paymentUtils
;
protected
$paymentUtils
;
public
function
__construct
(
EntityManagerInterface
$em
,
public
function
__construct
(
EntityManagerInterface
$em
,
TranslatorInterface
$translator
,
TranslatorInterface
$translator
,
LoginAuthenticator
$authenticator
,
LoginAuthenticator
$authenticator
,
GuardAuthenticatorHandler
$guardHandler
,
GuardAuthenticatorHandler
$guardHandler
,
Payum
$payum
,
Payum
$payum
,
PaymentUtils
$paymentUtils
)
PaymentUtils
$paymentUtils
{
)
{
$this
->
em
=
$em
;
$this
->
em
=
$em
;
$this
->
translator
=
$translator
;
$this
->
translator
=
$translator
;
$this
->
payum
=
$payum
;
$this
->
payum
=
$payum
;
...
@@ -55,7 +56,8 @@ class PaymentController extends AbstractController
...
@@ -55,7 +56,8 @@ class PaymentController extends AbstractController
// Enregistre les données du Flux en json, pour l'enregistrer une fois le paiement validé
// Enregistre les données du Flux en json, pour l'enregistrer une fois le paiement validé
$serializer
=
$this
->
container
->
get
(
'serializer'
);
$serializer
=
$this
->
container
->
get
(
'serializer'
);
$toSerialize
=
Payment
::
TYPE_ADHESION
==
$type
?
$form
->
get
(
'cotisation'
)
->
getData
()
:
$form
->
getData
();
$toSerialize
=
Payment
::
TYPE_ADHESION
==
$type
?
$form
->
get
(
'cotisation'
)
->
getData
()
:
$form
->
getData
();
$data
=
$serializer
->
normalize
(
$toSerialize
,
$data
=
$serializer
->
normalize
(
$toSerialize
,
null
,
null
,
[
AbstractNormalizer
::
ATTRIBUTES
=>
[
[
AbstractNormalizer
::
ATTRIBUTES
=>
[
'reference'
,
'reference'
,
...
@@ -75,7 +77,8 @@ class PaymentController extends AbstractController
...
@@ -75,7 +77,8 @@ class PaymentController extends AbstractController
'expediteur'
=>
[
'id'
],
'expediteur'
=>
[
'id'
],
'destinataire'
=>
[
'id'
],
'destinataire'
=>
[
'id'
],
'operateur'
=>
[
'id'
],
],
'operateur'
=>
[
'id'
],
],
]);
]
);
$jsondata
=
$serializer
->
serialize
(
$data
,
'json'
);
$jsondata
=
$serializer
->
serialize
(
$data
,
'json'
);
...
@@ -325,9 +328,11 @@ class PaymentController extends AbstractController
...
@@ -325,9 +328,11 @@ class PaymentController extends AbstractController
$this
->
translator
->
trans
(
'Cotisation payée !'
)
$this
->
translator
->
trans
(
'Cotisation payée !'
)
);
);
}
}
}
elseif
(
GetHumanStatus
::
STATUS_CANCELED
==
$payment
->
getStatus
()
||
}
elseif
(
GetHumanStatus
::
STATUS_CANCELED
==
$payment
->
getStatus
()
||
GetHumanStatus
::
STATUS_EXPIRED
==
$payment
->
getStatus
()
||
GetHumanStatus
::
STATUS_EXPIRED
==
$payment
->
getStatus
()
||
GetHumanStatus
::
STATUS_FAILED
==
$payment
->
getStatus
())
{
GetHumanStatus
::
STATUS_FAILED
==
$payment
->
getStatus
()
)
{
$this
->
addFlash
(
$this
->
addFlash
(
'error'
,
'error'
,
$this
->
translator
->
trans
(
'La transaction a été annulée.'
)
$this
->
translator
->
trans
(
'La transaction a été annulée.'
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment