-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #159 from xendit/TPI-8191/bss-va
add BSS VA
- Loading branch information
Showing
21 changed files
with
255 additions
and
32 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
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
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,27 @@ | ||
<?php | ||
|
||
namespace Xendit\M2Invoice\Model\Payment; | ||
|
||
use Magento\Quote\Api\Data\CartInterface; | ||
|
||
/** | ||
* Class BSSVA | ||
* @package Xendit\M2Invoice\Model\Payment | ||
*/ | ||
class BSSVA extends AbstractInvoice | ||
{ | ||
/** | ||
* Payment Method feature | ||
* | ||
* @var bool | ||
*/ | ||
protected $_isInitializeNeeded = true; | ||
|
||
/** | ||
* Payment code | ||
* | ||
* @var string | ||
*/ | ||
protected $_code = 'bssva'; | ||
protected $methodCode = 'BSS'; | ||
} |
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,29 @@ | ||
<?xml version="1.0"?> | ||
<include xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Config:etc/system_include.xsd"> | ||
<group id="bssva" translate="label" type="text" sortOrder="150" showInDefault="1" showInWebsite="1" showInStore="1"> | ||
<label>BSS</label> | ||
<field id="active" translate="label comment" sortOrder="1" type="select" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1"> | ||
<label>Enable</label> | ||
<source_model>Magento\Config\Model\Config\Source\Yesno</source_model> | ||
<config_path>payment/bssva/active</config_path> | ||
</field> | ||
<field id="title" translate="label" type="text" sortOrder="20" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1"> | ||
<label>Title</label> | ||
<config_path>payment/bssva/title</config_path> | ||
</field> | ||
<field id="description" translate="label" type="textarea" sortOrder="30" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1"> | ||
<label>Description</label> | ||
<config_path>payment/bssva/description</config_path> | ||
</field> | ||
<field id="min_order_total" translate="label" type="text" sortOrder="50" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1"> | ||
<label>Minimum Order Total</label> | ||
<frontend_class>validate-zero-or-greater</frontend_class> | ||
<config_path>payment/bssva/min_order_total</config_path> | ||
</field> | ||
<field id="max_order_total" translate="label" type="text" sortOrder="50" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1"> | ||
<label>Maximum Order Total</label> | ||
<frontend_class>validate-zero-or-greater</frontend_class> | ||
<config_path>payment/bssva/max_order_total</config_path> | ||
</field> | ||
</group> | ||
</include> |
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
<?xml version="1.0"?> | ||
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd"> | ||
<module name="Xendit_M2Invoice" setup_version="9.0.1" active="true"></module> | ||
<module name="Xendit_M2Invoice" setup_version="10.0.0" active="true"></module> | ||
</config> |
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,34 @@ | ||
<?php | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
?> | ||
<script> | ||
require([ | ||
'uiLayout', | ||
'jquery' | ||
], function (layout, $) { | ||
$(function () { | ||
var paymentMethodData = { | ||
method: 'bssva' | ||
}; | ||
layout([ | ||
{ | ||
component: 'Xendit_M2Invoice/js/view/payment/method-renderer/multishipping/bssva', | ||
name: 'payment_method_bssva', | ||
method: paymentMethodData.method, | ||
item: paymentMethodData | ||
} | ||
]); | ||
|
||
if(window.checkoutConfig.payment[paymentMethodData.method].image != ""){ | ||
$("label[for=p_method_"+paymentMethodData.method+"]") | ||
.prepend('<img class="xendit-payment-icon" src="'+window.checkoutConfig.payment[paymentMethodData.method].image+'" />'); | ||
} | ||
|
||
$('body').trigger('contentUpdated'); | ||
}) | ||
}) | ||
</script> | ||
<!-- ko template: getTemplate() --><!-- /ko --> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
Oops, something went wrong.