Bug 39080

Summary: Table headers of holds to pull table are incorrect size on scroll
Product: Koha Reporter: Lisette Scheer <lisette>
Component: Staff interfaceAssignee: Jonathan Druart <jonathan.druart>
Status: Pushed to main --- QA Contact: Marcel de Rooy <m.de.rooy>
Severity: minor    
Priority: P5 - low CC: gmcharlt, jonathan.druart, m.de.rooy, martin.renvoize, pedro.amorim
Version: MainKeywords: rel_24_11_candidate
Hardware: All   
OS: All   
GIT URL: Change sponsored?: ---
Patch complexity: Trivial patch Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
25.05.00
Circulation function:
Bug Depends on: 36640    
Bug Blocks:    
Attachments: title example
Bug 39080: Redraw the table after we added the column filters
Bug 39080: Adjust the fixed header after we added the column filters
Bug 39080: Adjust the fixed header after we added the column filters
Bug 39080: Adjust the fixed header after we added the column filters

Description Lisette Scheer 2025-02-10 18:16:53 UTC
Created attachment 177707 [details]
title example

After the datatable updates the header of the "title" column doesn't keep the correct width when you scroll down, so everything is off that's to the right of it.
Comment 1 Jonathan Druart 2025-02-11 09:29:36 UTC
Created attachment 177726 [details] [review]
Bug 39080: Redraw the table after we added the column filters

If a column contains a dropdown list (for libraries for instance), the
width of the column will be modified, but DT won't redraw the table and
the offset will be kept on horizontal scroll.

Test plan:
One example where this problem can be observed is the "holds to pull"
table: "Title" is followed by "Libraries".
Test without and with the patch, and confirm that the display/offset is fixed.
Comment 2 Owen Leonard 2025-02-11 12:45:34 UTC
This is not working for me. I still get the alignment problem. Curiously, if I hide or show a column using the columns dropdown the alignment is fixed.
Comment 3 Jonathan Druart 2025-02-11 13:06:47 UTC
Created attachment 177730 [details] [review]
Bug 39080: Adjust the fixed header after we added the column filters

If a column contains a dropdown list (for libraries for instance), the
width of the column will be modified, but DT's fixed header need to be
adjusted.

Test plan:
One example where this problem can be observed is the "holds to pull"
table: "Title" is followed by "Libraries".
Test without and with the patch, and confirm that the display/offset is fixed.
Comment 4 Jonathan Druart 2025-02-11 13:07:14 UTC
Hum indeed. I didn't understand why the patch was fixing the problem. I certainly have tested incorrectly!

I think this second patch is fixing the problem correctly.
Comment 5 David Nind 2025-02-13 21:51:37 UTC
Created attachment 178054 [details] [review]
Bug 39080: Adjust the fixed header after we added the column filters

If a column contains a dropdown list (for libraries for instance), the
width of the column will be modified, but DT's fixed header need to be
adjusted.

Test plan:
One example where this problem can be observed is the "holds to pull"
table: "Title" is followed by "Libraries".
Test without and with the patch, and confirm that the display/offset is fixed.

Signed-off-by: David Nind <david@davidnind.com>
Comment 6 Marcel de Rooy 2025-02-14 08:08:14 UTC
Created attachment 178078 [details] [review]
Bug 39080: Adjust the fixed header after we added the column filters

If a column contains a dropdown list (for libraries for instance), the
width of the column will be modified, but DT's fixed header need to be
adjusted.

Test plan:
One example where this problem can be observed is the "holds to pull"
table: "Title" is followed by "Libraries".
Test without and with the patch, and confirm that the display/offset is fixed.

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 7 Katrin Fischer 2025-02-17 14:07:28 UTC
Pushed for 25.05!

Well done everyone, thank you!
Comment 8 Pedro Amorim 2025-06-11 16:05:23 UTC
Please backport to 24.11.