Skip to content
This repository was archived by the owner on Feb 2, 2025. It is now read-only.
This repository was archived by the owner on Feb 2, 2025. It is now read-only.

dtOptions: DataTables.Settings - ignored #1628

@giuseppemorale

Description

@giuseppemorale

🪲 bug report

DataTables Options not working.
Tried to change Language (and others) with DataTables.Settings, it doesn't work

🔬 Minimal Reproduction

StackBlitz/GitHub Link:

Step-by-step Instructions:

🎱 Expected behavior

Language Datatable Italian

📷 Screenshots

I've created a service to manage DataTables (i've also tried in component)

service

ngOnInit in component:

ngOnInit

Table Result:

dataTable

Html:

component-html

🌐 Your Environment

  • NodeJS version: v12.22.5
  • Angular version: 13.1.0
  • Angular CLI version: 13.1.0
  • jQuery version: 3.6.0
  • DataTables version: 1.11.3
  • angular-datatables version: 13.0.1

📝 Additional context

CODE PASSED TO SETTINGS:


public tableOptions: DataTables.Settings =  {
        pagingType: 'full_numbers',
        pageLength: 10,
        language: {
            emptyTable: "Nessun dato presente nella tabella",
            info: "Vista da _START_ a _END_ di _TOTAL_ elementi",
            infoEmpty: "Vista da 0 a 0 di 0 elementi",
            infoFiltered: "(filtrati da _MAX_ elementi totali)",
            infoPostFix: "",
            lengthMenu: "Visualizza _MENU_ elementi",
            loadingRecords: "Caricamento...",
            processing: "",
            search: "Cerca:",
            zeroRecords: "La ricerca non ha portato alcun risultato.",
            paginate: {
                first: "Inizio",
                previous: "Precedente",
                next: "Successivo",
                last: "Fine"
            },
            aria: {
                sortAscending: ": attiva per ordinare la colonna in ordine crescente",
                sortDescending: ": attiva per ordinare la colonna in ordine decrescente"
            }
      }
}

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions