Commit 0ce00b1d by wangjf

fix userName to username

parent 32d77411
......@@ -132,7 +132,7 @@ public class UserController {
@PostMapping("/user/exit")
@ResponseBody
boolean exit(@RequestParam(name = "userName") String username) {
boolean exit(@RequestParam(name = "username") String username) {
// 存在,不通过,false
return !userService.exit(username);
}
......
......@@ -26,8 +26,8 @@ public class UserServiceImpl implements UserService {
@Override
public boolean createUser(Map<String, Object> uMap, String userId) {
User user = new User();
user.setUserId(uMap.get("userName").toString());
user.setUserName(uMap.get("userName").toString());
user.setUserId(uMap.get("username").toString());
user.setUserName(uMap.get("username").toString());
try {
user.setPassword(MD5Util.getMD5Str(uMap.get("password").toString()));
} catch (Exception e) {
......
......@@ -49,7 +49,7 @@ function validateRule() {
type : "post", // 数据发送方式
dataType : "json", // 接受数据格式
data : { // 要传递的数据
userName : function() {
username : function() {
return $("#username").val();
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment