fix[litemall-wx,litemall-wx-api]: 修复一些小问题。
This commit is contained in:
@@ -237,6 +237,7 @@ public class WxAuthController {
|
||||
user.setStatus("可用");
|
||||
user.setLastLoginTime(LocalDateTime.now());
|
||||
user.setLastLoginIp(IpUtil.client(request));
|
||||
user.setAddTime(LocalDateTime.now());
|
||||
userService.add(user);
|
||||
|
||||
|
||||
|
||||
@@ -84,7 +84,14 @@ public class WxHomeController {
|
||||
l2List.add(catL2.getId());
|
||||
}
|
||||
|
||||
List<LitemallGoods> categoryGoods = goodsService.queryByCategory(l2List, 0, 5);
|
||||
List<LitemallGoods> categoryGoods = null;
|
||||
if(l2List.size() == 0){
|
||||
categoryGoods = new ArrayList<>();
|
||||
}
|
||||
else{
|
||||
categoryGoods = goodsService.queryByCategory(l2List, 0, 5);
|
||||
}
|
||||
|
||||
Map catGoods = new HashMap();
|
||||
catGoods.put("id", catL1.getId());
|
||||
catGoods.put("name", catL1.getName());
|
||||
|
||||
@@ -341,6 +341,7 @@ public class WxOrderController {
|
||||
orderGoods.setNumber(cartGoods.getNumber());
|
||||
orderGoods.setGoodsSpecificationIds(cartGoods.getGoodsSpecificationIds());
|
||||
orderGoods.setGoodsSpecificationValues(cartGoods.getGoodsSpecificationValues());
|
||||
orderGoods.setAddTime(LocalDateTime.now());
|
||||
|
||||
// 添加订单商品表项
|
||||
orderGoodsService.add(orderGoods);
|
||||
|
||||
@@ -162,6 +162,11 @@ Page({
|
||||
}
|
||||
});
|
||||
}
|
||||
else{
|
||||
wx.redirectTo({
|
||||
url: '/pages/payResult/payResult?status=0&orderId=' + orderId
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user