本文整理汇总了Java中org.kuali.rice.kew.quicklinks.ActionListStats类的典型用法代码示例。如果您正苦于以下问题:Java ActionListStats类的具体用法?Java ActionListStats怎么用?Java ActionListStats使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ActionListStats类属于org.kuali.rice.kew.quicklinks包,在下文中一共展示了ActionListStats类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getActionListStats
import org.kuali.rice.kew.quicklinks.ActionListStats; //导入依赖的package包/类
@Override
@SuppressWarnings("unchecked")
public List<ActionListStats> getActionListStats(final String principalId) {
try {
final List<Object[]> stats = getEntityManager().createNamedQuery("ActionItem.GetQuickLinksDocumentTypeNameAndCount").
setParameter("principalId", principalId).setParameter("delegationType", DelegationType
.SECONDARY.getCode()).getResultList();
final List<ActionListStats> docTypes = new ArrayList<ActionListStats>(stats.size());
for (Object[] res : stats) {
final String docTypeName = (String) res[0];
final Long count = (Long) res[1];
final DocumentType docType = getDocumentTypeService().findByName(docTypeName);
if(docType != null){
docTypes.add(new ActionListStats(docTypeName, docType.getLabel(), count.intValue()));
}
}
Collections.sort(docTypes);
return docTypes;
} catch (Exception e) {
throw new WorkflowRuntimeException("Error getting action list stats for user: " + principalId, e);
}
}
示例2: getActionListStats
import org.kuali.rice.kew.quicklinks.ActionListStats; //导入依赖的package包/类
@Override
@SuppressWarnings("unchecked")
public List<ActionListStats> getActionListStats(final String principalId) {
try {
final List<Object[]> stats = entityManager.createNamedQuery("ActionItem.QuickLinks.FindActionListStatsByPrincipalId").setParameter("principalId", principalId).setParameter("delegationType", DelegationType
.SECONDARY.getCode()).getResultList();
final List<ActionListStats> docTypes = new ArrayList<ActionListStats>(stats.size());
for (Object[] res : stats) {
final String docTypeName = (String) res[0];
final Long count = (Long) res[1];
final List<String> docTypeLabel = entityManager.createNamedQuery("DocumentType.QuickLinks.FindLabelByTypeName").setParameter("docTypeName", docTypeName).getResultList();
if (docTypeLabel.size() > 0) {
docTypes.add(new ActionListStats(docTypeName, docTypeLabel.get(0), count.intValue()));
}
}
Collections.sort(docTypes);
return docTypes;
} catch (Exception e) {
throw new WorkflowRuntimeException("Error getting action list stats for user: " + principalId, e);
}
}
示例3: getActionListStats
import org.kuali.rice.kew.quicklinks.ActionListStats; //导入依赖的package包/类
@Override
public List<ActionListStats> getActionListStats(String principalId) {
return getQuickLinksDAO().getActionListStats(principalId);
}
示例4: getActionListStats
import org.kuali.rice.kew.quicklinks.ActionListStats; //导入依赖的package包/类
public List<ActionListStats> getActionListStats(String principalId);