当前位置: 首页>>代码示例>>Java>>正文


Java RoleDocumentDelegationMemberQualifier.setAttrVal方法代码示例

本文整理汇总了Java中org.kuali.rice.kim.bo.ui.RoleDocumentDelegationMemberQualifier.setAttrVal方法的典型用法代码示例。如果您正苦于以下问题:Java RoleDocumentDelegationMemberQualifier.setAttrVal方法的具体用法?Java RoleDocumentDelegationMemberQualifier.setAttrVal怎么用?Java RoleDocumentDelegationMemberQualifier.setAttrVal使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.kuali.rice.kim.bo.ui.RoleDocumentDelegationMemberQualifier的用法示例。


在下文中一共展示了RoleDocumentDelegationMemberQualifier.setAttrVal方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setDelegationMemberRoleMemberId

import org.kuali.rice.kim.bo.ui.RoleDocumentDelegationMemberQualifier; //导入方法依赖的package包/类
/**
 * @param delegationMemberRoleMemberId the delegationMemberRoleMemberId to set
 */
public void setDelegationMemberRoleMemberId(String delegationMemberRoleMemberId) {
	this.delegationMemberRoleMemberId = delegationMemberRoleMemberId;
	getDelegationMember().setRoleMemberId(delegationMemberRoleMemberId);
	KimDocumentRoleMember roleMember = getRoleDocument().getMember(delegationMemberRoleMemberId);
	if(roleMember!=null){
		delegationMember.setRoleMemberId(roleMember.getRoleMemberId());
		delegationMember.setRoleMemberName(roleMember.getMemberName());
		delegationMember.setRoleMemberNamespaceCode(roleMember.getMemberNamespaceCode());
		RoleDocumentDelegationMemberQualifier delegationMemberQualifier;
		for(KimDocumentRoleQualifier roleQualifier: roleMember.getQualifiers()){
			delegationMemberQualifier = getDelegationMember().getQualifier(roleQualifier.getKimAttrDefnId());
			delegationMemberQualifier.setAttrVal(roleQualifier.getAttrVal());
		}
	}
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:19,代码来源:IdentityManagementRoleDocumentForm.java

示例2: addDelegationMember

import org.kuali.rice.kim.bo.ui.RoleDocumentDelegationMemberQualifier; //导入方法依赖的package包/类
public ActionForward addDelegationMember(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception {
    IdentityManagementPersonDocumentForm personDocumentForm = (IdentityManagementPersonDocumentForm) form;
    IdentityManagementPersonDocument personDocument = personDocumentForm.getPersonDocument();
    RoleDocumentDelegationMember newDelegationMember = personDocumentForm.getNewDelegationMember();
    KimTypeAttributesHelper attrHelper = newDelegationMember.getAttributesHelper();
    if (getKualiRuleService().applyRules(new AddPersonDelegationMemberEvent("", personDocumentForm.getPersonDocument(), newDelegationMember))) {
     //RoleImpl roleBo = (RoleImpl)getUiDocumentService().getMember(KimApiConstants.KimUIConstants.MEMBER_TYPE_ROLE_CODE, newDelegationMember.getRoleDao().getRoleId());
     Role role;
    	role = KimApiServiceLocator.getRoleService().getRole(newDelegationMember.getRoleBo().getId());
     if (role != null) {
      if(!validateRole(newDelegationMember.getRoleBo().getId(),role, PersonDocumentRoleRule.ERROR_PATH, "Person")){
      	return mapping.findForward(RiceConstants.MAPPING_BASIC);
      }
      newDelegationMember.setRoleBo(RoleBo.from(role));
     }
     KimAttributeField attrDefinition;
     RoleMemberBo roleMember = KIMServiceLocatorInternal.getUiDocumentService().getRoleMember(newDelegationMember.getRoleMemberId());
     Map<String, String>
                roleMemberAttributes = (new AttributeValidationHelper()).convertAttributesToMap(roleMember.getAttributeDetails());
     for (KimAttributeField key: attrHelper.getDefinitions()) {
     	RoleDocumentDelegationMemberQualifier qualifier = new RoleDocumentDelegationMemberQualifier();
     	attrDefinition = key;
     	qualifier.setKimAttrDefnId(attrHelper.getKimAttributeDefnId(attrDefinition));
     	qualifier.setAttrVal(attrHelper.getAttributeValue(roleMemberAttributes, attrDefinition.getAttributeField().getName()));
        	newDelegationMember.setMemberTypeCode(MemberType.PRINCIPAL.getCode());
     	newDelegationMember.getQualifiers().add(qualifier);
     }
     //newDelegationMember.setAttributeEntry(getUiDocumentService().getAttributeEntries(newDelegationMember.getAttributesHelper().getDefinitions())));
        newDelegationMember.setMemberId(personDocument.getPrincipalId());
     personDocument.getDelegationMembers().add(newDelegationMember);
     personDocumentForm.setNewDelegationMember(new RoleDocumentDelegationMember());
    }
    return mapping.findForward(RiceConstants.MAPPING_BASIC);
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:35,代码来源:IdentityManagementPersonDocumentAction.java

示例3: changeDelegationMemberTypeCode

import org.kuali.rice.kim.bo.ui.RoleDocumentDelegationMemberQualifier; //导入方法依赖的package包/类
public ActionForward changeDelegationMemberTypeCode(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception {
    IdentityManagementRoleDocumentForm roleDocumentForm = (IdentityManagementRoleDocumentForm) form;
    KimDocumentRoleMember roleMember = roleDocumentForm.getRoleDocument().getMember(roleDocumentForm.getDelegationMember().getRoleMemberId());
    if (roleMember != null) {
        RoleDocumentDelegationMemberQualifier delegationMemberQualifier;
        for (KimDocumentRoleQualifier roleQualifier : roleMember.getQualifiers()) {
            delegationMemberQualifier = roleDocumentForm.getDelegationMember().getQualifier(roleQualifier.getKimAttrDefnId());
            delegationMemberQualifier.setAttrVal(roleQualifier.getAttrVal());
        }
    }
    return refresh(mapping, roleDocumentForm, request, response);
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:13,代码来源:IdentityManagementRoleDocumentAction.java

示例4: addDelegationMember

import org.kuali.rice.kim.bo.ui.RoleDocumentDelegationMemberQualifier; //导入方法依赖的package包/类
public ActionForward addDelegationMember(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception {
    IdentityManagementPersonDocumentForm personDocumentForm = (IdentityManagementPersonDocumentForm) form;
    IdentityManagementPersonDocument personDocument = personDocumentForm.getPersonDocument();
    RoleDocumentDelegationMember newDelegationMember = personDocumentForm.getNewDelegationMember();
    KimTypeAttributesHelper attrHelper = newDelegationMember.getAttributesHelper();
    if (getKualiRuleService().applyRules(new AddPersonDelegationMemberEvent("", personDocumentForm.getPersonDocument(), newDelegationMember))) {
     //RoleImpl roleBo = (RoleImpl)getUiDocumentService().getMember(KimApiConstants.KimUIConstants.MEMBER_TYPE_ROLE_CODE, newDelegationMember.getRoleDao().getRoleId());
     Role role;
    	role = KimApiServiceLocator.getRoleService().getRole(newDelegationMember.getRoleBo().getId());
     if (role != null) {
      if(!validateRole(newDelegationMember.getRoleBo().getId(),role, PersonDocumentRoleRule.ERROR_PATH, "Person")){
      	return mapping.findForward(RiceConstants.MAPPING_BASIC);
      }
      newDelegationMember.setRoleBo(RoleBo.from(role));
     }
     KimAttributeField attrDefinition;
     RoleMemberBo roleMember = KIMServiceLocatorInternal.getUiDocumentService().getRoleMember(newDelegationMember.getRoleMemberId());
     Map<String, String>
                roleMemberAttributes = (new AttributeValidationHelper()).convertAttributesToMap(roleMember.getAttributeDetails());
     for (KimAttributeField key: attrHelper.getDefinitions()) {
     	RoleDocumentDelegationMemberQualifier qualifier = new RoleDocumentDelegationMemberQualifier();
     	attrDefinition = key;
     	qualifier.setKimAttrDefnId(attrHelper.getKimAttributeDefnId(attrDefinition));
     	qualifier.setAttrVal(attrHelper.getAttributeValue(roleMemberAttributes, attrDefinition.getAttributeField().getName()));
     	newDelegationMember.setMemberId(personDocument.getPrincipalId());
     	newDelegationMember.setMemberTypeCode(MemberType.PRINCIPAL.getCode());
     	newDelegationMember.getQualifiers().add(qualifier);
     }
     //newDelegationMember.setAttributeEntry(getUiDocumentService().getAttributeEntries(newDelegationMember.getAttributesHelper().getDefinitions())));
     personDocument.getDelegationMembers().add(newDelegationMember);
     personDocumentForm.setNewDelegationMember(new RoleDocumentDelegationMember());
    }
    return mapping.findForward(RiceConstants.MAPPING_BASIC);
}
 
开发者ID:aapotts,项目名称:kuali_rice,代码行数:35,代码来源:IdentityManagementPersonDocumentAction.java


注:本文中的org.kuali.rice.kim.bo.ui.RoleDocumentDelegationMemberQualifier.setAttrVal方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。