In the Section for Recycle Bin in the Portal Settings there should a Select called "Enable Recycle Bin" and the options would be:
- Enabled by default (Site admins will be able to disable it per site)
- Disabled by default (Site admins will be able to enable it per site)
Then, in Site Settings, if the "Enable Recycle Bin" is disabled, we should not show the section for the Recycle Bin. If it is set to enabled by default or disabled by default, we should show a checkbox called "Enable Recycle Bin" whose value is by default the one set in Portal Settings, but admins will be able to change it.
All the buttons/links which now say "move to the Recycle Bin" should say either that or "Delete" if the Recycle Bin is not enabled and the CMD parameters should depend also on this setting.
It would be nice to have a method in TrashUtil called "isTrashEnabled(groupId)" which returns the value of the Site Setting and then we can do things like this:
trash="<%= TrashUtil.isTrashEnabled(themeDisplay.getParentGroupId()) %>"
url="<%= deleteURL %>"