roblib / node_media_unpublish
Adds action to unpublish nodes and all associated media.
Package info
git.library.upei.ca/astanley/node_media_unpublish
Type:drupal-custom-module
pkg:composer/roblib/node_media_unpublish
dev-main
2026-08-25 15:27 UTC
Requires
- drupal/islandora: ^2.0
This package is not auto-updated.
Last update: 2026-08-26 01:03:00 UTC
README
Provides a Drupal 10/11 node action named Unpublish node and associated media.
When the action is executed for a node, it:
- Unpublishes the node if it is currently published.
- Finds media entities where
field_media_ofreferences the node. - Unpublishes each published media entity the current user is allowed to update.
Installation
Copy the module to web/modules/custom/node_media_unpublish, then enable it:
drush en node_media_unpublish -y
drush cr
The module installs a configured system action automatically, so it can be used from Drupal's node bulk operations/action UI.
Caution
Will unpublish the associated media, even if media is associated with multiple nodes.