0

既存の RML レポートを変更するモジュールを作成しました。RML ファイルを変更するだけです (Python の変更はありません)。

モジュールをインストールした後、新しいレポートを印刷できました。しかし、.potファイルをエクスポートして翻訳しようとすると、ファイルが空でした。理由はわかりませんが、最終的に翻訳ファイルを手動で作成する必要がありました。

現在、用語は 1 つを除いて大きく翻訳されています。次の文:

<para style="terp_default_8">[[ (o.comment and format(o.comment)) or "Please, indicate the invoice number on the concept of income" ]]</para>

動作している他の用語とまったく同じように、翻訳ファイル ( es.po ) に追加しました。

#. module: customized_reports_03
#: report:account.invoice.custom:0
msgid "Please, indicate the invoice number on the concept of income"
msgstr "Por favor, indique el número de factura en el concepto del ingreso"

翻訳を読み込んで何度か更新しましたが、この文は翻訳されていません。

なんで?オペレーターのせいかもしれません

4

1 に答える 1

1

最後に、[[ ]] の間に書いた文字列が翻訳ファイルで認識されていないことに気付きました。これを管理するには、文字列が二重括弧の外にあるコードを使用して同じ動作を実現する方法を見つける必要があります。

私の場合、問題は次のように解決されます。

<para style="terp_default_8">[[ (o.comment and format(o.comment)) or removeParentNode('para') ]]</para>
<para style="terp_default_8">Please, indicate the invoice number on the concept of income[[ not o.comment and '.' or removeParentNode('para') ]]</para>
于 2015-02-06T08:31:22.897 に答える