Skip to content

Commit

Permalink
Add appropriately named action to unpublish
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathan-s committed Oct 15, 2019
1 parent 3971f3f commit a1c8254
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions djangocms_moderation/admin_actions.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from functools import partial
from collections import defaultdict

from django.contrib import admin
Expand Down Expand Up @@ -153,9 +154,11 @@ def add_items_to_collection(modeladmin, request, queryset):
return HttpResponseRedirect(request.META.get("HTTP_REFERER"))


add_items_to_collection.short_description = _(
"Add to moderation collection"
) # noqa: E305
add_items_to_collection.short_description = _("Add to moderation collection")

add_item_to_unpublish_collection = partial(add_items_to_collection)
add_item_to_unpublish_collection.__name__ = 'add_item_to_unpublish_collection'
add_item_to_unpublish_collection.short_description = _('Add moderation collection to unpublish')


def post_bulk_actions(collection):
Expand Down

0 comments on commit a1c8254

Please sign in to comment.