Skip to content

Commit

Permalink
Update of payment method InvoiceB2B.
Browse files Browse the repository at this point in the history
  • Loading branch information
Timon Rönisch committed Apr 4, 2016
1 parent 0ff18cd commit 9de2f7a
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion app/code/community/Wirecard/CheckoutPage/Helper/Data.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
class Wirecard_CheckoutPage_Helper_Data extends Mage_Payment_Helper_Data
{

protected $_pluginVersion = '4.0.3';
protected $_pluginVersion = '4.0.4';
protected $_pluginName = 'Wirecard/CheckoutPage';

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ abstract class Wirecard_CheckoutPage_Model_Abstract extends Mage_Payment_Model_M
protected $_defaultLocale = 'en';

protected $_order;
protected $_pluginVersion = '4.0.3';
protected $_pluginVersion = '4.0.4';
protected $_pluginName = 'Wirecard/CheckoutPage';

protected $_formBlockType = 'wirecard_checkoutpage/form';
Expand Down
8 changes: 3 additions & 5 deletions app/code/community/Wirecard/CheckoutPage/Model/Invoiceb2b.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,10 @@ public function isAvailable($quote = null)
}

$billingAddress = $quote->getBillingAddress();
if (strlen($billingAddress->getCompany()))
return true;

$vat_id = $billingAddress->getData('vat_id');
if (!strlen($vat_id))
if (!strlen($billingAddress->getCompany()))
{
return false;
}

return parent::isAvailable($quote);
}
Expand Down
2 changes: 1 addition & 1 deletion app/code/community/Wirecard/CheckoutPage/etc/config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
<config>
<modules>
<wirecard_checkoutpage>
<version>4.0.3</version>
<version>4.0.4</version>
</wirecard_checkoutpage>
</modules>
<global>
Expand Down

0 comments on commit 9de2f7a

Please sign in to comment.