Description of problem: @29500/Oracle/Resin Create a folder Add an item to the folder Publish item Unpublish item Delete item The delete link does not show up for the folder, though it is empty. This problem does not occur if you delete the item before publication.
Jon, I'm confused about this ticket. As far as I can tell, since way way back, folders are not deletable: public boolean isDeletable() { if ( m_itemColl.isLive() ) { return false; } return ! ( m_itemColl.isFolder() ) || ((Folder) m_itemColl.getContentItem()).isEmpty(); } So, shall I try to enable folder deletes?
I think that from a usability perspective, it makes sense to allow folders to be deleted. I asked Mr Berrange on IRC: <danpb> live folders are automatically deleted when the last live item in them is removed <danpb> then you need to delete all draft items in the folder, at which point a link to delete the draft folder will appear in the 'browse' pane The convoluted isDeletable code actually makes sense. The first if says "if it is live, it is not deletable". The second has two parts: "if it is not a folder, it is deletable" and "if it is a folder and is empty, it is deletable". So this part is correct, albeit confusing.
This might have something to do with the fact that Bundles are never unpublished. When the last lang instance of a bundle is unpublished, the Bundle should be unpublished. Currently when a live folder is emptied, the live version is unpublished (allowing deletion). When bundles are never unpublished, neither are folders.
I now understand how isDeletable *does* do the right thing :). I will clarify that code a bit.
At perforce 32126, I'm not reproducing this bug. I believe it was fixed by making auto bundle unpublish work.