int sizeGroup = jrs.getRowCount();
for (int i = 1; i <= sizeGroup; ++i)
{
jrs.absolute(i);
WorkflowDepartment workflowDepartment =
createDepartment(
jrs.getString("vc_uuid"),
jrs.getString("vc_name"),
jrs.getString("vc_description"),
parentDept);
workflowDepartment.setCategory(findCategory(jrs.getString("vc_categoryid")));
workflowDepartment.setPresident(findParticipant(jrs.getString("vc_presidentid")));
departments.put(jrs.getString("vc_uuid"), workflowDepartment);
genDepartmentTree(departments, workflowDepartment);
}
jrs.release();
}
catch (SQLException sqlex)
{
;
}
}
else
{
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try
{
strSQL += " WHERE vc_parent=?";
conn = ConnUtils.getConnection(getStore());
pstmt = conn.prepareStatement(strSQL);
pstmt.setString(1, parentDept.getUUID());
rs = pstmt.executeQuery();
while (rs.next())
{
WorkflowDepartment workflowDepartment =
createDepartment_impl(
rs.getString("vc_uuid"),
rs.getString("vc_name"),
rs.getString("vc_description"),
parentDept);
workflowDepartment.setCategory(findCategory(rs.getString("vc_categoryid")));
workflowDepartment.setPresident(findParticipant(rs.getString("vc_presidentid")));
departments.put(rs.getString("vc_uuid"), workflowDepartment);
genDepartmentTree(departments, workflowDepartment);
}
}
catch (SQLException sqlex)