Checkpoint for the Manage Deleted Items UI
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2718 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
@@ -761,6 +761,44 @@ company_id=Company ID
|
||||
home_space_location=Home Space Location
|
||||
home_space_name=Home Space Name
|
||||
|
||||
# Trashcan messages
|
||||
title_deleted_items=Deleted Items
|
||||
title_delete_all=Delete All Items
|
||||
title_recover_all=Recover All Items
|
||||
title_recover_listed=Recover Listed Items
|
||||
title_delete_listed=Delete Listed Items
|
||||
title_delete_item=Delete Item
|
||||
title_recover_item=Recover Item
|
||||
deleted_items=Deleted Items
|
||||
manage_deleted_items=Manage Deleted Items
|
||||
manage_deleted_items_description=Remove or recover previously deleted items
|
||||
recover_all_items=Recover All Items
|
||||
delete_all_items=Delete All Items
|
||||
deleted_items_info=Use the Search to find specific named deleted items and use the Filters to reduce the list.
|
||||
original_location=Original Location
|
||||
deleted_date=Date Deleted
|
||||
deleted_user=Deleted by User
|
||||
recover=Recover
|
||||
search_deleted_items=Search Deleted Items
|
||||
delete_item=Delete Item
|
||||
delete_item_info=Permanently delete an item from the deleted file store
|
||||
delete_item_confirm=Are you sure you want to permanently delete \"{0}\" from the deleted file store? The item cannot be recovered once this action has been performed.
|
||||
recover_item=Recover Item
|
||||
recover_item_info=Recover an item from the deleted file store
|
||||
recover_item_confirm=Are you sure you want to recover \"{0}\" from the deleted file store?
|
||||
delete_all_items=Delete All Items
|
||||
delete_all_items_info=Permanently delete all files and spaces from the deleted file store
|
||||
delete_all_items_confirm=Are you sure you want to permanently delete all files and spaces from the deleted file store? The items cannot be recovered once this action has been performed.
|
||||
recover_all_items=Recover All Items
|
||||
recover_all_items_info=Recover all files and spaces from the deleted file store
|
||||
recover_all_items_confirm=Are you sure you want to recover all the deleted files and spaces from the deleted file store?
|
||||
delete_listed_items=Delete Listed Items
|
||||
delete_listed_items_info=Permanently delete the listed files and spaces from the deleted file store
|
||||
delete_listed_items_confirm=Are you sure you want to permanently delete the listed deleted files and spaces from the deleted file store? The items cannot be recovered once this action has been performed.
|
||||
recover_listed_items=Recover Listed Items
|
||||
recover_listed_items_info=Recover the listed files and spaces from the deleted file store
|
||||
recover_listed_items_confirm=Are you sure you want to recover the listed deleted files and spaces from the deleted file store?
|
||||
|
||||
# Admin Console messages
|
||||
title_admin_console=Administration Console
|
||||
admin_console=Administration Console
|
||||
|
@@ -258,6 +258,7 @@
|
||||
<action idref="export_space" />
|
||||
<action idref="create_shortcut" />
|
||||
<action idref="take_ownership_space" />
|
||||
<action idref="manage_space_users" />
|
||||
<action idref="manage_space_rules" />
|
||||
<action idref="discuss_node" />
|
||||
<action idref="create_forum_node" />
|
||||
|
@@ -75,6 +75,7 @@ public abstract class BaseServlet extends HttpServlet
|
||||
validRedirectJSPs.add("/jsp/dialog/system-info.jsp");
|
||||
validRedirectJSPs.add("/jsp/forums/forums.jsp");
|
||||
validRedirectJSPs.add("/jsp/users/users.jsp");
|
||||
validRedirectJSPs.add("/jsp/trashcan/trash-list.jsp");
|
||||
}
|
||||
|
||||
private static Log logger = LogFactory.getLog(BaseServlet.class);
|
||||
|
137
source/java/org/alfresco/web/bean/TrashcanBean.java
Normal file
@@ -0,0 +1,137 @@
|
||||
/*
|
||||
* Copyright (C) 2005 Alfresco, Inc.
|
||||
*
|
||||
* Licensed under the Mozilla Public License version 1.1
|
||||
* with a permitted attribution clause. You may obtain a
|
||||
* copy of the License at
|
||||
*
|
||||
* http://www.alfresco.org/legal/license.txt
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
|
||||
* either express or implied. See the License for the specific
|
||||
* language governing permissions and limitations under the
|
||||
* License.
|
||||
*/
|
||||
package org.alfresco.web.bean;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.service.cmr.repository.NodeService;
|
||||
import org.alfresco.service.cmr.search.SearchService;
|
||||
import org.alfresco.web.app.context.IContextListener;
|
||||
import org.alfresco.web.bean.repository.Node;
|
||||
import org.alfresco.web.ui.common.component.data.UIRichList;
|
||||
|
||||
/**
|
||||
* @author Kevin Roast
|
||||
*/
|
||||
public class TrashcanBean implements IContextListener
|
||||
{
|
||||
/** NodeService bean reference */
|
||||
protected NodeService nodeService;
|
||||
|
||||
/** SearchService bean reference */
|
||||
protected SearchService searchService;
|
||||
|
||||
/** Component reference for Deleted Items RichList control */
|
||||
protected UIRichList itemsRichList;
|
||||
|
||||
/** Search text */
|
||||
private String searchText;
|
||||
|
||||
|
||||
// ------------------------------------------------------------------------------
|
||||
// Bean property getters and setters
|
||||
|
||||
/**
|
||||
* @param nodeService The NodeService to set.
|
||||
*/
|
||||
public void setNodeService(NodeService nodeService)
|
||||
{
|
||||
this.nodeService = nodeService;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param searchService the search service
|
||||
*/
|
||||
public void setSearchService(SearchService searchService)
|
||||
{
|
||||
this.searchService = searchService;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return Returns the itemsRichList.
|
||||
*/
|
||||
public UIRichList getItemsRichList()
|
||||
{
|
||||
return this.itemsRichList;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param itemsRichList The itemsRichList to set.
|
||||
*/
|
||||
public void setItemsRichList(UIRichList itemsRichList)
|
||||
{
|
||||
this.itemsRichList = itemsRichList;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return Returns the searchText.
|
||||
*/
|
||||
public String getSearchText()
|
||||
{
|
||||
return this.searchText;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param searchText The searchText to set.
|
||||
*/
|
||||
public void setSearchText(String searchText)
|
||||
{
|
||||
this.searchText = searchText;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the list of deleted items to display
|
||||
*/
|
||||
public List<Node> getItems()
|
||||
{
|
||||
// TODO: need the following MapNode properties:
|
||||
// deletedDate, locationPath, displayPath, deletedUsername [only for admin user]
|
||||
// TODO: get deleted items from deleted items store
|
||||
// use a search - also use filters by name/username
|
||||
return Collections.<Node>emptyList();
|
||||
}
|
||||
|
||||
|
||||
// ------------------------------------------------------------------------------
|
||||
// Action handlers
|
||||
|
||||
// TODO:
|
||||
// need the following navigation outcomes
|
||||
// DONE deleteItem, recoverItem, recoverAllItems, deleteAllItems, recoverListedItems, deleteListedItems
|
||||
// need the following Action Handlers:
|
||||
// deleteItemOK, recoverItemOK, deleteAllItemsOK, recoverAllItemsOK, recoverListedItemsOK, deleteListedItemsOK
|
||||
// and following Action Event Handlers:
|
||||
// setupItemAction, search
|
||||
// and following getters:
|
||||
// listedItems, item (setup by setupItemAction!)
|
||||
|
||||
|
||||
// ------------------------------------------------------------------------------
|
||||
// IContextListener implementation
|
||||
|
||||
/**
|
||||
* @see org.alfresco.web.app.context.IContextListener#contextUpdated()
|
||||
*/
|
||||
public void contextUpdated()
|
||||
{
|
||||
if (this.itemsRichList != null)
|
||||
{
|
||||
this.itemsRichList.setValue(null);
|
||||
}
|
||||
}
|
||||
}
|
@@ -1394,6 +1394,23 @@
|
||||
</managed-property>
|
||||
</managed-bean>
|
||||
|
||||
<managed-bean>
|
||||
<description>
|
||||
The bean that holds state for the Manage Deleted Items screen.
|
||||
</description>
|
||||
<managed-bean-name>TrashcanBean</managed-bean-name>
|
||||
<managed-bean-class>org.alfresco.web.bean.TrashcanBean</managed-bean-class>
|
||||
<managed-bean-scope>session</managed-bean-scope>
|
||||
<managed-property>
|
||||
<property-name>nodeService</property-name>
|
||||
<value>#{NodeService}</value>
|
||||
</managed-property>
|
||||
<managed-property>
|
||||
<property-name>searchService</property-name>
|
||||
<value>#{SearchService}</value>
|
||||
</managed-property>
|
||||
</managed-bean>
|
||||
|
||||
<managed-bean>
|
||||
<description>
|
||||
Helper bean that caches the last item added to a multi
|
||||
@@ -1404,8 +1421,8 @@
|
||||
<managed-bean-scope>session</managed-bean-scope>
|
||||
</managed-bean>
|
||||
|
||||
<!-- ==================== COMPONENT GENERATOR BEANS ==================== -->
|
||||
|
||||
<!-- ==================== COMPONENT GENERATOR BEANS ==================== -->
|
||||
<managed-bean>
|
||||
<description>
|
||||
Bean that generates a text field component
|
||||
|
@@ -174,6 +174,10 @@
|
||||
<from-outcome>saveEditSearch</from-outcome>
|
||||
<to-view-id>/jsp/dialog/edit-search.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
<navigation-case>
|
||||
<from-outcome>manageDeletedItems</from-outcome>
|
||||
<to-view-id>/jsp/trashcan/trash-list.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
</navigation-rule>
|
||||
|
||||
<!-- Admin Console rules -->
|
||||
@@ -1153,5 +1157,34 @@
|
||||
<to-view-id>/jsp/forums/forum.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
</navigation-rule>
|
||||
|
||||
<!-- Manage Deleted Items screen action outcomes -->
|
||||
<navigation-rule>
|
||||
<from-view-id>/jsp/trashcan/*</from-view-id>
|
||||
<navigation-case>
|
||||
<from-outcome>deleteItem</from-outcome>
|
||||
<to-view-id>/jsp/trashcan/delete-item.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
<navigation-case>
|
||||
<from-outcome>recoverItem</from-outcome>
|
||||
<to-view-id>/jsp/trashcan/recover-item.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
<navigation-case>
|
||||
<from-outcome>recoverAllItems</from-outcome>
|
||||
<to-view-id>/jsp/trashcan/recover-all.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
<navigation-case>
|
||||
<from-outcome>deleteAllItems</from-outcome>
|
||||
<to-view-id>/jsp/trashcan/delete-all.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
<navigation-case>
|
||||
<from-outcome>recoverListedItems</from-outcome>
|
||||
<to-view-id>/jsp/trashcan/recover-listed.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
<navigation-case>
|
||||
<from-outcome>deleteListedItems</from-outcome>
|
||||
<to-view-id>/jsp/trashcan/delete-listed.jsp</to-view-id>
|
||||
</navigation-case>
|
||||
</navigation-rule>
|
||||
|
||||
</faces-config>
|
||||
|
BIN
source/web/images/icons/delete_all.gif
Normal file
After Width: | Height: | Size: 970 B |
BIN
source/web/images/icons/delete_all_large.gif
Normal file
After Width: | Height: | Size: 778 B |
BIN
source/web/images/icons/recover.gif
Normal file
After Width: | Height: | Size: 553 B |
BIN
source/web/images/icons/recover_all.gif
Normal file
After Width: | Height: | Size: 553 B |
BIN
source/web/images/icons/recover_all_large.gif
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
source/web/images/icons/recover_large.gif
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
source/web/images/icons/trashcan.gif
Normal file
After Width: | Height: | Size: 970 B |
BIN
source/web/images/icons/trashcan_large.gif
Normal file
After Width: | Height: | Size: 778 B |
@@ -144,11 +144,11 @@
|
||||
</table>
|
||||
<% PanelGenerator.generatePanelEnd(out, request.getContextPath(), "yellowInner"); %>
|
||||
|
||||
<div style="padding: 6px;" />
|
||||
<div style="padding: 6px;"></div>
|
||||
<h:inputText id="search-text" value="#{UsersBean.searchCriteria}" size="35" maxlength="1024" onkeyup="updateButtonState();" onchange="updateButtonState();" />
|
||||
<h:commandButton id="search-btn" value="#{msg.search}" action="#{UsersBean.search}" disabled="true" />
|
||||
<h:commandButton value="#{msg.show_all}" action="#{UsersBean.showAll}" />
|
||||
<div style="padding: 6px;" />
|
||||
<div style="padding: 6px;"></div>
|
||||
|
||||
<a:richList id="users-list" binding="#{UsersBean.usersRichList}" viewMode="details" pageSize="10"
|
||||
styleClass="recordSet" headerStyleClass="recordSetHeader" rowStyleClass="recordSetRow" altRowStyleClass="recordSetRowAlt" width="100%"
|
||||
|