Jump to content

From where does this fault comes from


Recommended Posts

Hey all

 

I have a strange problem and can't find a solution. I'am working PS 1.6.0.11 with the default template.

Please take a look at the screenshot below.

 

post-873637-0-91710000-1428768682_thumb.jpg

 

As you can see the invoice is made in english via the english Frontoffice. Therefor everything's fine except the word "Banküberweisung" below the payment method. Normally it should be "Bank wire" ...

 

Problem No. 1 - i have no idea from where this come from. With the translations in the bank wire module everythings ok. I'am just wondering why it is "Banküberweisung" if I'am in the english FO.

 

Therefor I made a test with the COD (Cash on Delivery) in the FO. First order in english and second order in german.

As you can see below everythings fine.

post-873637-0-23992700-1428769915_thumb.jpg

post-873637-0-76651100-1428769915_thumb.jpg

 

Also a check in the database (ps_order_payment) ... everythings fine.

 

post-873637-0-04639900-1428770027_thumb.jpg

 

But take a look at this ...

 

post-873637-0-63623900-1428770088_thumb.jpg

 

It doesn't matter if I'am in english in the Front Office, if I make an order, "Banküberweisung" will be written to the database instead of Bank wire.

 

Does somebody know which part of prestashop is responsible for this?

 

Thanks for any help

 

 

Link to comment
Share on other sites

Thanks, just checked it but it didn't work quiet well. This is code that is actually used in the invoice.tpl

 

{foreach from=$order_invoice->getOrderPaymentCollection() item=payment}
                {$payment->payment_method}
            {foreachelse}
                {if $payment->payment_method == 'PrePayment'}
                    {l s='PrePayment' pdf='true'}
                {else}
                    {l s='Invoice' pdf='true'}
                {/if}
            {/foreach}

 

I changed the 4th and 5th line to this ...

 

   {if $order->payment == 'Banküberweisung'}

       {l s='Banküberweisung' pdf='true'}

 

But i take no effect. It seems that the foreach Clause above will be handled before.

 

Therefor I changed the total code to this:

 

   {if $order->payment == 'Banküberweisung'}

       {l s='Bank wire' pdf='true'}

                {else}
                    {l s='Invoice' pdf='true'}
                {/if}

 

Now it takes effect, but not as expected. I get "Invoice" in the the Payment Method instead of "Bank wire"

Furthermore by taking out the foreach clause, all the rest payment methods do not take effect.

 

Where i got "COD" in earlier invoices, everywhere is writte "Invoice" which is clear because taken out the foreach Clause.

 

What's also strange, that in the database table ps_order_payment  only "Banküberweisung" appears even when I'am in english FO

 

Hm, I have no idea what to do

Edited by kalua (see edit history)
Link to comment
Share on other sites

As I cannot answer in German Forum so I answer here your second question for database: Banküberweisung is written into dabatase but only for the order, , cause your main shop language is German, BUT not for payment (module) row which is always English (software language). If the main language of your shop is Portuguese or English for ex. than into database is written Portuguese translated or English translated. See screen attached.

post-741527-0-71500800-1428843745_thumb.jpg

Edited by selectshop.at (see edit history)
Link to comment
Share on other sites

Hey

 

Thanks for your reply. So far so clear, but I have also foreign languages in the table row.

If a place an order in english languag in FO with Payment "Cash on Delivery (COD) i get this entry also in the database ps_order_payment

Take a look at this ...

post-873637-0-85636800-1428855475_thumb.jpg

 

As you can see COD will be written in german and english depends on the actual language in the FO.
But with Bank Wire .. i everytime get "Banküberweisung" in the tablerow, it doesn't matter if I'am on english or german.

Thats strange!! Isnt it?

 

Link to comment
Share on other sites

No, it is not strange. Basically what is written into database is the language your shop is set. If it is set to localization EN than the entry in DB is EN. If it is set to DE, than the entry is DE, if it is set to PT, than the entry is PT. This is independent of the customer language.

 

If you want your invoice printed in customer's language, so there is a fix you can find in the English Forum as well: https://www.prestashop.com/forums/topic/396155-need-to-display-double-currency-and-change-pdf-language/?do=findComment&comment=2011871

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...