Problem with translation files
-
Hello.
I’m testing ERP 1.17.10 on WordPress 7.1.2 and the translation files generated by translate.wordpress.org (I tried with Spanish) and I noticed the following.
The “Accounting”, “Create Invoice” and “Settings” screens are not displayed and the following errors are reported in the browser console:
For "Accounting":
[Error] SyntaxError: JSON Parse error: Unrecognized token '\'
parse (admin.php:762)
Codice globale (admin.php:762)
[Error] ReferenceError: Can't find variable: erpAcct
798 (bootstrap.js:1:73282)
o (vendor.js:1:417)
797 (bootstrap.js:1:71767)
o (vendor.js:1:417)
(funzione anonima) (vendor.js:1:288)
Codice globale (bootstrap.js:1)
[Error] ReferenceError: Can't find variable: __
(funzione anonima) (admin.js:1:3918)
o (vendor.js:1:417)
(funzione anonima) (admin.js:1:467)
o (vendor.js:1:417)
(funzione anonima) (admin.js:1:168955)
o (vendor.js:1:417)
(funzione anonima) (admin.js:1:478946)
o (vendor.js:1:417)
(funzione anonima) (admin.js:1:470554)
o (vendor.js:1:417)
(funzione anonima) (admin.js:1:383639)
o (vendor.js:1:417)
(funzione anonima) (vendor.js:1:288)
Codice globale (admin.js:1)
For "Settings":
[Error] SyntaxError: JSON Parse error: Unrecognized token '\'
parse (admin.php:18)
Codice globale (admin.php:18)
[Error] SyntaxError: JSON Parse error: Unrecognized token '\'
parse (admin.php:768)
Codice globale (admin.php:768)
[Error] ReferenceError: Can't find variable: erpLocale
(funzione anonima) (i18n.js:821:90)
__webpack_require__ (i18n.js:20)
(funzione anonima) (i18n.js:63)
Codice globale (i18n.js:64)
[Error] ReferenceError: Can't find variable: erpSettings
348 (erp-settings-bootstrap.js:1:19171)
o (vendor.js:1:417)
347 (erp-settings-bootstrap.js:1:17774)
o (vendor.js:1:417)
(funzione anonima) (vendor.js:1:288)
Codice globale (erp-settings-bootstrap.js:1)
[Error] ReferenceError: Can't find variable: __
(funzione anonima) (erp-settings.js:1:4275)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1:258)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1:6682)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1:997)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1:4522)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1:122943)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1:180747)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1:178632)
o (vendor.js:1:417)
(funzione anonima) (erp-settings.js:1:147888)
o (vendor.js:1:417)
(funzione anonima) (vendor.js:1:288)
Codice globale (erp-settings.js:1)At the moment, the only solution that seems to work is to replace the
scriptcontained in thefunction erp_accounting_page()in the file /modules/accounting/includes/Classes/Admin.php with this command:window.erpAcct = {};and the
scriptcontained in the file /includes/Settings/views/settings.php with this command:window.erpSettings = {};Thanks.
You must be logged in to reply to this topic.