Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] cannot delete page #7830

Open
1 of 2 tasks
im-n1 opened this issue Mar 4, 2024 · 10 comments
Open
1 of 2 tasks

[BUG] cannot delete page #7830

im-n1 opened this issue Mar 4, 2024 · 10 comments

Comments

@im-n1
Copy link

im-n1 commented Mar 4, 2024

Description

Cannot delete a page.

Steps to reproduce

  1. fresh installation of 4.1 + one superuser account
  2. create a home page
  3. create a subpage
  4. open admin
  5. navigate to "Page contents"
  6. under burger menu on the very end of a page table row "Delete..."
  7. no-persmissions page

Expected behaviour

To be able to delete a page.

Actual behaviour

Cannot delete a page.

Screenshots

image

Translation: Deleting an item of type page "" would result in the deletion of related items. However, you do not have permission to delete items of the following types:

Additional information (CMS/Python/Django versions)

Do you want to help fix this issue?

  • Yes, I want to help fix this issue and I will join #workgroup-pr-review on Slack to confirm with the community that a PR is welcome.
  • No, I only want to report the issue.
@im-n1
Copy link
Author

im-n1 commented Mar 4, 2024

Temporary workaround is via versioning: Page content versions -> choose the page -> submit -> Discard the version (page gets entirely deleted).

@fsbraun
Copy link
Sponsor Member

fsbraun commented Mar 4, 2024

Thanks for bringing this to our attention. Can you check if this persists if you set your user language to English? (I'm trying to hunt down the reason for this message.)

@fsbraun
Copy link
Sponsor Member

fsbraun commented Mar 4, 2024

(Potentially is a duplicate of #7745, fixed in #7747 - to be verified)

@aacimov
Copy link

aacimov commented Mar 14, 2024

@im-n1 I also had problems with versioning and deleting the whole page, what helped was adding to settings.py:

DJANGOCMS_VERSIONING_ALLOW_DELETING_VERSIONS = True

Maybe you will find it helpful.

@im-n1
Copy link
Author

im-n1 commented Mar 25, 2024

@aacimov sadly no luck - the "confirmation delete page" still has no submit button.

On top of that https://github.com/django-cms/djangocms-versioning/blob/master/docs/settings.rst is empty so I have absolutely no info.

@aacimov
Copy link

aacimov commented Mar 25, 2024

@im-n1 have you tried going to Page content versions - select your desired page from the dropdown and delete all of the versions? After that you should be able to delete the whole page.

If this does not help try pulling the page on the root level (side-by-side with your Homepage) and then try it.

Let us know.

@im-n1
Copy link
Author

im-n1 commented Mar 26, 2024

@aacimov yes that works - actually that's the way I used before and is the only way to delete a page. But the reported problem persists.

@aacimov
Copy link

aacimov commented Mar 26, 2024

@aacimov yes that works - actually that's the way I used before and is the only way to delete a page. But the reported problem persists.

Well, from my perspective this is a good thing since if you have users editing the page you don't want them to accidentally delete the whole page (I had this experience before). So double-action is a good thing from my end. I would not consider it a bug but actually a feature.

If they are certain, they should first delete all the versions and then the actual page.

To be honest I first looked at this as you are, but on the other hand it is a 2FA, haha.

@im-n1
Copy link
Author

im-n1 commented Mar 27, 2024

That might be a good point but there are 2 things that tell me that the current solution is bad:

  1. why show an icon next to a page for deleting when the action simply doesn't work?
  2. the "accidental" page deletion can happen and that's exactly why there is the confirmation page.

@fsbraun
Copy link
Sponsor Member

fsbraun commented Mar 27, 2024

@im-n1 Any news on my question? #7830 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants