generated from root/miduo_server
增加返回码为200
parent
2326045f63
commit
8a879025ae
|
|
@ -15,11 +15,13 @@ import com.mongodb.BasicDBObject;
|
||||||
import com.mongodb.DBObject;
|
import com.mongodb.DBObject;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
import org.springframework.http.HttpStatus;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
import org.springframework.ui.ModelMap;
|
import org.springframework.ui.ModelMap;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.ResponseBody;
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseStatus;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
|
@ -86,6 +88,7 @@ public class UserInfoController {
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequestMapping(value = "/gomotaGetRoleList", method = {RequestMethod.POST, RequestMethod.GET})
|
@RequestMapping(value = "/gomotaGetRoleList", method = {RequestMethod.POST, RequestMethod.GET})
|
||||||
|
@ResponseStatus(HttpStatus.OK)
|
||||||
public String gomotaGetRoleInfo(ModelMap map, HttpServletRequest request) throws Exception {
|
public String gomotaGetRoleInfo(ModelMap map, HttpServletRequest request) throws Exception {
|
||||||
HashMap<String, String> parameterMap = JsonUtil.getInstence().getParameterMap(request);
|
HashMap<String, String> parameterMap = JsonUtil.getInstence().getParameterMap(request);
|
||||||
String appota_user_id = request.getParameter("appota_user_id");
|
String appota_user_id = request.getParameter("appota_user_id");
|
||||||
|
|
@ -107,7 +110,7 @@ public class UserInfoController {
|
||||||
return resp.toString();
|
return resp.toString();
|
||||||
}
|
}
|
||||||
if (StringUtils.checkIsEmpty(api_key)) {
|
if (StringUtils.checkIsEmpty(api_key)) {
|
||||||
resp.put("message", "sub_channel null");
|
resp.put("message", "api_key null");
|
||||||
resp.put("error_code", 1);
|
resp.put("error_code", 1);
|
||||||
resp.put("data", roleList);
|
resp.put("data", roleList);
|
||||||
return resp.toString();
|
return resp.toString();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue