Beispiel #1
0
  /** hkf 验证子账号名 2013.1.9 */
  @GET
  public String checkoperator() {
    String operator = SysUtil.getDecode(this.getParam("operator").toString());
    OperatorService operatorService =
        (OperatorService) SofaSpringContext.getBean("operatorService");
    HttpServletResponse response = this.getResponseHelper().getResponse();
    if (operator.equals("admin")) {
      String jsonmsg = JsonGenerateUtil.getMsgJson("sorry");
      return new JsonResponse().responseJson(response, jsonmsg);
    }

    Map map = new HashMap();
    map.put("operator", operator);
    HttpServletRequest request = this.getResponseHelper().getRequest();
    SessionBean sessionBean = SessionUtil.getSession(request);
    map.put("partyid", sessionBean.getPartyid());
    String msg = operatorService.checkoperator(map);
    msg = JsonGenerateUtil.getMsgJson(msg);
    return new JsonResponse().responseJson(response, msg);
  }