|
@@ -15,10 +15,7 @@ import com.sunxung.factoring.service.sys.UserService;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.stereotype.Controller;
|
|
import org.springframework.stereotype.Controller;
|
|
import org.springframework.ui.Model;
|
|
import org.springframework.ui.Model;
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
-import org.springframework.web.bind.annotation.RequestMethod;
|
|
|
|
-import org.springframework.web.bind.annotation.RequestParam;
|
|
|
|
-import org.springframework.web.bind.annotation.ResponseBody;
|
|
|
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
import javax.servlet.http.HttpServletRequest;
|
|
import java.util.List;
|
|
import java.util.List;
|
|
@@ -57,24 +54,24 @@ public class UserController {
|
|
@RequestMapping(value = "/user/do_updateSimpleUser", method = RequestMethod.POST)
|
|
@RequestMapping(value = "/user/do_updateSimpleUser", method = RequestMethod.POST)
|
|
@ResponseBody
|
|
@ResponseBody
|
|
@OperationLog(operationModule = "用户信息",operationType = OperationTypeEnum.UPDATE,description = "个人信息修改")
|
|
@OperationLog(operationModule = "用户信息",operationType = OperationTypeEnum.UPDATE,description = "个人信息修改")
|
|
- public Object do_userInfoUpdate(User user) {
|
|
|
|
|
|
+ public Object do_userInfoUpdate(@RequestBody User user) {
|
|
return userService.updateSimpleUserInfo(user);
|
|
return userService.updateSimpleUserInfo(user);
|
|
}
|
|
}
|
|
|
|
|
|
- /**
|
|
|
|
- * 修改密码
|
|
|
|
- */
|
|
|
|
- @RequestMapping("/user/updatePassword")
|
|
|
|
- public String currSetPassword(Model model) {
|
|
|
|
- model.addAttribute("userId", ThreadLocalUtil.getUserId());
|
|
|
|
- return PREFIX + "updatePassword";
|
|
|
|
- }
|
|
|
|
|
|
+// /**
|
|
|
|
+// * 修改密码
|
|
|
|
+// */
|
|
|
|
+// @RequestMapping("/user/updatePassword")
|
|
|
|
+// public String currSetPassword(Model model) {
|
|
|
|
+// model.addAttribute("userId", ThreadLocalUtil.getUserId());
|
|
|
|
+// return PREFIX + "updatePassword";
|
|
|
|
+// }
|
|
|
|
|
|
- @RequestMapping(value = "/user/do_updatePassword", method = RequestMethod.POST)
|
|
|
|
|
|
+ @RequestMapping(value = "/user/updatePassword/{newPwd}", method = RequestMethod.PUT)
|
|
@ResponseBody
|
|
@ResponseBody
|
|
@OperationLog(operationModule = "用户信息",operationType = OperationTypeEnum.UPDATE,description = "修改密码")
|
|
@OperationLog(operationModule = "用户信息",operationType = OperationTypeEnum.UPDATE,description = "修改密码")
|
|
- public Object do_updatePassword(Long id, String password, String oldPassword, String password1) {
|
|
|
|
- return userService.updatePassword(id, password, oldPassword, password1);
|
|
|
|
|
|
+ public Object do_updatePassword(@PathVariable("newPwd") String pwd) {
|
|
|
|
+ return userService.updatePassword(pwd);
|
|
}
|
|
}
|
|
|
|
|
|
@RequestMapping("/user/isAgreement")
|
|
@RequestMapping("/user/isAgreement")
|