Compare commits
6 Commits
84206e653d
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| 44b64aa9df | |||
| 97ad9f1bbb | |||
| 25d2148d8e | |||
| 37e942c0c9 | |||
| 429a2c6f9e | |||
| 7a7c2e85e3 |
@@ -22,7 +22,7 @@ public class CartPageController {
|
||||
}
|
||||
|
||||
|
||||
@GetMapping("/cart_oder_success")
|
||||
@GetMapping("/cart_order_success")
|
||||
public String cartOrderSuccessPage() {
|
||||
return "cart_order_success";
|
||||
}
|
||||
|
||||
@@ -51,6 +51,7 @@ public class UserController {
|
||||
|
||||
@PostMapping("/user/update")
|
||||
public ServerResponseEntity<Boolean> updatePassword(@RequestBody PasswordData passwordData) {
|
||||
logger.info("request passwordData: {}",passwordData);
|
||||
if(passwordData != null){
|
||||
boolean isSuccess = userService.updateUserPasswordByUserId(passwordData);
|
||||
if (isSuccess) {
|
||||
|
||||
@@ -36,7 +36,9 @@ public class UserService {
|
||||
|
||||
public boolean updateUserPasswordByUserId(PasswordData passwordData) {
|
||||
String currentPassword = queryPasswordByUserId(passwordData.getUserId());
|
||||
if (currentPassword == passwordData.getOldPassword()) {
|
||||
logger.info("currentPassword: {}, oldPassword: {}.",currentPassword,passwordData.getOldPassword());
|
||||
if (currentPassword.equals(passwordData.getOldPassword())) {
|
||||
logger.info("start update password.");
|
||||
UpdateWrapper<User> updateWrapper = new UpdateWrapper<>();
|
||||
updateWrapper.eq("user_id", passwordData.getUserId())
|
||||
.set("password", passwordData.getNewPassword());
|
||||
|
||||
@@ -52,9 +52,7 @@
|
||||
|
||||
function toPay() {
|
||||
var nu = '1';
|
||||
|
||||
window.location = "cart_agreement.html";
|
||||
|
||||
window.location = "/cart_agreement";
|
||||
}
|
||||
</script>
|
||||
<!--内容-->
|
||||
|
||||
@@ -58,12 +58,14 @@
|
||||
var nu = '1';
|
||||
|
||||
if (check()) {
|
||||
$("#aspnetForm").submit();
|
||||
// $("#aspnetForm").submit();
|
||||
window.location.href = "/cart_order";
|
||||
}
|
||||
|
||||
}
|
||||
$(function() {
|
||||
$("#aspnetForm").attr("action", "/cart_order");
|
||||
// window.location.href = "/cart_order";
|
||||
});
|
||||
</script>
|
||||
<!--真爱协议中的内容-->
|
||||
|
||||
@@ -179,15 +179,16 @@
|
||||
//check
|
||||
if ($(".shop_adress-top:not(:last) :radio:checked").length == 0) {
|
||||
alert("请先选择一个地址。");
|
||||
return;
|
||||
}
|
||||
var nu = '1';
|
||||
|
||||
$("#aspnetForm").submit();
|
||||
// $("#aspnetForm").submit();
|
||||
window.location.href = "/cart_order_success";
|
||||
|
||||
}
|
||||
$(function() {
|
||||
$("#aspnetForm").attr("action", "/cart_order_success");
|
||||
// window.location.href = "/cart_order_success";
|
||||
// $("#aspnetForm").attr("action", "/cart_order_success");
|
||||
});
|
||||
</script>
|
||||
<!--内容-->
|
||||
|
||||
Reference in New Issue
Block a user