Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
C
commerce_moneris
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Custom Issue Tracker
Custom Issue Tracker
Labels
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Analytics
Analytics
Code Review
Insights
Issue
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
project
commerce_moneris
Commits
2747ce35
Commit
2747ce35
authored
Jun 24, 2019
by
git
Committed by
rbrownell
Jun 24, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue
#3063729
by embeau, rbrownell: Error bad character content for element 'amount'
parent
aaaf20df
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
src/Plugin/Commerce/PaymentGateway/Onsite.php
src/Plugin/Commerce/PaymentGateway/Onsite.php
+3
-3
No files found.
src/Plugin/Commerce/PaymentGateway/Onsite.php
View file @
2747ce35
...
...
@@ -110,7 +110,7 @@ class Onsite extends OnsitePaymentGatewayBase implements OnsiteInterface {
$this
->
assertPaymentMethod
(
$payment_method
);
$amount
=
$payment
->
getAmount
();
$number
=
$amount
->
getNumber
(
);
$number
=
number_format
(
$amount
->
getNumber
(),
2
);
$payment_method_token
=
$payment_method
->
getRemoteId
();
$moneris_order_id
=
$payment
->
getOrderId
()
.
'-'
.
$payment
->
uuid
()
.
'-'
.
date
(
"dmy-G:i:s"
);
...
...
@@ -151,7 +151,7 @@ class Onsite extends OnsitePaymentGatewayBase implements OnsiteInterface {
$this
->
assertPaymentState
(
$payment
,
[
'authorization'
]);
// If not specified, capture the entire amount.
$amount
=
$amount
?:
$payment
->
getAmount
();
$number
=
$amount
->
getNumber
(
);
$number
=
number_format
(
$amount
->
getNumber
(),
2
);
$remote_id
=
explode
(
'|'
,
$payment
->
getRemoteId
());
...
...
@@ -235,7 +235,7 @@ class Onsite extends OnsitePaymentGatewayBase implements OnsiteInterface {
// Validate the requested amount.
$this
->
assertRefundAmount
(
$payment
,
$amount
);
$number
=
$amount
->
getNumber
(
);
$number
=
number_format
(
$amount
->
getNumber
(),
2
);
$remote_id
=
explode
(
'|'
,
$payment
->
getRemoteId
());
...
...
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