firegento-pdf icon indicating copy to clipboard operation
firegento-pdf copied to clipboard

Payment Method Title M2E Pro

Open agentlucky opened this issue 9 years ago • 6 comments

I use the m2e pro extension and do import the orders from eBay. On the invoice appears the Payment Method Title "M2E Pro Payment" but not the actual Payment Method from eBay like PayPal. When i change to the standard Magento PDF Engine everything works fine, though... How can i solve this problem?

Thanks in advance

agentlucky avatar Aug 12 '15 09:08 agentlucky

I can only give you a short code snippet how you can get the "real" payment method (it is not from me), but you would have to implement that in your own engine, see the FAQ.

$paymentInfo = Mage::helper('payment')->getInfoBlock($order->getPayment())
    ->setIsSecureMode(true)
    ->toPdf();
$payment = explode('{{pdf_row_separator}}', $paymentInfo);
foreach ($payment as $key=>$value) {
    if (strip_tags(trim($value)) == '') {
        unset($payment[$key]);
    } else {
        $payment[$key] = strip_tags(trim($value));
    }
}
$paymentMethodArray = $this->_prepareText(
    $payment[0], $page, $font, 10, $width
);
$paymentMethod = array_shift($paymentMethodArray);

@Schrank should we implement something like that in the default engine?

sprankhub avatar Aug 12 '15 10:08 sprankhub

Thanks for the quick reply. I kind of tried to do so but i failed. It's definitely too "much" for me. Hopefully you'll implement this into the plugin soon. But thank you anyways...

agentlucky avatar Aug 12 '15 10:08 agentlucky

This is horrible code and I hope, there is a better way to do this. But I think we should implement this. Might help for Billpay, etc. too.

Schrank avatar Sep 10 '15 14:09 Schrank

btw, if you want to sponsor this implementation, it can be done a lot faster.

Schrank avatar Sep 10 '15 16:09 Schrank

Do you see a time range to provide this update? Or can you explain step by step how we can install your code to fix this problem?

tommy83 avatar Feb 18 '16 15:02 tommy83

As for the free part, I don't think this will happen in the near future unbfortunately.I can only speak for myself, but I have more paid work to do, then I can handle currently - I assume it is the same with @sprankhub.

If you are interested in contracting some one, please feel free to send us an email, this motivates a lot :-)

Schrank avatar Feb 18 '16 15:02 Schrank