-
Notifications
You must be signed in to change notification settings - Fork 459
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Datatable nav terms translations #1451
Conversation
More Locatizations for 2.4.0. versions
best form with spaces
Changes added to translate dataTable nav terms following model of FamilyList.php
@@ -370,6 +370,22 @@ | |||
</a> | |||
</div> | |||
|
|||
<script type="text/javascript"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
while this will work It will end up initializing the DataTable twice - because you still have the "data-table" class assigned to the <table>
DOM element.
I think the better solution would be to modify the DataTable initializer bound to the class so that all .data-table
classed objects will include translation terms
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sorry, i understand that it will call. I understand that your solution keep the system more organized, but it isn't working in the translation view point.
There are various .js with code to translation that not working as, for example, GroupView.php.
I think that we need talk about this because I don't know what i need make.
I see so many types of implementatios:
- all code in PHP and table render by DataTable - all translated
- table header terms in PHP and render and some processing in JS - table header translated and nav maybe
- all in JS and nothing in PHP - table header not translated and nav probabily no
- and all types above with "language" clause in php file (nav translated) and other with these clauses in .JS file (nav not translated)
See, for english user, it don't care because interface has the same efect. But, for translated user each interface appear with a diferent face.
Sorry, but it is terrible...
I found various issues about subject:
DataTables use in #227
datatable : Internationalisation plug-ins #1141 -> DataTables Navterms
Untranslated terms in 2.30-RC1: #1207 -> arround the title
Update DataTables to latest and include localization files #1237 -> To suport #1141 and #1207
I realy need a solution, a way that i can folow
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
data-table
class does not really do anything without the JS block... we don't have a common code for data classes as lots of the data-table have extra params and you can only init it once
responsive: true, | ||
"dom": 'T<"clear">lfrtip', | ||
"tableTools": { | ||
"sSwfPath": "//cdn.datatables.net/tabletools/2.2.3/swf/copy_csv_xls_pdf.swf" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do you need the export :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry, i don't understand ... i copied from FamilyList.php
I need study this more
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think no ...
Did tableTools refer to export?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"tableTools": {
+ "sSwfPath": "//cdn.datatables.net/tabletools/2.2.3/swf/copy_csv_xls_pdf.swf"
will show the export to cvs xls or pdf
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, i don't need ... but i try exclude this part and translation don't work
Datatable nav terms translations