code review:订单逻辑

This commit is contained in:
YunaiV 2023-09-01 20:00:04 +08:00
parent 8dd600a300
commit 28adfff10e
2 changed files with 6 additions and 5 deletions

View File

@ -26,10 +26,11 @@ public class TradeOrderDetailRespVO extends TradeOrderBaseVO {
private MemberUserRespVO user; private MemberUserRespVO user;
/** /**
* TODO 订单操作日志, 先模拟一波 * TODO 订单操作日志, 先模拟一波返回 logs简洁然后复数哈
*/ */
private List<OrderLog> orderLog; private List<OrderLog> orderLog;
// TODO @puhui999swagger 注解
@Data @Data
public static class OrderLog { public static class OrderLog {

View File

@ -106,7 +106,7 @@ public class TradeOrderQueryServiceImpl implements TradeOrderQueryService {
throw exception(ORDER_NOT_FOUND); throw exception(ORDER_NOT_FOUND);
} }
return getTrackRespDTOs(order); return getExpressTrackList(order);
} }
@Override @Override
@ -117,16 +117,16 @@ public class TradeOrderQueryServiceImpl implements TradeOrderQueryService {
throw exception(ORDER_NOT_FOUND); throw exception(ORDER_NOT_FOUND);
} }
return getTrackRespDTOs(order); return getExpressTrackList(order);
} }
/** /**
* 得到物流轨迹 * 获得订单的物流轨迹
* *
* @param order 订单 * @param order 订单
* @return 物流轨迹 * @return 物流轨迹
*/ */
private List<ExpressTrackRespDTO> getTrackRespDTOs(TradeOrderDO order) { private List<ExpressTrackRespDTO> getExpressTrackList(TradeOrderDO order) {
// 查询物流公司 // 查询物流公司
if (order.getLogisticsId() == null) { if (order.getLogisticsId() == null) {
return Collections.emptyList(); return Collections.emptyList();