10000 fix: Make sure that the latest version is opened from the page overvi… · django-cms/django-cms@dfb0483 · GitHub
[go: up one dir, main page]

Skip to content

Commit dfb0483

Browse files
committed
fix: Make sure that the latest version is opened from the page overview in admin
Without applying .latest_content() on the queryset it could happen that an old version was opened when clicking on the eye icon of a page in the pages overview.
1 parent 233790a commit dfb0483

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cms/admin/pageadmin.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1303,7 +1303,7 @@ def get_tree(self, request):
13031303
Prefetch(
13041304
"pagecontent_set",
13051305
to_attr="filtered_translations",
1306-
queryset=PageContent.admin_manager.get_queryset(),
1306+
queryset=PageContent.admin_manager.get_queryset().latest_content(),
13071307
),
13081308
)
13091309
rows = self.get_tree_rows(

0 commit comments

Comments
 (0)
0