-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Labels
needs to be backportedCommits need to be backportedCommits need to be backported
Description
Description
show_menu
will show children of inactive nodes despite setting extra_inactive
to 0.
Given a page tree like:
+ P1
| + P2
| + P3
| + P9
| + P10
| + P11
Rendering {% show_menu 1 100 0 1 %}
on P2 will also render the children of P9.
This is because:
- The
from_level
is subtracted fromextra_inactive
- and the negative number is not caught by the check that cuts the children.
Steps to reproduce
Set up a page structure like above and test with a show menu call like above.
Expected behaviour
The expected behaviour is that P2, P3 and P9 are rendered on page P2 given the above page tree (which is an excerpt from the ExtendedFixturesMenuTests
.
Actual behaviour
All sibling's children are rendered.
Additional information (CMS/Python/Django versions)
Present in latest Django CMS 5.1.0dev1.
Do you want to help fix this issue?
A PR with test will be added.
Metadata
Metadata
Assignees
Labels
needs to be backportedCommits need to be backportedCommits need to be backported