Example #1
0
  /**
   * 차트 All 테스트
   *
   * @param model
   * @param request
   * @param response
   * @return
   * @throws ServletException
   * @throws IOException
   */
  @SuppressWarnings("unchecked")
  @RequestMapping("/testAllChart")
  // @RequestMapping(value="member_secede.jab", method = RequestMethod.POST)
  public ModelMap testAllChart(
      ModelMap model, HttpServletRequest request, HttpServletResponse response) {
    ParameterUtil p = new ParameterUtil();
    HashMap<String, Object> param = p.setParameter(request);

    /*
    @SuppressWarnings("rawtypes")
    List list = service.getHtHm100(param);

    model.addAttribute("dataLst", list);
    */

    model.addAttribute("gradeLst", JsonUtil.toJson(service.getGradeList(param)));
    model.addAttribute("deptLst", JsonUtil.toJson(service.getDeptList(param)));

    return model;
  }
Example #2
0
  /**
   * 조직도 테스트
   *
   * @param model
   * @param request
   * @param response
   * @return
   * @throws ServletException
   * @throws IOException
   */
  @SuppressWarnings("unchecked")
  @RequestMapping("/getOrganization")
  // @RequestMapping(value="member_secede.jab", method = RequestMethod.POST)
  public void getOrganization(
      ModelMap model, HttpServletRequest request, HttpServletResponse response) throws IOException {
    ParameterUtil p = new ParameterUtil();
    HashMap<String, String> param = p.setParameter(request);

    response.setContentType("text/html;charset=UTF-8");
    response.setHeader("Cache-Control", "no-cache");
    response.setCharacterEncoding("UTF-8");

    PrintWriter out = response.getWriter();

    // JSON 객체 생성
    // JSONArray jsonArray = new JSONArray();

    logger.info(service.getOrganization(param));

    out.print(service.getOrganization(param));
    out.flush();
  }
Example #3
0
  /**
   * 부서리스트 구하기
   *
   * @param model
   * @param request
   * @param response
   * @return
   * @throws ServletException
   * @throws IOException
   */
  @SuppressWarnings("unchecked")
  @RequestMapping("/getDeptLst")
  // @RequestMapping(value="member_secede.jab", method = RequestMethod.POST)
  public void getDeptLst(ModelMap model, HttpServletRequest request, HttpServletResponse response)
      throws IOException {
    ParameterUtil p = new ParameterUtil();
    HashMap<String, String> param = p.setParameter(request);

    response.setContentType("text/xml;charset=UTF-8");
    response.setHeader("Cache-Control", "no-cache");
    response.setCharacterEncoding("UTF-8");

    PrintWriter out = response.getWriter();

    out.println(JsonUtil.toJson(service.getDeptList(param)));
  }