Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Paygate Module like Authorize - some Questions about request model and parameter delimiter and others
 
mzentrale1
Guru
 
Total Posts:  731
Joined:  2007-12-06
Stuttgart, Germany
 

Hi,

i want to extend may Payment-Module by a Paygate Module. I started to extend my module with code examples from authorizenet, all works fine, my request query is build and i can send my request to paymentprovider and i get responce. But i have two Problems. I made a request-model like request model of authorizenet to set my request parameters. for example i set parameter

$request Mage::getModel('heidelpaydebitadvice/request')
            ->
setSecuritySender('xxxxyyyyyxxxxxzzzzyyyyy');

This will be transformed to SECURITY_SENDER=xxxxyyyyyxxxxxzzzzyyyyy, i need a transformation to SECURITY.SENDER=xxxxyyyyyxxxxxzzzzyyyyy. Where can i set the delimiter from _ to .?

Within my _buildRequest method there is following code:

class Mage_Heidelpaydebitadvice_Model_Heidelpaydebitadvice extends Mage_Payment_Model_Method_Abstract{
    
protected function _buildRequest(Varien_Object $payment)
    
{
        $document 
$payment->getDocument();#
        /*......*/
        
$billing $document->getBillingAddress();
        
$request->setNameGiven($billing->getFirstname())
            ->
setNameFamily($billing->getLastname());
    
}
}

During authorization i get following error-message:
Call to a member function getBillingAddress() on a non-object in

Within my paygate i need some additional Information: Need the store/selected currency, how can i get it?

How someone can help me.

KR

Stefan

 
Magento Community Magento Community
Magento Community
Magento Community
 
mzentrale1
Guru
 
Total Posts:  731
Joined:  2007-12-06
Stuttgart, Germany
 

Hi,

partial solved problem - instead of returning an object in _buildRequest iam returning an array.

KR

Stefan

 
Magento Community Magento Community
Magento Community
Magento Community
 
mzentrale1
Guru
 
Total Posts:  731
Joined:  2007-12-06
Stuttgart, Germany
 

Hi,

second problem also solved, i used following code to get billing address data

$order $payment->getOrder();
$billing $order->getBillingAddress();

$billing->getFirstname();
.
.
.
.

cheers

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top