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

Rows are not displayed #1811

Open
luis-cosillo opened this issue Oct 5, 2024 · 1 comment
Open

Rows are not displayed #1811

luis-cosillo opened this issue Oct 5, 2024 · 1 comment
Labels
feature request Use to ask for feature request stale Used to close issues for inactivity (by bot)

Comments

@luis-cosillo
Copy link

luis-cosillo commented Oct 5, 2024

me html

Cliente Descripcion
Estado
Documento Otro Documento
Fecha 1 Fecha 2
Monto 1 Monto 2
nombre 1 nombre 2
Tipo Serie
Indicadores
{{ item.codCli }} | {{ item.nombreCliente }} {{ item.codSin }} | {{ item.claveNotificacion }} | {{ item.numSin }}
{{ item.documento }} {{ item.otroDocumento }}
{{ getFecha(item.fecha1) }} {{ getFecha(item.fecha2) }}
{{ formatNumberPrefix(item.pendiente, 2) }} {{ formatNumberPrefix(item.pagado, 2) }}
{{ item.nombre1 }} {{ item.nombre 2}}
{{ item.tipo }} {{ item.serie }}
menu commit

and me code:
datosDataTable() {
const that = this;
let lastPage = this._notificacion.pageIndex * this._notificacion.pageSize;
this.dtOptions = {
...this._global.parametrosDatatable(),
displayStart: lastPage,
serverSide: true,
processing: true,
searching: false,
paging: true,
pageLength: this._notificacion.pageSize,
ajax: (dataTablesParameters: any, callback, settings) => {
lastPage = dataTablesParameters.start;
const _page: number = dataTablesParameters.start / dataTablesParameters.length;
this._notificacion.pageIndex = _page;

            const respuesta = this._busqueda.filtrosProcesar();

            const _filtro: ResultFilters = {
                pagina: this._notificacion.pageIndex,
                filas: this._notificacion.pageSize,
                textFilter: this._busqueda.textoFiltrado,
                esAsegurado: this._notificacion.opcionEsCliente,
                filters: respuesta,
            };

            this._notificacion.getSiniestros(_filtro).subscribe({
                next: _lista => {
                    this._notificacion.totalRegistros = _lista.recordsTotal;
                    this._notificacion.totalPaginas = _lista.totalPaginas;
                    this.listaSiniestros = _lista.data;

                    console.log('dataTablesParameters: ', dataTablesParameters);
                    console.log('listaSiniestros: ', _lista.data);
                    console.log('settings: ', settings);

                    this.actualizaColorNotificacion();
                    callback({
                        draw: dataTablesParameters.draw,
                        recordsTotal: this._notificacion.totalRegistros,
                        recordsFiltered: this._notificacion.totalRegistros,
                    });
                },
                error: error => {
                    this.listaSiniestros = [];

                    this._global.mostrarNotificacion(
                        glob.enumTipoNotificacion.errores,
                        this.getTituloPantalla(),
                        'Error al obtener los datos',
                        '.main-content'
                    );

                    callback({
                        draw: dataTablesParameters.draw,
                        recordsTotal: 0,
                        recordsFiltered: 0,
                        data: [],
                    });
                },
            });
        },
        columnDefs: [
            { orderable: false, targets: 0, className: 'largo_info_cliente' },
            { orderable: true, targets: 1, className: 'largo_etapas' },
            { orderable: true, targets: 2, className: 'largo_columnas' },
            { orderable: true, targets: 3, className: 'largo_columnas' },
            { orderable: true, targets: 4, className: 'largo_columnas' },
            { orderable: true, targets: 5, className: 'largo_info_ajustador' },
            { orderable: true, targets: 6, className: 'largo_columnas' },
            { orderable: false, targets: 7, className: 'largo_columnas' },
        ],
        scrollX: true,
        responsive: false,
    };
}

It stopped working after updating and the html ng-for doesn't render the rows now

@luis-cosillo luis-cosillo added the feature request Use to ask for feature request label Oct 5, 2024
Copy link

stale bot commented Jan 31, 2025

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale Used to close issues for inactivity (by bot) label Jan 31, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature request Use to ask for feature request stale Used to close issues for inactivity (by bot)
Projects
None yet
Development

No branches or pull requests

1 participant