Open Schrank opened 6 years ago
Did you test this @Schrank? I just tested it and it does not change anything for me. The "Shipping & Handling Tax" is still shown separately and does not show any tax rate. Are you sure this works @nige-one?
No, I just added it and then left the room :) (no joke)
It works like a charm for me. Just tested it again, dropped my XML totals extension from https://github.com/firegento/firegento-pdf/issues/316#issuecomment-225514966 and copied the new file from the PR.
Maybe a configuration issue. Here is mine:
Note the overridden fields, which do not seem to take affect, since everything is still working as expected in the B2C configuration. This installation is version 1.9.3.6.
By the way: I changed
public function __getCalculatedTaxes()
{
return array();
}
to
public function _getCalculatedTaxes()
{
return $this->_getTaxHelper()->getCalculatedTaxes($this->getSource());
}
I really can't remember why at the moment, but I think it has something to do with rendering the order itself as PDF to use it as order confirmation. Probably this addresses https://github.com/firegento/firegento-pdf/pull/297#issuecomment-160663808 as well.
@nige-one could you provide a screenshot of the totals section of the invoice PDF? Mine looks like this:
As you can see, it still dows not show the tax rate of the shipping and handling tax.
Ok, I have to extend my answer.
Shipping tax and value of goods taxes get only summed up if you return an empty array for both functions _getShippingTax()
and _getCalculatedTaxes()
.
So @Schrank's PR should lead to the wanted behaviour.
Thanks @nige-one