svnno****@sourc*****
svnno****@sourc*****
2007年 4月 5日 (木) 23:00:51 JST
Revision: 19 http://svn.sourceforge.jp/cgi-bin/viewcvs.cgi?root=pal&view=rev&rev=19 Author: shinsuke Date: 2007-04-05 23:00:51 +0900 (Thu, 05 Apr 2007) Log Message: ----------- added group admin page Modified Paths: -------------- pal-admin/trunk/src/main/java/jp/sf/pal/admin/logic/SecurityProviderLogic.java pal-admin/trunk/src/main/resources/appMessages.properties Added Paths: ----------- pal-admin/trunk/src/main/java/jp/sf/pal/admin/dxo/GroupDxo.java pal-admin/trunk/src/main/java/jp/sf/pal/admin/entity/Group.java pal-admin/trunk/src/main/java/jp/sf/pal/admin/pager/GroupPager.java pal-admin/trunk/src/main/java/jp/sf/pal/admin/service/GroupManagementService.java pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/ pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/AbstractGroupPage.java pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupConfirmPage.java pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupEditPage.java pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupListPage.java pal-admin/trunk/src/main/resources/jp/sf/pal/admin/web/group/ pal-admin/trunk/src/main/resources/jp/sf/pal/admin/web/group/label.properties pal-admin/trunk/src/main/webapp/view/group/groupConfirm.html pal-admin/trunk/src/main/webapp/view/group/groupEdit.html pal-admin/trunk/src/main/webapp/view/group/groupList.html Removed Paths: ------------- pal-admin/trunk/src/main/webapp/view/group/roleConfirm.html pal-admin/trunk/src/main/webapp/view/group/roleEdit.html pal-admin/trunk/src/main/webapp/view/group/roleList.html -------------- next part -------------- Added: pal-admin/trunk/src/main/java/jp/sf/pal/admin/dxo/GroupDxo.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/dxo/GroupDxo.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/dxo/GroupDxo.java 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,16 @@ +package jp.sf.pal.admin.dxo; + +import java.util.List; +import java.util.Map; + +import jp.sf.pal.admin.entity.Group; +import jp.sf.pal.admin.web.group.AbstractGroupPage; + +public interface GroupDxo +{ + public void convert(List<Group> entities, List<Map<String, Object>> list); + + public void convert(AbstractGroupPage page, Group entity); + + public void convert(Group entity, AbstractGroupPage page); +} Property changes on: pal-admin/trunk/src/main/java/jp/sf/pal/admin/dxo/GroupDxo.java ___________________________________________________________________ Name: svn:eol-style + native Added: pal-admin/trunk/src/main/java/jp/sf/pal/admin/entity/Group.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/entity/Group.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/entity/Group.java 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,23 @@ +package jp.sf.pal.admin.entity; + +public class Group +{ + + private String name; + + /** + * @return the name + */ + public String getName() + { + return name; + } + + /** + * @param name the name to set + */ + public void setName(String name) + { + this.name = name; + } +} Property changes on: pal-admin/trunk/src/main/java/jp/sf/pal/admin/entity/Group.java ___________________________________________________________________ Name: svn:eol-style + native Modified: pal-admin/trunk/src/main/java/jp/sf/pal/admin/logic/SecurityProviderLogic.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/logic/SecurityProviderLogic.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/logic/SecurityProviderLogic.java 2007-04-05 14:00:51 UTC (rev 19) @@ -8,12 +8,16 @@ import jp.sf.pal.admin.PALAdminConstants; import jp.sf.pal.admin.PALAdminException; +import jp.sf.pal.admin.entity.Group; import jp.sf.pal.admin.entity.Role; +import jp.sf.pal.admin.pager.GroupPager; import jp.sf.pal.admin.pager.RolePager; +import org.apache.jetspeed.security.GroupManager; import org.apache.jetspeed.security.RoleManager; import org.apache.jetspeed.security.SecurityException; import org.apache.jetspeed.security.SecurityProvider; +import org.apache.jetspeed.security.spi.GroupSecurityHandler; import org.apache.jetspeed.security.spi.RoleSecurityHandler; import org.apache.log4j.Logger; @@ -31,6 +35,10 @@ private RoleManager roleManager = null; + private GroupSecurityHandler groupSecurityHandler = null; + + private GroupManager groupManager = null; + /** * @return the facesContext */ @@ -61,6 +69,28 @@ } /** + * @return the groupSecurityHandler + */ + public GroupSecurityHandler getGroupSecurityHandler() + { + if (groupSecurityHandler == null) + { + groupSecurityHandler = getSecurityProvider() + .getGroupSecurityHandler(); + } + return groupSecurityHandler; + } + + /** + * @param groupSecurityHandler the groupSecurityHandler to set + */ + public void setGroupSecurityHandler( + GroupSecurityHandler groupSecurityHandler) + { + this.groupSecurityHandler = groupSecurityHandler; + } + + /** * @return the roleManager */ public RoleManager getRoleManager() @@ -83,6 +113,28 @@ } /** + * @return the groupManager + */ + public GroupManager getGroupManager() + { + if (groupManager == null) + { + groupManager = (GroupManager) getFacesContext() + .getExternalContext().getRequestMap().get( + PALAdminConstants.GROUP_MANAGER_COMPONENT); + } + return groupManager; + } + + /** + * @param groupManager the groupManager to set + */ + public void setGroupManager(GroupManager groupManager) + { + this.groupManager = groupManager; + } + + /** * @return the securityProvider */ public SecurityProvider getSecurityProvider() @@ -104,6 +156,10 @@ this.securityProvider = securityProvider; } + // + // Role + // + public List<Role> getRoles(RolePager pager) { //Debug @@ -152,7 +208,7 @@ { return; } - + try { getRoleManager().addRole(role.getName()); @@ -180,4 +236,85 @@ throw new PALAdminException(e); } } + + // + // Group + // + + public List<Group> getGroups(GroupPager pager) + { + //Debug + if (PALAdminConstants.DEBUG) + { + List<Group> list = new ArrayList<Group>(); + Group entity = new Group(); + entity.setName("GROUP"); + list.add(entity); + return list; + } + + List<Group> groupList = new ArrayList<Group>(); + List<Principal> principals = getGroupSecurityHandler() + .getGroupPrincipals(pager.getFilter()); + + // set count + pager.setCount(principals.size()); + + // create list + int offset = pager.getOffset(); + int limit = pager.getLimit(); + int size = principals.size(); + if (logger.isDebugEnabled()) + { + logger.debug("getGroups(GroupPager) - pager.getFilter()=" + + pager.getFilter()); + logger.debug("getGroups(GroupPager) - offset=" + offset + + ", limit=" + limit + ", size=" + size); + } + for (int i = offset; i < offset + limit && i < size; i++) + { + Group r = new Group(); + r.setName(principals.get(i).getName()); + groupList.add(r); + } + + return groupList; + + } + + public void insertGroup(Group group) throws PALAdminException + { + //Debug + if (PALAdminConstants.DEBUG) + { + return; + } + + try + { + getGroupManager().addGroup(group.getName()); + } + catch (SecurityException e) + { + throw new PALAdminException(e); + } + } + + public void deleteGroup(Group group) throws PALAdminException + { + //Debug + if (PALAdminConstants.DEBUG) + { + return; + } + + try + { + getGroupManager().removeGroup(group.getName()); + } + catch (SecurityException e) + { + throw new PALAdminException(e); + } + } } Added: pal-admin/trunk/src/main/java/jp/sf/pal/admin/pager/GroupPager.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/pager/GroupPager.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/pager/GroupPager.java 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,28 @@ +package jp.sf.pal.admin.pager; + +public class GroupPager extends DefaultPager +{ + private String filter; + + public GroupPager() + { + super(); + filter = ""; + } + + /** + * @return the filter + */ + public String getFilter() + { + return filter; + } + + /** + * @param filter the filter to set + */ + public void setFilter(String filter) + { + this.filter = filter; + } +} Property changes on: pal-admin/trunk/src/main/java/jp/sf/pal/admin/pager/GroupPager.java ___________________________________________________________________ Name: svn:eol-style + native Added: pal-admin/trunk/src/main/java/jp/sf/pal/admin/service/GroupManagementService.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/service/GroupManagementService.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/service/GroupManagementService.java 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,144 @@ +package jp.sf.pal.admin.service; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import javax.faces.context.FacesContext; + +import jp.sf.pal.admin.PALAdminConstants; +import jp.sf.pal.admin.PALAdminException; +import jp.sf.pal.admin.dxo.GroupDxo; +import jp.sf.pal.admin.entity.Group; +import jp.sf.pal.admin.logic.SecurityProviderLogic; +import jp.sf.pal.admin.pager.GroupPager; +import jp.sf.pal.admin.web.group.AbstractGroupPage; +import jp.sf.pal.admin.web.group.GroupListPage; + +public class GroupManagementService +{ + private GroupPager groupPager; + + private SecurityProviderLogic securityProviderLogic; + + private GroupDxo groupDxo; + + /** + * @return the groupDxo + */ + public GroupDxo getGroupDxo() + { + return groupDxo; + } + + /** + * @param groupDxo the groupDxo to set + */ + public void setGroupDxo(GroupDxo groupDxo) + { + this.groupDxo = groupDxo; + } + + /** + * @return the groupPager + */ + public GroupPager getGroupPager() + { + return groupPager; + } + + /** + * @param groupPager the groupPager to set + */ + public void setGroupPager(GroupPager groupPager) + { + this.groupPager = groupPager; + } + + /** + * @return the securityProviderLogic + */ + public SecurityProviderLogic getSecurityProviderLogic() + { + return securityProviderLogic; + } + + /** + * @param securityProviderLogic the securityProviderLogic to set + */ + public void setSecurityProviderLogic( + SecurityProviderLogic securityProviderLogic) + { + this.securityProviderLogic = securityProviderLogic; + } + + public void handlePagerNavigation() + { + Map requestMap = FacesContext.getCurrentInstance().getExternalContext() + .getRequestParameterMap(); + String prev = (String) requestMap + .get(PALAdminConstants.PREVIOUS_PAGE_NUMBER); + if (prev != null) + { + int pageNum = Integer.parseInt(prev); + getGroupPager().setOffset( + (pageNum - 1) * getGroupPager().getLimit()); + return; + } + + String next = (String) requestMap + .get(PALAdminConstants.NEXT_PAGE_NUMBER); + if (next != null) + { + int pageNum = Integer.parseInt(next); + getGroupPager().setOffset( + (pageNum - 1) * getGroupPager().getLimit()); + return; + } + } + + public List<Map<String, Object>> getGroups(GroupListPage page) + { + GroupPager pager = getGroupPager(); + + List<Map<String, Object>> list = new ArrayList<Map<String, Object>>(); + groupDxo.convert(securityProviderLogic.getGroups(pager), list); + + // update page + page.setCount(pager.getCount()); + page.setMaxPageNumber((pager.getCount() - 1) / pager.getLimit() + 1); + page.setCurrentPageNumber(pager.getOffset() / pager.getLimit() + 1); + if (page.getMaxPageNumber() > page.getCurrentPageNumber()) + { + page.setNextPageNumber(page.getCurrentPageNumber() + 1); + } + else + { + page.setNextPageNumber(null); + } + if (page.getCurrentPageNumber() > 1) + { + page.setPreviousPageNumber(page.getCurrentPageNumber() - 1); + } + else + { + page.setPreviousPageNumber(null); + } + + return list; + } + + public void insert(AbstractGroupPage page) throws PALAdminException + { + Group entity = new Group(); + groupDxo.convert(page, entity); + securityProviderLogic.insertGroup(entity); + } + + public void delete(AbstractGroupPage page) throws PALAdminException + { + Group entity = new Group(); + groupDxo.convert(page, entity); + securityProviderLogic.deleteGroup(entity); + } +} Property changes on: pal-admin/trunk/src/main/java/jp/sf/pal/admin/service/GroupManagementService.java ___________________________________________________________________ Name: svn:eol-style + native Added: pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/AbstractGroupPage.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/AbstractGroupPage.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/AbstractGroupPage.java 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,48 @@ +package jp.sf.pal.admin.web.group; + +import jp.sf.pal.admin.service.GroupManagementService; +import jp.sf.pal.admin.web.AbstractCrudPage; + +import org.seasar.teeda.extension.annotation.validator.Required; + +public class AbstractGroupPage extends AbstractCrudPage +{ + + private String name; + + private GroupManagementService groupManagementService; + + public AbstractGroupPage() + { + super(); + } + + public String getName() + { + return name; + } + + @Required + public void setName(String groupName) + { + this.name = groupName; + } + + /** + * @return the groupManagementService + */ + public GroupManagementService getGroupManagementService() + { + return groupManagementService; + } + + /** + * @param groupManagementService the groupManagementService to set + */ + public void setGroupManagementService( + GroupManagementService groupManagementService) + { + this.groupManagementService = groupManagementService; + } + +} \ No newline at end of file Property changes on: pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/AbstractGroupPage.java ___________________________________________________________________ Name: svn:eol-style + native Added: pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupConfirmPage.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupConfirmPage.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupConfirmPage.java 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,80 @@ +package jp.sf.pal.admin.web.group; + +import javax.faces.internal.FacesMessageUtil; + +import jp.sf.pal.admin.PALAdminException; +import jp.sf.pal.admin.web.CrudType; +import jp.sf.pal.admin.web.role.RoleConfirmPage; + +import org.seasar.framework.log.Logger; +import org.seasar.teeda.extension.annotation.takeover.TakeOver; +import org.seasar.teeda.extension.annotation.takeover.TakeOverType; + +public class GroupConfirmPage extends AbstractGroupPage +{ + /** + * Logger for this class + */ + private static final Logger logger = Logger + .getLogger(RoleConfirmPage.class); + + public String initialize() + { + return null; + } + + public String prerender() + { + return null; + } + + @TakeOver(type = TakeOverType.NEVER) + public Class doFinish() + { + switch (getCrudType()) + { + case CrudType.CREATE: + try + { + getGroupManagementService().insert(this); + FacesMessageUtil.addInfoMessage("added.new.group", + new Object[] { getName() }); + } + catch (PALAdminException e) + { + FacesMessageUtil.addErrorMessage("failed.to.add.new.group", + new Object[] { getName() }); + logger.error("Failed to add a new group: " + getName(), e); + } + break; + // case CrudType.UPDATE: + // break; + case CrudType.DELETE: + try + { + getGroupManagementService().delete(this); + FacesMessageUtil.addInfoMessage("deleted.group", + new Object[] { getName() }); + } + catch (PALAdminException e) + { + FacesMessageUtil.addErrorMessage("failed.to.delete.group", + new Object[] { getName() }); + logger.error("Failed to delete a new group: " + getName(), + e); + } + break; + default: + break; + } + return GroupListPage.class; + } + + public boolean isComeFromList() + { + return getCrudType() == CrudType.READ + || getCrudType() == CrudType.DELETE; + + } + +} Property changes on: pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupConfirmPage.java ___________________________________________________________________ Name: svn:eol-style + native Added: pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupEditPage.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupEditPage.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupEditPage.java 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,17 @@ +package jp.sf.pal.admin.web.group; + +public class GroupEditPage extends AbstractGroupPage +{ + + public String initialize() + { + return null; + } + + public String prerender() + { + // update + return null; + } + +} Property changes on: pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupEditPage.java ___________________________________________________________________ Name: svn:eol-style + native Added: pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupListPage.java =================================================================== --- pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupListPage.java 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupListPage.java 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,92 @@ +package jp.sf.pal.admin.web.group; + +import java.util.List; +import java.util.Map; + +import jp.sf.pal.admin.service.GroupManagementService; +import jp.sf.pal.admin.web.AbstractListPage; +import jp.sf.pal.admin.web.CrudType; + +import org.seasar.teeda.extension.annotation.takeover.TakeOver; + +public class GroupListPage extends AbstractListPage +{ + + private int groupIndex; + + private List<Map<String, Object>> groupItems; + + private String name; + + private GroupManagementService groupManagementService; + + public int getGroupIndex() + { + return groupIndex; + } + + public void setGroupIndex(int groupIndex) + { + this.groupIndex = groupIndex; + } + + public List<Map<String, Object>> getGroupItems() + { + return groupItems; + } + + public void setGroupItems(List<Map<String, Object>> groupItems) + { + this.groupItems = groupItems; + } + + public String getName() + { + return name; + } + + public void setName(String name) + { + this.name = name; + } + + /** + * @return the groupManagementService + */ + public GroupManagementService getGroupManagementService() + { + return groupManagementService; + } + + /** + * @param groupManagementService the groupManagementService to set + */ + public void setGroupManagementService( + GroupManagementService groupManagementService) + { + this.groupManagementService = groupManagementService; + } + + public String initialize() + { + return null; + } + + public String prerender() + { + // check page action + groupManagementService.handlePagerNavigation(); + + // set role list + setGroupItems(groupManagementService.getGroups(this)); + + return null; + } + + @TakeOver(properties = "crudType") + public Class doCreate() + { + setCrudType(CrudType.CREATE); + return GroupEditPage.class; + } +} Property changes on: pal-admin/trunk/src/main/java/jp/sf/pal/admin/web/group/GroupListPage.java ___________________________________________________________________ Name: svn:eol-style + native Modified: pal-admin/trunk/src/main/resources/appMessages.properties =================================================================== --- pal-admin/trunk/src/main/resources/appMessages.properties 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/resources/appMessages.properties 2007-04-05 14:00:51 UTC (rev 19) @@ -4,3 +4,7 @@ deleted.role=Delete the Role({0}). failed.to.delete.role=Failed to delete the Role({0}). +added.new.group=Added a new Group({0}). +failed.to.add.new.group=Failed to add a new Group({0}). +deleted.group=Delete the Group({0}). +failed.to.delete.group=Failed to delete the Group({0}). Added: pal-admin/trunk/src/main/resources/jp/sf/pal/admin/web/group/label.properties =================================================================== --- pal-admin/trunk/src/main/resources/jp/sf/pal/admin/web/group/label.properties 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/resources/jp/sf/pal/admin/web/group/label.properties 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,7 @@ +# Common +groupName=Group Name +groupList=Group List +groupInformation=Group Information + +# groupList +groupList.delete=Delete Property changes on: pal-admin/trunk/src/main/resources/jp/sf/pal/admin/web/group/label.properties ___________________________________________________________________ Name: svn:eol-style + native Copied: pal-admin/trunk/src/main/webapp/view/group/groupConfirm.html (from rev 15, pal-admin/trunk/src/main/webapp/view/group/roleConfirm.html) =================================================================== --- pal-admin/trunk/src/main/webapp/view/group/roleConfirm.html 2007-04-05 08:59:21 UTC (rev 15) +++ pal-admin/trunk/src/main/webapp/view/group/groupConfirm.html 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,52 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!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"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<link rel="stylesheet" type="text/css" href="../../css/global.css"/> +</head> +<body> +<form id="GroupConfirmForm"><input type="hidden" id="crudType" /> +<!-- tab: BEGIN --> +<div style="padding: 0px 0px 3px 10px; margin:5px 0px;border-bottom:1px solid #000000;"> + <a id="jumpUserList" href="../user/userList.html" style="text-decoration: none;"> + <span id="userTabLabel" style="font-weight: bold;color:#ffffff;background-color:#999999;border:1px solid #000000; padding: 3px 5px 3px 5px; margin: 0px 0px;">User</span> + </a> + <a id="jumpRoleList" href="../role/roleList.html" style="text-decoration: none;"> + <span id="roleTabLabel" style="font-weight: bold;color:#ffffff;background-color:#999999;border:1px solid #000000; padding: 3px 5px 3px 5px; margin: 0px 0px;">Role</span> + </a> + <span id="groupTabLabel" style="border-top:1px solid #000000;border-right:1px solid #000000;border-bottom:1px solid #ffffff;border-left:1px solid #000000;padding: 3px 5px 3px 5px; margin: 0px 0px;">Group</span> +</div> +<!-- tab: END --> + +<div> + <span id="allMessages" fatalClass="portlet-msg-error" errorClass="portlet-msg-error" warnClass="portlet-msg-alert" infoClass="portlet-msg-info"></span> +</div> + +<!-- content: BEGIN --> +<div style="padding:5px 0px;"> + <div class="portlet-section-header"> + <label id="groupInformationLabel">Group Information</label> + </div> + + <table class="tablebg"> + <tr> + <td class="portlet-section-subheader"><label id="groupNameLabel">Group Name</label></td> + <td class="portlet-section-body"><span id="name">group</span><input type="hidden" id="name-hidden" /></td> + <td class="portlet-section-body"><span id="nameMessage"></span></td> + </tr> + </table> + + <div> + <div id="isComeFromList" style="display:inline;"> + <input type="button" id="jumpGroupList" value="Back" + onclick="location.href='groupList.html'" class="portlet-form-button"/> + </div> + <div id="isNotRead" style="display:inline;"> + <input type="button" id="doFinish" value="Finish" onclick="location.href='groupList.html'" class="portlet-form-button"/> + </div> + </div> +</div> +<!-- content: END --> +</form> +</body></html> Copied: pal-admin/trunk/src/main/webapp/view/group/groupEdit.html (from rev 15, pal-admin/trunk/src/main/webapp/view/group/roleEdit.html) =================================================================== --- pal-admin/trunk/src/main/webapp/view/group/roleEdit.html 2007-04-05 08:59:21 UTC (rev 15) +++ pal-admin/trunk/src/main/webapp/view/group/groupEdit.html 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!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"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<link rel="stylesheet" type="text/css" href="../../css/global.css"/> +</head> +<body> +<form id="GroupEditForm"><input type="hidden" id="crudType" /> +<!-- tab: BEGIN --> +<div style="padding: 0px 0px 3px 10px; margin:5px 0px;border-bottom:1px solid #000000;"> + <a id="jumpUserList" href="../user/userList.html" style="text-decoration: none;"> + <span id="userTabLabel" style="font-weight: bold;color:#ffffff;background-color:#999999;border:1px solid #000000; padding: 3px 5px 3px 5px; margin: 0px 0px;">User</span> + </a> + <a id="jumpRoleList" href="../role/roleList.html" style="text-decoration: none;"> + <span id="roleTabLabel" style="font-weight: bold;color:#ffffff;background-color:#999999;border:1px solid #000000; padding: 3px 5px 3px 5px; margin: 0px 0px;">Role</span> + </a> + <span id="groupTabLabel" style="border-top:1px solid #000000;border-right:1px solid #000000;border-bottom:1px solid #ffffff;border-left:1px solid #000000;padding: 3px 5px 3px 5px; margin: 0px 0px;">Group</span> +</div> +<!-- tab: END --> + +<div> + <span id="allMessages" fatalClass="portlet-msg-error" errorClass="portlet-msg-error" warnClass="portlet-msg-alert" infoClass="portlet-msg-info"></span> +</div> + +<!-- content: BEGIN --> +<div style="padding:5px 0px;"> + <div class="portlet-section-header"> + <label id="groupInformationLabel">Group Information</label> + </div> + + <table class="tablebg"> + <tr> + <td class="portlet-section-subheader"><label id="groupNameLabel">Group Name</label></td> + <td class="portlet-section-body"><input type="text" id="name"/></td> + <td class="portlet-section-body"><span id="nameMessage"></span></td> + </tr> + </table> + + <div> + <input type="button" id="jumpGroupList" value="Back" + onclick="location.href='groupList.html'" class="portlet-form-button"/> + <div id="isNotRead" style="display:inline;"> + <input type="button" id="goGroupConfirm" value="Confirm" + onclick="location.href='groupConfirm.html'" class="portlet-form-button"/> + </div> + </div> +</div> +<!-- content: BEGIN --> +</form> +</body></html> Copied: pal-admin/trunk/src/main/webapp/view/group/groupList.html (from rev 15, pal-admin/trunk/src/main/webapp/view/group/roleList.html) =================================================================== --- pal-admin/trunk/src/main/webapp/view/group/roleList.html 2007-04-05 08:59:21 UTC (rev 15) +++ pal-admin/trunk/src/main/webapp/view/group/groupList.html 2007-04-05 14:00:51 UTC (rev 19) @@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!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:te="http://www.seasar.org/teeda/extension"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<link rel="stylesheet" type="text/css" href="../../css/global.css"/> +</head> +<body> +<form id="GroupListForm"> +<!-- tab: BEGIN --> +<div style="padding: 0px 0px 3px 10px; margin:5px 0px;border-bottom:1px solid #000000;"> + <a id="jumpUserList" href="../user/userList.html" style="text-decoration: none;"> + <span id="userTabLabel" style="font-weight: bold;color:#ffffff;background-color:#999999;border:1px solid #000000; padding: 3px 5px 3px 5px; margin: 0px 0px;">User</span> + </a> + <a id="jumpRoleList" href="../role/roleList.html" style="text-decoration: none;"> + <span id="roleTabLabel" style="font-weight: bold;color:#ffffff;background-color:#999999;border:1px solid #000000; padding: 3px 5px 3px 5px; margin: 0px 0px;">Role</span> + </a> + <span id="groupTabLabel" style="border-top:1px solid #000000;border-right:1px solid #000000;border-bottom:1px solid #ffffff;border-left:1px solid #000000;padding: 3px 5px 3px 5px; margin: 0px 0px;">Group</span> +</div> +<!-- tab: END --> + +<div> + <span id="allMessages" fatalClass="portlet-msg-error" errorClass="portlet-msg-error" warnClass="portlet-msg-alert" infoClass="portlet-msg-info"></span> +</div> + +<!-- content: BEGIN --> +<div style="padding:5px 0px;"> + <div class="portlet-section-header"> + <label id="groupListLabel">Group List</label> + </div> + + <div> + <label id="actionLabel" class="portlet-form-label">Action:</label> + <input type="button" id="doCreate" value="Create" onclick="location.href='groupEdit.html'" class="portlet-form-button"/><br/> + </div> + + <div> + <span id="count-header">10</span><!-- TODO: i18n--> <label id="foundLabel"> found.</label> + (<span id="currentPageNumber-header">3</span>/<span id="maxPageNumber-header">5</span>) + </div> + + <div> + <a id="goPreviousPage-header" href="groupList.html?previousPageNumber=1" + te:rendered="#{group_groupListPage.previousPageNumber!=null}"> + <span id="previousPageLabel-header"><<Previous</span> + </a> + <a id="goNextPage-header" href="groupList.html?nextPageNumber=2" + te:rendered="#{group_groupListPage.nextPageNumber!=null}"> + <span id="nextPageLabel-header">Next>></span> + </a> + </div> + + <table> + <thead class="portlet-section-subheader"> + <tr> + <th><label id="groupNameLabel">Group Name</label></th> + <th><br/></th> + </tr> + </thead> + <tbody> + <div id="groupItems"> + <tr> + <td class="portlet-section-body"><span id="name">group</span></td> + <td class="portlet-section-alternate"> + <a id="goGroupConfirm" href="groupConfirm.html?fixed_crudType=3&name=name"><span id="deleteLabel">Delete</span></a> + </td> + </tr> + </div> + </tbody> + </table> + + <div> + <a id="goPreviousPage-footer" href="groupList.html?previousPageNumber=1" + te:rendered="#{group_groupListPage.previousPageNumber!=null}"> + <span id="previousPageLabel-footer"><<Previous</span> + </a> + <a id="goNextPage-footer" href="groupList.html?nextPageNumber=2" + te:rendered="#{group_groupListPage.nextPageNumber!=null}"> + <span id="nextPageLabel-footer">Next>></span> + </a> + </div> +</div> +<!-- content: END --> +</form> +</body></html> Deleted: pal-admin/trunk/src/main/webapp/view/group/roleConfirm.html =================================================================== --- pal-admin/trunk/src/main/webapp/view/group/roleConfirm.html 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/webapp/view/group/roleConfirm.html 2007-04-05 14:00:51 UTC (rev 19) @@ -1,40 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!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"> -<head> -<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<link rel="stylesheet" type="text/css" href="../../css/global.css"/> -</head> -<body> -<form id="RoleConfirmForm"><input type="hidden" id="crudType" /> -<!-- tab: BEGIN --> -<a id="jumpUserList" href="../user/userList.html"><label id="userTabLabel">User</label></a> | -<label id="roleTabLabel">Role</label> | -<a id="jumpUserList" href="../group/groupList.html"><label id="groupTabLabel">Group</label></a> <br/> -<!-- tab: END --> - -<div> -<span id="messages"></span> -</div> -<table class="tablebg"> -<tr> - <td><label id="roleNameLabel">Role Name</label></td> - <td><span id="roleName">role</span><input type="hidden" id="roleName-hidden" /></td> - <td><span id="roleNameMessage"></span></td> -</tr> -</table> -<div id="isComeFromList"> - <input type="button" id="jumpRoleList" value="Previous" - onclick="location.href='roleList.html'" - /> -</div> -<div id="isNotComeFromList" style="display: none;"> - <input type="button" id="jumpRoleEdit" value="Previous" - onclick="location.href='roleEdit.html'" - /> -</div> -<div id="isNotRead"> -<input type="button" id="doFinish" value="Finish" onclick="location.href='roleList.html'" /> -</div> -</form> -</body></html> Deleted: pal-admin/trunk/src/main/webapp/view/group/roleEdit.html =================================================================== --- pal-admin/trunk/src/main/webapp/view/group/roleEdit.html 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/webapp/view/group/roleEdit.html 2007-04-05 14:00:51 UTC (rev 19) @@ -1,61 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!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"> -<head> -<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<link rel="stylesheet" type="text/css" href="../../css/global.css"/> -</head> -<body> -<form id="RoleEditForm"><input type="hidden" id="crudType" /> -<div> -<span id="messages"></span> -</div> -<table class="tablebg"> -<tr> - <td><label id="idLabel">id</label></td> - <td><div id="isCreate"> - <input type="text" id="id"/> - </div> - <div id="isNotCreate" style="display: none;"> - <span id="id-out">id</span><input type="hidden" id="id-hidden" /> - </div></td> - <td><span id="idMessage"></span></td> -</tr> -<tr> - <td><label id="nameLabel">name</label></td> - <td><input type="text" id="name"/></td> - <td><span id="nameMessage"></span></td> -</tr> -<tr> - <td><label id="number1Label">number1</label></td> - <td><input type="text" id="number1"/></td> - <td><span id="number1Message"></span></td> -</tr> -<tr> - <td><label id="number2Label">number2</label></td> - <td><input type="text" id="number2"/></td> - <td><span id="number2Message"></span></td> -</tr> -<tr> - <td><label id="number3Label">number3</label></td> - <td><input type="text" id="number3"/></td> - <td><span id="number3Message"></span></td> -</tr> -<tr> - <td><label id="textLabel">text</label></td> - <td><input type="text" id="text"/></td> - <td><span id="textMessage"></span></td> -</tr> -<tr> - <td><label id="notesLabel">notes</label></td> - <td><input type="text" id="notes"/></td> - <td><span id="notesMessage"></span></td> -</tr> -</table> -<input type="button" id="jumpRoleList" value="Previous" - onclick="location.href='RoleList.html'"/> -<div id="isNotRead"> -<input type="button" id="goRoleConfirm" value="Confirm" - onclick="location.href='RoleConfirm.html'"/></div> -</form> -</body></html> Deleted: pal-admin/trunk/src/main/webapp/view/group/roleList.html =================================================================== --- pal-admin/trunk/src/main/webapp/view/group/roleList.html 2007-04-05 13:57:49 UTC (rev 18) +++ pal-admin/trunk/src/main/webapp/view/group/roleList.html 2007-04-05 14:00:51 UTC (rev 19) @@ -1,37 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!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"> -<head> -<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> -<link rel="stylesheet" type="text/css" href="../../css/global.css"/> -</head> -<body> -<form id="RoleListForm"> -<!-- tab: BEGIN --> -<a id="jumpUserList" href="../user/userList.html"><label id="userTabLabel">User</label></a> | -<label id="roleTabLabel">Role</label> | -<a id="jumpGroupList" href="../group/groupList.html"><label id="groupTabLabel">Group</label></a> <br/> -<!-- tab: END --> - - -<input type="button" id="goRoleEdit" value="Create" onclick="location.href='roleEdit.html'"/><br/> -<table> - <thead> - <tr height="50px"> - <th><label id="roleNameLabel">Role Name</label></th> - <th><br/></th> - </tr> - </thead> - <tbody> - <div id=""> - <tr class="row_even"> - <td><span id="roleName">role</span></td> - <td> - <a id="goRoleConfirm" href="roleConfirm.html?fixed_crudType=3&id=id">Delete</a> - </td> - </tr> - </div> - </tbody> -</table> -</form> -</body></html>