DataTables / DataTables/FixedHeader

When assign scrollY:500, then value shifted from valued columns. after click on any column, working fine.

Open
#102 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
73
Forks
83
Avg merge
4m
Merged PRs (30d)
1

Description

table = $('#OrderMargin-data-table').DataTable({
data: data.AllData,
colReorder: true,
select: true,
scrollX: true,
scrollY: 430,
"scrollCollapse": true,
deferRender: true,
"searching": false,
autoWidth: false,
"columns": [
{ "title": "Discount", "data": "Discount", "searchable": true, width: '120px', className: "text-right", },
{ "title": "Deduction", "data": "Deduction", "searchable": true, width: '120px', className: "text-right", },
{ "title": "Fuel Cost", "data": "FuelCost", "searchable": true, width: '100px', className: "text-right", },
{ "title": "Gross Margin", "data": "GrossMargin", "searchable": true, width: '120px', className: "text-right", }

                    ],
                    "order": [],
                    dom: '<"datatable-header"fl><"datatable-scroll-lg"t><"datatable-footer"ip>',
                    language: {
                        search: '_INPUT_',
                        lengthMenu: '<span>Show:</span> _MENU_',
                        paginate: { 'first': 'First', 'last': 'Last', 'next': '&rarr;', 'previous': '&larr;' }
                    },                           
                    "lengthMenu": [[9, 25, 50, -1], [8, 25, 50, "All"]],
                   
                });

dt

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the supplied DataTables configuration and reproduce the issue using colReorder, select, scrollX, and scrollY: 430. Compare the displayed values before and after clicking a column; done means the values remain aligned with their columns without requiring a click.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.