订单列表增加店铺名称
This commit is contained in:
@@ -101,12 +101,14 @@ public class TbOrderInfo implements Serializable {
|
||||
private List<TbOrderDetail> detailList;
|
||||
private String winnnerNo;
|
||||
private String isWinner;
|
||||
private String shopName;
|
||||
|
||||
|
||||
//根据状态返回 需付款 已付款 未付款 已退
|
||||
private String description;
|
||||
|
||||
public void setDescription() {
|
||||
public void setDescription(String shopName) {
|
||||
this.shopName = shopName;
|
||||
switch (status) {
|
||||
case "closed":
|
||||
this.description = "已付款";
|
||||
|
||||
@@ -220,9 +220,11 @@ public class OrderService {
|
||||
// }
|
||||
PageHelper.startPage(page, size);
|
||||
List<TbOrderInfo> tbOrderInfos = orderInfoMapper.selectByUserId(userId, status);
|
||||
|
||||
String shopName = "";
|
||||
for (TbOrderInfo orderInfo : tbOrderInfos) {
|
||||
orderInfo.setDescription();
|
||||
TbShopInfo tbShopInfo = tbShopInfoMapper.selectByPrimaryKey(Integer.valueOf(orderInfo.getShopId()));
|
||||
shopName = tbShopInfo.getShopName();
|
||||
orderInfo.setDescription(shopName);
|
||||
List<TbOrderDetail> list = tbOrderDetailMapper.selectAllByOrderId(orderInfo.getId());
|
||||
int num = 0;
|
||||
for (TbOrderDetail orderDetail : list) {
|
||||
|
||||
Reference in New Issue
Block a user