salesagility / SuiteCRM-Portal-Joomla

Joomla Plugin for the SuiteCRM Portal
GNU General Public License v2.0
22 stars 21 forks source link

Navigation and actions not translated on joomla site #18

Open horus68 opened 7 years ago

horus68 commented 7 years ago

There are several jQuery strings not translated

Last
Next
Previuos
No data available in table
Showing 0 to 0 of 0 entries
Processing...
Loading...
No matching records found

The file is: \site\js\jquery.dataTables.1.9.4.min.js

oPaginate:{sFirst:"First",sLast:"Last",sNext:"Next",sPrevious:"Previous"},sEmptyTable:"No data available in table",sInfo:"Showing _START_ to _END_ of _TOTAL_ entries",sInfoEmpty:"Showing 0 to 0 of 0 entries",sInfoFiltered:"(filtered from _MAX_ total entries)",sInfoPostFix:"",sInfoThousands:",",sLengthMenu:"Show _MENU_ entries",sLoadingRecords:"Loading...",sProcessing:"Processing...",sSearch:"Search:",sUrl:"",sZeroRecords:"No matching records found"},oSearch:h.extend({},j.models.oSearch),sAjaxDataProp:"aaData",

So how can we translate this? 2017-01-05 20_20_40-microsoft edge

chris001 commented 7 years ago

It's easy, this requires a variable which is already set to the English name for language the user has selected, for example, Spanish, Latvian, German, Japanese, French, etc. The languages for this datatable can be either loaded dynamically, or pre-loaded locally at installation time onto the CRM server, better option because some organizations (bank etc) don't allow unrestricted random internet downloads from their crm server. Details and code example: https://datatables.net/plug-ins/i18n/