Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

257
Vistas
How to prevent pagination reset in datatable using global configuration?

How to stay on the same page of datatables after data changes when the table is reloaded? I've managed to persist datatable state after page refresh globally using

$.extend(true, $.fn.dataTable.defaults, {
    "bStateSave": true,

in plugins/datatables/plugins/bootstrap/datatables.bootstrap.js. BTW, is it a good solution to modify the code of the plugin itself?

But the datatable keeps resetting after I modify any row. Then I've managed to persist the page using table.ajax.reload(null, false). My goal is to apply this behaviour globally in the project without modifying each of the pages (there are about 700 occurences of table.ajax.reload() in the project). Adding

$.extend(true, $.fn.dataTable, {
  "ajax": {
      "reload": {
          "callback": null,
          "resetPaging": false
        }
    }
});

in plugins/datatables/plugins/bootstrap/datatables.bootstrap.js haven't done the trick.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda