Opencart发票货币

时间:2013-04-20 06:21:49

标签: opencart currency invoice

您好我在使用Opencart 1.5.5.1时遇到了问题。

我设定的货币在结帐流程中运作良好,我不希望它被更改。

我收到订单后打印发票我需要将货币更改为固定货币(当然是美元)因为货运代理需要任何发票以国际货运为单位。

理想的做法是在生成要打印的发票时轻松切换结账货币和美元。

我已找到并修改此vqmod以使用当前的opencart版本

<modification>
    <id><![CDATA[Invoice in base currency]]></id>
    <version><![CDATA[1.0.0]]></version>
    <vqmver><![CDATA[]]></vqmver>
    <author><![CDATA[Abhishek Tiwari]]></author>
    <file name="admin/controller/sale/order.php">
        <operation>
            <search position="replace"><![CDATA['price'    => $this->currency->format($product['price'] + ($this->config->get('config_tax') ? $product['tax'] : 0), $order_info['currency_code'], $order_info['currency_value']),]]></search>
            <add><![CDATA['price'    => $this->currency->format($product['price'] + ($this->config->get('config_tax') ? $product['tax'] : 0), $this->currency->getCode(), $this->currency->getValue()),]]></add>
        </operation>
        <operation>
            <search position="replace"><![CDATA['total'    => $this->currency->format($product['total'] + ($this->config->get('config_tax') ? ($product['tax'] * $product['quantity']) : 0), $order_info['currency_code'], $order_info['currency_value'])]]></search>
            <add><![CDATA['total'    => $this->currency->format($product['total']+ ($this->config->get('config_tax') ? ($product['tax'] * $product['quantity']) : 0), $this->currency->getCode(), $this->currency->getValue())]]></add>
        </operation>
        <operation>
            <search position="after"><![CDATA[$total_data = $this->model_sale_order->getOrderTotals($order_id);]]></search>
            <add><![CDATA[foreach ($total_data as &$total) {
          $total['text'] = $this->currency->format($total['value'], $this->currency->getCode(), $this->currency->getValue());
        }]]></add>
        </operation>
    </file>
</modification>

只要我了解它应该获得默认商店货币来生成发票但它不适合我。 现在我的基础货币是欧元,但如果我真的尝试将其更改为美元,则统计数据中显示的所有金额都不是转换器,而只是更改货币符号!

0 个答案:

没有答案