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
7f205197
Commit
7f205197
authored
Nov 25, 2024
by
Yvon Kerdoncuff
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
payment hot fix : $p->getCreatedAt() does not always exist
parent
807a021d
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
PaymentRepository.php
src/Repository/PaymentRepository.php
+4
-0
No files found.
src/Repository/PaymentRepository.php
View file @
7f205197
...
...
@@ -63,6 +63,9 @@ class PaymentRepository extends ServiceEntityRepository
$p
->
setStartingPaymentAnalysisStatus
(
'NOT CONCERNED'
);
continue
;
}
if
(
!
$p
->
getCreatedAt
())
{
$p
->
setStartingPaymentAnalysisStatus
(
'TIMEOUT'
);
}
else
{
$createdAt
=
clone
$p
->
getCreatedAt
();
//don't modify original object
$timeout
=
$createdAt
->
add
(
\DateInterval
::
createFromDateString
(
"10 minutes"
));
if
(
$timeout
<
new
\DateTime
())
{
...
...
@@ -71,6 +74,7 @@ class PaymentRepository extends ServiceEntityRepository
return
$timeout
;
}
}
}
//Note : some fields updates are done in this method to exclude non-candidate payment from future research.
//We may not want to flush here so flushing will probably not occur when an ongoing starting payment is found,
//but it will occur only when the payment process succeeds, which is fine.
...
...
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