Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
crefopay
WooCommerce
Commits
0e4320c8
Commit
0e4320c8
authored
Dec 20, 2018
by
Vincent Mrose
💬
Browse files
Merge branch 'hotfix/checkout'
parents
5d5c7c81
1766b739
Changes
2
Hide whitespace changes
Inline
Side-by-side
upg/class-wc-gateway-hostedPayments.php
View file @
0e4320c8
...
...
@@ -59,19 +59,21 @@ class WC_Gateway_Hosted_Payments extends WC_Payment_Gateway
* Yes: The additional gender field will not be required
* No: The additional gender field will be added to checkout page
*/
if
(
!
array_key_exists
(
'billing_title'
,
$fields
[
'billing'
])
&&
!
in_array
(
'Anrede'
,
$fields
[
'billing'
][
'billing_title'
]))
{
$newBillingFields
[
'billing_payco_gender'
]
=
array
(
'label'
=>
__
(
'Gender'
,
'upg'
),
'type'
=>
'select'
,
'required'
=>
1
,
'clear'
=>
false
,
'options'
=>
array
(
\
Upg\Library\Request\Objects\Person
::
SALUTATIONMALE
=>
__
(
'Male'
,
$this
->
id
),
\
Upg\Library\Request\Objects\Person
::
SALUTATIONFEMALE
=>
__
(
'Female'
,
$this
->
id
),
),
'priority'
=>
9
,
);
if
(
!
array_key_exists
(
'billing_title'
,
$fields
[
'billing'
]))
{
if
(
!
is_array
(
$fields
[
'billing'
][
'billing_title'
])
||
!
in_array
(
'Anrede'
,
$fields
[
'billing'
][
'billing_title'
]))
{
$newBillingFields
[
'billing_payco_gender'
]
=
array
(
'label'
=>
__
(
'Gender'
,
'upg'
),
'type'
=>
'select'
,
'required'
=>
1
,
'clear'
=>
false
,
'options'
=>
array
(
\
Upg\Library\Request\Objects\Person
::
SALUTATIONMALE
=>
__
(
'Male'
,
$this
->
id
),
\
Upg\Library\Request\Objects\Person
::
SALUTATIONFEMALE
=>
__
(
'Female'
,
$this
->
id
),
),
'priority'
=>
9
,
);
}
}
$checkoutFields
=
$fields
[
'billing'
];
...
...
upg/upg.php
View file @
0e4320c8
...
...
@@ -2,7 +2,7 @@
/**
* Plugin Name: CrefoPay für WooCommerce
* Description: Die Komplettlösung für Ihre Zahlungsabwicklung.
* Version: 2.4.
1
* Version: 2.4.
2
* Author: CrefoPayment GmbH & Co. KG
* Text Domain: upg
*/
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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