Unpublishing block list items
# help-with-umbraco


02/12/2024, 3:35 PM
Is there any approach to handle scheduling publish & unpublishing individual block list items? The only way I can think of is to schedule a publish of the page with a set of changes however the issue is if I want to schedule a change then schedule another change to then remove this content this isn't possible.


02/12/2024, 3:57 PM
This is not yet possible, but it is in the roadmap - if you want to read what the plan is you can find it here: Currently there is no date for when this will be implemented, but it is scheduled for AFTER Umbraco 15 (December) - ("Reusable Block Content for Umbraco CMS")


02/12/2024, 4:35 PM
You can add your own publish/unpublish date/time properties to the block settings and add your own logic at render time (or in the content delivery API).


02/12/2024, 4:38 PM
Yeah this was my next port of call however isn't quite as nice as they wouldn't appear as unpublished in the tree in the back office


02/12/2024, 4:47 PM
Yeah, though I don't think there can ever be a single coherent UI for handling publishing of content and blocks given how logically different they are. If having them work the same way as nodes is important then you can always use child nodes, or a repository of nodes, and pull them together into pages at render time.

Rob Schall

02/12/2024, 9:54 PM
I agree with the temporary approach of adding a go-live/end date field(s) to each block added. We already add a "hide block" field to allow easy removal/hiding of a given block within a blocklist, so I could see the logic/ease of adding quick date fields.


02/13/2024, 8:02 AM
For some of our sites we have a publish date on blocks and other a simple hide/display but I generally add some code to the label to let the user know if a block is published. You can add an Angular filter in the label:
Copy code
{{$settings.wFtSetPropPublished == '0' ? '🚫 ' : "🟢 "}}{{$contentTypeName}}{{wFtPropTitle ? ' - ' + wFtPropTitle : ''}}
to acheive this.


02/13/2024, 12:26 PM
Great solution! Thanks