uc_order doesn't make use of drupal's path API to generate a multilingual link for the invoice pop-up on the customer order page. The patch addresses this issue by generating the link with url() instead.
The patch also includes a quick fix to make order statuses appear translated on the customer order overview page. However, it would be nice to have the standard order statuses (in checkout, pending, processing, ...) translatable by default in a drupal-ish way.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | 402640.use_url.2.x.patch | 1.1 KB | cha0s |
| uc_order.admin_.inc_.patch | 1.57 KB | account-deletion-needed |
Comments
Comment #1
tr commentedHi,
1. Could you explain more about what url() does to fix things here? Would l() work too? Are there other places in Ubercart that could benefit from this change?
2. t() is only supposed to wrap string literals, so what your patch does (t($order->title)) is the wrong way to go about accomplishing what you want. Read http://www.ubercart.org/faq/8123 and http://drupal.org/node/191810 for a very brief explanation of how to translate these things in a manner compliant with Drupal standards.
Comment #2
account-deletion-needed commented1. url() allows other modules to rewrite the URL to take into account things such as language prefixes. l() does the same thing as url(), except that it returns a fully themed HTML link, whereas url() returns the raw URL. As for other places in Ubercart, I'm not sure, only found this place so far.
2. OK thanks I'll have a look.
Comment #3
cha0s commentedI rolled another patch with only the URL change.
Comment #4
Island Usurper commentedLooks good to me. Thanks, and committed.