django-cms / djangocms-moderation

Other
13 stars 21 forks source link

Delete selected moderation requests (remove items from collection) #44

Closed damilare closed 6 years ago

damilare commented 6 years ago

@czpython made changes

damilare commented 6 years ago

@czpython :100: :ecuador: :+1: :us: :+1:

mmoravcik commented 6 years ago

@czpython Failing tests here look like some kind of caching issue?

Traceback (most recent call last):
  File "/home/circleci/app/tests/test_views.py", line 112, in test_prevent_locked_collections
    self.collection_1.status = self.collection_1.IN_REVIEW
AttributeError: 'ModerationCollection' object has no attribute 'IN_REVIEW'

Can't see this in the code, it is in fact from PR #42 -> https://github.com/divio/djangocms-moderation/pull/42/files#diff-a4f5c4d64d4811b15e1405573c00f3f4R113

mmoravcik commented 6 years ago

@czpython I see there is no test added (there is a bit of a custom logic as we override delete_selected). Should we add some? Something like https://github.com/FidelityInternational/djangocms-moderation/pull/28/files#diff-a82ca14d7d1c69eb52c8032a74e294adR67

mmoravcik commented 6 years ago

Also, would you agree if I moved the delete_action to file admin_actions.py? We've done it in #46