forked from craigchristenson/magento2-2checkout
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CSP whitelist and inline onestep support
- Loading branch information
1 parent
ee3c836
commit fbc9126
Showing
7 changed files
with
80 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?php | ||
|
||
namespace Tco\Checkout\Model; | ||
|
||
/** | ||
* @api | ||
* @since 100.0.2 | ||
*/ | ||
class InlineType implements \Magento\Framework\Option\ArrayInterface | ||
{ | ||
/** | ||
* @return array|array[] | ||
*/ | ||
public function toOptionArray() | ||
{ | ||
return [['value' => 'inline-one-step', 'label' => __('One step inline')], ['value' => 'inline', 'label' => __('Multi step inline')]]; | ||
} | ||
|
||
/** | ||
* @return array | ||
*/ | ||
public function toArray() | ||
{ | ||
return ['inline-one-step' => __('One step inline'), 'inline' => __('Multi step inline')]; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?xml version="1.0"?> | ||
<csp_whitelist xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Csp:etc/csp_whitelist.xsd"> | ||
<policies> | ||
<policy id="script-src"> | ||
<values> | ||
<value id="2co" type="host">https://secure.2checkout.com</value> | ||
<value id="2pay" type="host">https://2pay-js.2checkout.com</value> | ||
<value id="avangate" type="host">https://secure.avangate.com</value> | ||
</values> | ||
</policy> | ||
<policy id="frame-src"> | ||
<values> | ||
<value id="2co" type="host">https://secure.2checkout.com</value> | ||
<value id="2pay" type="host">https://2pay-js.2checkout.com</value> | ||
<value id="avangate" type="host">https://secure.avangate.com</value> | ||
</values> | ||
</policy> | ||
<policy id="img-src"> | ||
<values> | ||
<value id="2co" type="host">https://secure.2checkout.com</value> | ||
<value id="2pay" type="host">https://2pay-js.2checkout.com</value> | ||
<value id="avangate" type="host">https://secure.avangate.com</value> | ||
</values> | ||
</policy> | ||
</policies> | ||
</csp_whitelist> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters