// 显示具体某个组的详细规则
 public String pureRuleList() {
   String id = getParaValue("id");
   CompGroupRuleDao groupRuleDao = new CompGroupRuleDao();
   CompGroupRule rule = (CompGroupRule) groupRuleDao.findByID(id);
   groupRuleDao.close();
   CompRuleDao dao = new CompRuleDao();
   String temp = rule.getRuleId();
   String ids = temp.substring(0, temp.lastIndexOf(","));
   List list = dao.findByCondition(" where ID in(" + ids + ")");
   request.setAttribute("list", list);
   return "/config/vpntelnet/compliance/pureRuleList.jsp";
 }
  // 保存工作组
  public String saveGroupRule() {
    String name = getParaValue("name");
    String desciption = getParaValue("description");
    String[] id = getParaArrayValue("checkbox");
    String ids = "";
    if (ids != null) {
      for (int i = 0; i < id.length; i++) {
        ids = ids + id[i] + ",";
      }
    }
    SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
    Date date = new Date();
    User user = (User) session.getAttribute(SessionConstant.CURRENT_USER);
    CompGroupRule vo = new CompGroupRule();
    vo.setName(name);

    vo.setDescription(desciption);
    vo.setRuleId(ids);
    vo.setCreatedBy(user.getName());
    vo.setCreatedTime(sdf.format(date));
    vo.setLastModifiedBy(user.getName());
    vo.setLastModifiedTime(sdf.format(date));
    CompGroupRuleDao dao = new CompGroupRuleDao();
    dao.save(vo);
    return null;
  }
  // 修改工作组
  public String updateGroupRule() {
    int id = getParaIntValue("id");
    String name = getParaValue("name");
    String desciption = getParaValue("description");
    String[] temp = getParaArrayValue("checkbox");

    StringBuffer ids = new StringBuffer();
    if (temp != null) {
      for (int i = 0; i < temp.length; i++) {
        ids.append(temp[i] + ",");
      }
    }
    SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
    Date date = new Date();
    User user = (User) session.getAttribute(SessionConstant.CURRENT_USER);
    CompGroupRule vo = new CompGroupRule();
    vo.setId(id);
    vo.setName(name);

    vo.setDescription(desciption);
    vo.setRuleId(ids.toString());
    vo.setLastModifiedBy(user.getName());
    vo.setLastModifiedTime(sdf.format(date));
    CompGroupRuleDao dao = new CompGroupRuleDao();
    dao.update(vo);
    return null;
  }