mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
. Checkpoint of WCM UI
- First pass of the Staging/User Sandboxes view for an AVM website folder - Basic layout and component structure only, nothing works yet - Panel for each user sandbox, collapsing area for change files (nothing in it yet) git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3783 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -796,6 +796,7 @@ create_website_finish_instruction=To close this wizard and create your website s
|
|||||||
title_browse_website=Browse Website Sandboxes
|
title_browse_website=Browse Website Sandboxes
|
||||||
website_info=Use this view to browse the staging area and user sandboxes for a website.
|
website_info=Use this view to browse the staging area and user sandboxes for a website.
|
||||||
staging_sandbox=Staging Sandbox
|
staging_sandbox=Staging Sandbox
|
||||||
|
user_sandboxes=User Sandboxes
|
||||||
|
|
||||||
# New User Wizard messages
|
# New User Wizard messages
|
||||||
new_user_title=New User Wizard
|
new_user_title=New User Wizard
|
||||||
|
@@ -17,6 +17,7 @@
|
|||||||
package org.alfresco.web.bean.wcm;
|
package org.alfresco.web.bean.wcm;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
@@ -100,10 +101,16 @@ public class CreateWebsiteWizard extends BaseWizardBean
|
|||||||
// create the AVM stores (layers) to represent the newly created location website
|
// create the AVM stores (layers) to represent the newly created location website
|
||||||
createStagingSandbox(this.name);
|
createStagingSandbox(this.name);
|
||||||
|
|
||||||
// create layer for current user (TODO: based on role)
|
// create a sandbox for each user (TODO: based on role?)
|
||||||
createUserSandbox(this.name, Application.getCurrentUser(context).getUserName());
|
List<String> invitedUsers = getInvitedUsernames();
|
||||||
|
invitedUsers.add(Application.getCurrentUser(context).getUserName());
|
||||||
|
for (String username : invitedUsers)
|
||||||
|
{
|
||||||
|
createUserSandbox(this.name, username);
|
||||||
|
}
|
||||||
|
|
||||||
// TODO: create layers for invited users based on roles
|
// save the list of invited users against the store
|
||||||
|
this.nodeService.setProperty(nodeRef, ContentModel.PROP_USERSANDBOXES, (Serializable)invitedUsers);
|
||||||
|
|
||||||
// TODO: import the ZIP structure into the AVM staging store
|
// TODO: import the ZIP structure into the AVM staging store
|
||||||
|
|
||||||
@@ -362,4 +369,13 @@ public class CreateWebsiteWizard extends BaseWizardBean
|
|||||||
this.avmService.setStoreProperty(store, QName.createQName(null, dnsProp),
|
this.avmService.setStoreProperty(store, QName.createQName(null, dnsProp),
|
||||||
new PropertyValue(DataTypeDefinition.TEXT, path));
|
new PropertyValue(DataTypeDefinition.TEXT, path));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return The list of invited usernames
|
||||||
|
*/
|
||||||
|
private List<String> getInvitedUsernames()
|
||||||
|
{
|
||||||
|
// TODO: add the list of invited users here
|
||||||
|
return new ArrayList<String>(1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -154,6 +154,7 @@
|
|||||||
<component-class>org.alfresco.web.ui.repo.component.UIWorkflowSummary</component-class>
|
<component-class>org.alfresco.web.ui.repo.component.UIWorkflowSummary</component-class>
|
||||||
</component>
|
</component>
|
||||||
|
|
||||||
|
|
||||||
<!-- ==================== CONVERTERS ==================== -->
|
<!-- ==================== CONVERTERS ==================== -->
|
||||||
<component>
|
<component>
|
||||||
<component-type>org.alfresco.faces.PermissionEvaluator</component-type>
|
<component-type>org.alfresco.faces.PermissionEvaluator</component-type>
|
||||||
|
19
source/web/WEB-INF/faces-config-wcm.xml
Normal file
19
source/web/WEB-INF/faces-config-wcm.xml
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
<?xml version='1.0' encoding='UTF-8'?>
|
||||||
|
<!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
|
||||||
|
"http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
|
||||||
|
<faces-config>
|
||||||
|
|
||||||
|
<!-- ==================== COMPONENTS ==================== -->
|
||||||
|
<component>
|
||||||
|
<component-type>org.alfresco.faces.UserSandboxes</component-type>
|
||||||
|
<component-class>org.alfresco.web.ui.wcm.component.UIUserSandboxes</component-class>
|
||||||
|
</component>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- ==================== CONVERTERS ==================== -->
|
||||||
|
|
||||||
|
|
||||||
|
<!-- ==================== RENDERERS ==================== -->
|
||||||
|
|
||||||
|
|
||||||
|
</faces-config>
|
47
source/web/WEB-INF/wcm.tld
Normal file
47
source/web/WEB-INF/wcm.tld
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE taglib PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN" "http://java.sun.com/j2ee/dtds/web-jsptaglibrary_1_2.dtd">
|
||||||
|
|
||||||
|
<taglib>
|
||||||
|
|
||||||
|
<tlib-version>1.0</tlib-version>
|
||||||
|
<jsp-version>1.2</jsp-version>
|
||||||
|
<short-name>w</short-name>
|
||||||
|
<display-name>Alfresco WCM JSF Components</display-name>
|
||||||
|
<description>Tag library consisting of Alfresco WCM JSF components i.e. those that can only be used in Alfresco WCM based projects</description>
|
||||||
|
|
||||||
|
<tag>
|
||||||
|
<name>userSandboxes</name>
|
||||||
|
<tag-class>org.alfresco.web.ui.wcm.tag.UserSandboxesTag</tag-class>
|
||||||
|
<body-content>JSP</body-content>
|
||||||
|
<display-name>User Sandboxes</display-name>
|
||||||
|
<description>Displays the user sandboxes for a website</description>
|
||||||
|
|
||||||
|
<attribute>
|
||||||
|
<name>id</name>
|
||||||
|
<required>false</required>
|
||||||
|
<rtexprvalue>true</rtexprvalue>
|
||||||
|
<description>The component identifier for this component</description>
|
||||||
|
</attribute>
|
||||||
|
|
||||||
|
<attribute>
|
||||||
|
<name>value</name>
|
||||||
|
<required>true</required>
|
||||||
|
<rtexprvalue>true</rtexprvalue>
|
||||||
|
<description>The noderef of the website to display sandboxes for</description>
|
||||||
|
</attribute>
|
||||||
|
|
||||||
|
<attribute>
|
||||||
|
<name>binding</name>
|
||||||
|
<required>false</required>
|
||||||
|
<rtexprvalue>true</rtexprvalue>
|
||||||
|
<description>The value binding expression linking this component to a property in a backing bean</description>
|
||||||
|
</attribute>
|
||||||
|
|
||||||
|
<attribute>
|
||||||
|
<name>rendered</name>
|
||||||
|
<required>false</required>
|
||||||
|
<rtexprvalue>true</rtexprvalue>
|
||||||
|
</attribute>
|
||||||
|
</tag>
|
||||||
|
|
||||||
|
</taglib>
|
@@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
<context-param>
|
<context-param>
|
||||||
<param-name>javax.faces.CONFIG_FILES</param-name>
|
<param-name>javax.faces.CONFIG_FILES</param-name>
|
||||||
<param-value>/WEB-INF/faces-config-app.xml,/WEB-INF/faces-config-beans.xml,/WEB-INF/faces-config-navigation.xml,/WEB-INF/faces-config-common.xml,/WEB-INF/faces-config-repo.xml,WEB-INF/faces-config-custom.xml,/WEB-INF/faces-config-enterprise.xml,/WEB-INF/faces-config-jbpm.xml</param-value>
|
<param-value>/WEB-INF/faces-config-app.xml,/WEB-INF/faces-config-beans.xml,/WEB-INF/faces-config-navigation.xml,/WEB-INF/faces-config-common.xml,/WEB-INF/faces-config-repo.xml,/WEB-INF/faces-config-wcm.xml,WEB-INF/faces-config-custom.xml,/WEB-INF/faces-config-enterprise.xml,/WEB-INF/faces-config-jbpm.xml</param-value>
|
||||||
</context-param>
|
</context-param>
|
||||||
|
|
||||||
<context-param>
|
<context-param>
|
||||||
|
@@ -17,12 +17,13 @@
|
|||||||
|
|
||||||
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
|
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
|
||||||
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
|
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
|
||||||
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
|
|
||||||
<%@ taglib uri="/WEB-INF/alfresco.tld" prefix="a" %>
|
<%@ taglib uri="/WEB-INF/alfresco.tld" prefix="a" %>
|
||||||
<%@ taglib uri="/WEB-INF/repo.tld" prefix="r" %>
|
<%@ taglib uri="/WEB-INF/repo.tld" prefix="r" %>
|
||||||
|
<%@ taglib uri="/WEB-INF/wcm.tld" prefix="w" %>
|
||||||
|
|
||||||
<%@ page buffer="64kb" contentType="text/html;charset=UTF-8" %>
|
<%@ page buffer="64kb" contentType="text/html;charset=UTF-8" %>
|
||||||
<%@ page isELIgnored="false" %>
|
<%@ page isELIgnored="false" %>
|
||||||
|
<%@ page import="org.alfresco.web.ui.common.PanelGenerator" %>
|
||||||
|
|
||||||
<r:page titleId="title_browse_website">
|
<r:page titleId="title_browse_website">
|
||||||
|
|
||||||
@@ -94,7 +95,13 @@
|
|||||||
<a:panel id="staging-panel" border="white" bgcolor="white" titleBorder="blue" titleBgcolor="#D3E6FE" styleClass="mainSubTitle" label="#{msg.staging_sandbox}">
|
<a:panel id="staging-panel" border="white" bgcolor="white" titleBorder="blue" titleBgcolor="#D3E6FE" styleClass="mainSubTitle" label="#{msg.staging_sandbox}">
|
||||||
|
|
||||||
<%-- Staging Sandbox Info here --%>
|
<%-- Staging Sandbox Info here --%>
|
||||||
---STAGING SANDBOX INFO HERE---
|
<% PanelGenerator.generatePanelStart(out, request.getContextPath(), "blue", "#D3E6FE"); %>
|
||||||
|
---STAGING SANDBOX INFO HERE---<br>
|
||||||
|
-------------------------------<br>
|
||||||
|
Last Updated: 1234<br>
|
||||||
|
12 items currently being modified<br>
|
||||||
|
3 items pending approval
|
||||||
|
<% PanelGenerator.generatePanelEnd(out, request.getContextPath(), "blue"); %>
|
||||||
|
|
||||||
</a:panel>
|
</a:panel>
|
||||||
|
|
||||||
@@ -107,10 +114,10 @@
|
|||||||
<td style="background-image: url(<%=request.getContextPath()%>/images/parts/whitepanel_4.gif)" width=4></td>
|
<td style="background-image: url(<%=request.getContextPath()%>/images/parts/whitepanel_4.gif)" width=4></td>
|
||||||
<td style="padding:4px">
|
<td style="padding:4px">
|
||||||
|
|
||||||
<a:panel id="sandboxes-panel" border="white" bgcolor="white" titleBorder="blue" titleBgcolor="#D3E6FE" styleClass="mainSubTitle" label="#{msg.staging_sandbox}">
|
<a:panel id="sandboxes-panel" border="white" bgcolor="white" titleBorder="blue" titleBgcolor="#D3E6FE" styleClass="mainSubTitle" label="#{msg.user_sandboxes}">
|
||||||
|
|
||||||
<%-- User Sandboxes List --%>
|
<%-- User Sandboxes List --%>
|
||||||
---USER SANDBOXES HERE---
|
<w:userSandboxes value="#{NavigationBean.currentNode.nodeRef}" />
|
||||||
|
|
||||||
</a:panel>
|
</a:panel>
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user