Lines 202-208
function KohaTable(id_selector, dt_parameters, table_settings, add_filters) {
Link Here
|
202 |
|
202 |
|
203 |
if ( table_settings ) { |
203 |
if ( table_settings ) { |
204 |
if ( table_settings.hasOwnProperty('default_display_length') && table_settings['default_display_length'] != null ) { |
204 |
if ( table_settings.hasOwnProperty('default_display_length') && table_settings['default_display_length'] != null ) { |
205 |
new_parameters["pageLength"] = table_settings['default_display_length']; |
205 |
// pageLength needs to be a number, not a string, or it can cause issues with DataTable's next button. |
|
|
206 |
new_parameters["pageLength"] = parseInt(table_settings['default_display_length']); |
206 |
} |
207 |
} |
207 |
if ( table_settings.hasOwnProperty('default_sort_order') && table_settings['default_sort_order'] != null ) { |
208 |
if ( table_settings.hasOwnProperty('default_sort_order') && table_settings['default_sort_order'] != null ) { |
208 |
new_parameters["order"] = [[ table_settings['default_sort_order'], 'asc' ]]; |
209 |
new_parameters["order"] = [[ table_settings['default_sort_order'], 'asc' ]]; |
209 |
- |
|
|