[seam-commits] Seam SVN: r8014 - in trunk/examples/seamspace: resources/META-INF and 3 other directories.
seam-commits at lists.jboss.org
seam-commits at lists.jboss.org
Thu Apr 24 07:38:58 EDT 2008
Author: shane.bryzak at jboss.com
Date: 2008-04-24 07:38:58 -0400 (Thu, 24 Apr 2008)
New Revision: 8014
Added:
trunk/examples/seamspace/view/security.xhtml
trunk/examples/seamspace/view/style/btn_newrole.png
trunk/examples/seamspace/view/style/btn_newuser.png
trunk/examples/seamspace/view/style/manage_roles.png
trunk/examples/seamspace/view/style/manage_users.png
Modified:
trunk/examples/seamspace/build.xml
trunk/examples/seamspace/resources/META-INF/security-rules.drl
trunk/examples/seamspace/resources/WEB-INF/components.xml
trunk/examples/seamspace/view/rolemanager.xhtml
trunk/examples/seamspace/view/style/seamspace.css
trunk/examples/seamspace/view/template.xhtml
trunk/examples/seamspace/view/usermanager.xhtml
Log:
new look for identity management screens
Modified: trunk/examples/seamspace/build.xml
===================================================================
--- trunk/examples/seamspace/build.xml 2008-04-23 19:27:50 UTC (rev 8013)
+++ trunk/examples/seamspace/build.xml 2008-04-24 11:38:58 UTC (rev 8014)
@@ -11,8 +11,6 @@
<property name="drools.lib" value="yes"/>
<property name="seam.ui.lib" value="yes"/>
<property name="jcaptcha.lib" value="yes"/>
- <property name="richfaces.lib" value="yes"/>
-
<import file="../build.xml"/>
</project>
Modified: trunk/examples/seamspace/resources/META-INF/security-rules.drl
===================================================================
--- trunk/examples/seamspace/resources/META-INF/security-rules.drl 2008-04-23 19:27:50 UTC (rev 8013)
+++ trunk/examples/seamspace/resources/META-INF/security-rules.drl 2008-04-24 11:38:58 UTC (rev 8014)
@@ -14,16 +14,6 @@
import org.jboss.seam.example.seamspace.MemberFriend;
import org.jboss.seam.example.seamspace.MemberImage;
-rule ViewProfile
- no-loop
- activation-group "permissions"
-when
- check: PermissionCheck(name == "/profile.xhtml", action == "render", granted == false)
- Role(name == "admin")
-then
- check.grant();
-end
-
rule ViewImage
no-loop
activation-group "permissions"
Modified: trunk/examples/seamspace/resources/WEB-INF/components.xml
===================================================================
--- trunk/examples/seamspace/resources/WEB-INF/components.xml 2008-04-23 19:27:50 UTC (rev 8013)
+++ trunk/examples/seamspace/resources/WEB-INF/components.xml 2008-04-24 11:38:58 UTC (rev 8014)
@@ -49,7 +49,7 @@
enabled-attribute="enabled"
/>
- <security:jpa-permission-store name="accountPermissionStore" permission-class="org.jboss.seam.example.seamspace.Permission"/>
+ <security:jpa-permission-store name="permissionStore" permission-class="org.jboss.seam.example.seamspace.Permission"/>
<drools:rule-base name="securityRules">
<drools:rule-files>
Modified: trunk/examples/seamspace/view/rolemanager.xhtml
===================================================================
--- trunk/examples/seamspace/view/rolemanager.xhtml 2008-04-23 19:27:50 UTC (rev 8013)
+++ trunk/examples/seamspace/view/rolemanager.xhtml 2008-04-24 11:38:58 UTC (rev 8014)
@@ -2,8 +2,7 @@
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
- xmlns:f="http://java.sun.com/jsf/core"
- xmlns:rich="http://richfaces.org/rich"
+ xmlns:f="http://java.sun.com/jsf/core"
xmlns:s="http://jboss.com/products/seam/taglib">
<ui:composition template="template.xhtml">
@@ -22,42 +21,31 @@
<h2>Role Manager</h2>
<s:button action="#{roleAction.createRole}" styleClass="newrole" rendered="#{s:hasPermission('seam.account', 'create', null)}"/>
- <s:link view="/usermanager.xhtml" value="--> Manage Users" propagation="none"/>
- <rich:dataTable
+ <h:dataTable
id="threads"
value="#{roles}"
var="role"
styleClass="default"
columnClasses=",,enabled,action">
- <f:facet name="header">
- <rich:columnGroup>
- <rich:column width="auto">
- User name
- </rich:column>
- <rich:column width="auto">
- Member Of
- </rich:column>
- <rich:column width="auto">
- Action
- </rich:column>
- </rich:columnGroup>
- </f:facet>
- <rich:column width="auto">
+ <h:column width="auto">
+ <f:facet name="header">Role</f:facet>
#{role}
- </rich:column>
- <rich:column width="auto">
+ </h:column>
+ <h:column width="auto">
+ <f:facet name="header">Member Of</f:facet>
#{roleSearch.getRoleGroups(role)}
- </rich:column>
- <rich:column width="auto">
+ </h:column>
+ <h:column width="auto">
+ <f:facet name="header">Action</f:facet>
<s:fragment rendered="#{s:hasPermission('seam.role', 'update')}">
<s:link value="Edit" action="#{roleAction.editRole(roleSearch.selectedRole)}"/><span> | </span>
</s:fragment>
<s:link value="Delete" action="#{identityManager.deleteRole(roleSearch.selectedRole)}"
rendered="#{s:hasPermission('seam.role', 'delete')}"
onclick="return confirmDelete()"/>
- </rich:column>
- </rich:dataTable>
+ </h:column>
+ </h:dataTable>
</div>
</ui:define>
Added: trunk/examples/seamspace/view/security.xhtml
===================================================================
--- trunk/examples/seamspace/view/security.xhtml (rev 0)
+++ trunk/examples/seamspace/view/security.xhtml 2008-04-24 11:38:58 UTC (rev 8014)
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:s="http://jboss.com/products/seam/taglib">
+
+ <ui:composition template="template.xhtml">
+
+ <ui:define name="content">
+
+ <div id="contentMain">
+
+ <h2>Security</h2>
+
+ <s:button view="/usermanager.xhtml" styleClass="manageusers" value="Manage Users"/><br/>
+ <s:button view="/rolemanager.xhtml" styleClass="manageroles" value="Manage Roles"/>
+
+ </div>
+
+ </ui:define>
+
+ </ui:composition>
+</html>
Added: trunk/examples/seamspace/view/style/btn_newrole.png
===================================================================
(Binary files differ)
Property changes on: trunk/examples/seamspace/view/style/btn_newrole.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/examples/seamspace/view/style/btn_newuser.png
===================================================================
(Binary files differ)
Property changes on: trunk/examples/seamspace/view/style/btn_newuser.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/examples/seamspace/view/style/manage_roles.png
===================================================================
(Binary files differ)
Property changes on: trunk/examples/seamspace/view/style/manage_roles.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/examples/seamspace/view/style/manage_users.png
===================================================================
(Binary files differ)
Property changes on: trunk/examples/seamspace/view/style/manage_users.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Modified: trunk/examples/seamspace/view/style/seamspace.css
===================================================================
--- trunk/examples/seamspace/view/style/seamspace.css 2008-04-23 19:27:50 UTC (rev 8013)
+++ trunk/examples/seamspace/view/style/seamspace.css 2008-04-24 11:38:58 UTC (rev 8014)
@@ -501,23 +501,53 @@
}
input.newuser {
- background: url(../images/btn_newuser.png) top left no-repeat;
- height: 24px;
- width: 80px;
+ background: url(btn_newuser.png) top left no-repeat;
+ height: 39px;
+ width: 113px;
margin: 4px 4px 4px 4px;
border: 0px;
cursor: pointer;
}
input.newrole {
- background: url(../images/btn_newrole.png) top left no-repeat;
- height: 24px;
- width: 80px;
+ background: url(btn_newrole.png) top left no-repeat;
+ height: 39px;
+ width: 113px;
margin: 4px 4px 4px 4px;
border: 0px;
cursor: pointer;
}
+input.manageusers {
+ display: block;
+ background: url(manage_users.png) top left no-repeat;
+ height: 88px;
+ width: 400px;
+ padding-left: 10px;
+ font-size: 19px;
+ font-weight: bold;
+ color: #333333;
+ border: 0px;
+ cursor: pointer;
+ margin-top: 30px;
+ margin-left: 90px;
+}
+
+input.manageroles {
+ display: block;
+ background: url(manage_roles.png) top left no-repeat;
+ height: 88px;
+ width: 400px;
+ padding-left: 10px;
+ font-size: 19px;
+ font-weight: bold;
+ color: #333333;
+ border: 0px;
+ cursor: pointer;
+ margin-top: 30px;
+ margin-left: 90px;
+}
+
/* General form styles */
div.formRow {
Modified: trunk/examples/seamspace/view/template.xhtml
===================================================================
--- trunk/examples/seamspace/view/template.xhtml 2008-04-23 19:27:50 UTC (rev 8013)
+++ trunk/examples/seamspace/view/template.xhtml 2008-04-24 11:38:58 UTC (rev 8014)
@@ -17,6 +17,10 @@
<div class="headerRight">
<div class="headerMenu">
<!--s:link action="" value="SignUp"/-->
+ <s:fragment rendered="#{s:hasRole('admin')}">
+ <s:link view="/security.xhtml" value="Security" propagation="none"/> |
+ </s:fragment>
+
<s:link action="#{identity.logout}" value="Log out" rendered="#{identity.loggedIn}"/>
<h:outputLink value="home.seam" rendered="#{not identity.loggedIn}">Log in</h:outputLink>
</div>
@@ -40,8 +44,7 @@
<s:link view="/home.xhtml" value="Home" propagation="none"/>|
<s:link value="Browse" onclick="javascript:alert('This feature coming soon!');return false"/>|
<s:link value="Blog" onclick="javascript:alert('This feature coming soon!');return false"/>|
- <s:link value="Music" onclick="javascript:alert('This feature coming soon!');return false"/><s:fragment rendered="#{s:hasPermission('seam.user', 'read')}">|
- <s:link view="/usermanager.xhtml" value="User Manager" propagation="none"/></s:fragment>
+ <s:link value="Music" onclick="javascript:alert('This feature coming soon!');return false"/>
</div>
<div id="content">
Modified: trunk/examples/seamspace/view/usermanager.xhtml
===================================================================
--- trunk/examples/seamspace/view/usermanager.xhtml 2008-04-23 19:27:50 UTC (rev 8013)
+++ trunk/examples/seamspace/view/usermanager.xhtml 2008-04-24 11:38:58 UTC (rev 8014)
@@ -3,7 +3,6 @@
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
- xmlns:rich="http://richfaces.org/rich"
xmlns:s="http://jboss.com/products/seam/taglib">
<ui:composition template="template.xhtml">
@@ -22,48 +21,44 @@
<h2>User Manager</h2>
<s:button action="#{userAction.createUser}" styleClass="newuser" rendered="#{s:hasPermission('seam.account', 'create')}"/>
- <s:link view="/rolemanager.xhtml" value="--> Manage Roles" propagation="none"/>
- <rich:dataTable
+ <h:dataTable
id="threads"
value="#{users}"
var="user"
styleClass="default"
columnClasses=",,enabled,action">
+ <h:column width="auto">
<f:facet name="header">
- <rich:columnGroup>
- <rich:column width="auto">
- User name
- </rich:column>
- <rich:column width="auto">
- Member Of
- </rich:column>
- <rich:column width="auto">
- Enabled
- </rich:column>
- <rich:column width="auto">
- Action
- </rich:column>
- </rich:columnGroup>
- </f:facet>
- <rich:column width="auto">
+ User name
+ </f:facet>
#{user}
- </rich:column>
- <rich:column width="auto">
+ </h:column>
+ <h:column width="auto">
+ <f:facet name="header">
+ Member Of
+ </f:facet>
#{userSearch.getUserRoles(user)}
- </rich:column>
- <rich:column width="auto">
+ </h:column>
+ <h:column width="auto">
+ <f:facet name="header">
+ Enabled
+ </f:facet>
<div class="#{identityManager.isUserEnabled(user) ? 'checkmark' : 'cross'}"/>
- </rich:column>
- <rich:column width="auto">
+ </h:column>
+ <h:column width="auto">
+ <f:facet name="header">
+ Action
+ </f:facet>
+
<s:fragment rendered="#{s:hasPermission('seam.user', 'update')}">
<s:link value="Edit" action="#{userAction.editUser(userSearch.selectedUser)}"/><span> | </span>
</s:fragment>
<s:link value="Delete" action="#{identityManager.deleteUser(userSearch.selectedUser)}"
rendered="#{s:hasPermission('seam.user', 'delete')}"
onclick="return confirmDelete()"/>
- </rich:column>
- </rich:dataTable>
+ </h:column>
+ </h:dataTable>
</div>
</ui:define>
More information about the seam-commits
mailing list