Skip to content

Commit 86fac03

Browse files
author
xenv
committed
fixed bugs
1 parent 8ffb742 commit 86fac03

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/main/java/tmall/controller/front/UserFrontController.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,15 @@ public String registerAdd(String name ,String password , Model model) throws Exc
2626
if(userService.isExist(name)){
2727
msg = "用户名已存在,无法注册,请重新输入";
2828
}
29+
if (msg != null ) {
30+
model.addAttribute("msg",msg);
31+
return "register";
32+
}
2933
User user = new User();
3034
user.setName(name);
3135
user.setPassword(password);
3236
user.setGroup(User.Group.user);
3337
userService.add(user);
34-
if (msg != null ) {
35-
model.addAttribute("msg",msg);
36-
return "register";
37-
}
3838
return "registerSuccess";
3939
}
4040
@RequestMapping("login")

src/main/webapp/WEB-INF/jsp/admin/listOrder.jsp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
<table class="table table-striped">
6565
<c:forEach items="${o.orderItems}" var="item" varStatus="vs">
6666
<tr>
67-
<td><img width="40px" height="40px" src="${productImgDir}${item.product.image.path}"></td>
67+
<td><img width="40px" height="40px" src="../../../${productImgDir}${item.product.image.path}"></td>
6868
<td>${item.product.name}</td>
6969
<td>${item.number}个</td>
7070
<td>单价${item.product.nowPrice}元</td>

0 commit comments

Comments
 (0)