Skip to content

fix(pat-structure): Fix ordering logic.#1552

Merged
thet merged 1 commit intomasterfrom
thet/structure-ordering
Mar 10, 2026
Merged

fix(pat-structure): Fix ordering logic.#1552
thet merged 1 commit intomasterfrom
thet/structure-ordering

Conversation

@thet
Copy link
Member

@thet thet commented Mar 9, 2026

The logic to set orderable columns in the structure pattern was quite wrong:

  • The very first and second-to-last columns were set to no ordering. This PR fixes it to the very first (selection checkboxes) and very last column (actions column).

  • The very first column was set for a default, ascending ordering. This went unnoticed, as the checkbox cells all have the same order information. This PR sets no initial ordering, as we want the order position in the container set as the default ordering.

Fixes: #1551

Now:
image

Before:

Image
  • I signed and returned the Plone Contributor Agreement, and received and accepted an invitation to join a team in the Plone GitHub organization.
  • I verified there aren't any other open pull requests for the same change.
  • I followed the guidelines in Contributing to Plone.
  • I successfully ran code quality checks on my changes locally.
  • I successfully ran tests on my changes locally.
  • If needed, I added new tests for my changes.
  • If needed, I added documentation for my changes.
  • I included a change log entry in my commits.

If your pull request closes an open issue, include the exact text below, immediately followed by the issue number. When your pull request gets merged, then that issue will close automatically.

Closes #

@thet thet requested a review from petschki March 9, 2026 21:30
@thet thet force-pushed the thet/structure-ordering branch from b7acb40 to 2593ee0 Compare March 9, 2026 21:33
The logic to set orderable columns in the structure pattern was quite
wrong:

- The very first and second-to-last columns were set to no ordering.
  This PR fixes it to the very first (selection checkboxes) and very
  last column (actions column).

- The very first column was set for a default, ascending ordering. This
  went unnoticed, as the checkbox cells all have the same order
  information. This PR sets no initial ordering, as we want the order
  position in the container set as the default ordering.

Fixes: #1551
@thet thet force-pushed the thet/structure-ordering branch from 2593ee0 to 57cd7dd Compare March 10, 2026 16:22
@petschki
Copy link
Member

/run-coredev-robottests

Copy link
Member

@petschki petschki left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hm ... somehow I have the feeling my coredev-robottests workflow doesn't use our checkedout plone.staticresources (see https://github.com/plone/mockup/actions/runs/22912898220/job/66490022037#step:13:44) ... need to look that up.

but for this one LGTM!

@thet thet merged commit a6854cf into master Mar 10, 2026
3 checks passed
@thet thet deleted the thet/structure-ordering branch March 10, 2026 19:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

pat-structure: incorrect sorting headers

2 participants