diff --git a/yudao-module-mall/yudao-module-market-biz/src/main/java/cn/iocoder/yudao/module/market/service/price/PriceApiImpl.java b/yudao-module-mall/yudao-module-market-biz/src/main/java/cn/iocoder/yudao/module/market/service/price/PriceApiImpl.java new file mode 100644 index 000000000..6b8663d1e --- /dev/null +++ b/yudao-module-mall/yudao-module-market-biz/src/main/java/cn/iocoder/yudao/module/market/service/price/PriceApiImpl.java @@ -0,0 +1,24 @@ +package cn.iocoder.yudao.module.market.service.price; + +import cn.iocoder.yudao.module.market.api.price.PriceApi; +import cn.iocoder.yudao.module.market.api.price.dto.PriceCalculateReqDTO; +import cn.iocoder.yudao.module.market.api.price.dto.PriceCalculateRespDTO; +import org.springframework.stereotype.Service; + +/** + * 价格 API 实现类 + * + * TODO 完善注释 + * + * @author TODO + */ +@Service +public class PriceApiImpl implements PriceApi { + + @Override + public PriceCalculateRespDTO calculatePrice(PriceCalculateReqDTO calculateReqDTO) { + // TODO fixme:实现逻辑 + return new PriceCalculateRespDTO(); + } + +} diff --git a/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/package-info.java b/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/package-info.java new file mode 100644 index 000000000..162453c3c --- /dev/null +++ b/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/package-info.java @@ -0,0 +1 @@ +package cn.iocoder.yudao.module.product.api; diff --git a/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/sku/ProductSkuApiImpl.java b/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/sku/ProductSkuApiImpl.java new file mode 100644 index 000000000..22636826b --- /dev/null +++ b/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/sku/ProductSkuApiImpl.java @@ -0,0 +1,26 @@ +package cn.iocoder.yudao.module.product.api.sku; + +import cn.iocoder.yudao.module.product.api.sku.dto.SkuDecrementStockBatchReqDTO; +import cn.iocoder.yudao.module.product.api.sku.dto.SkuInfoRespDTO; +import org.springframework.stereotype.Service; + +import java.util.Collection; +import java.util.List; + +/** + * todo 注释 + */ +@Service +public class ProductSkuApiImpl implements ProductSkuApi { + + @Override + public List getSkusByIds(Collection skuIds) { + return null; + } + + @Override + public void decrementStockBatch(SkuDecrementStockBatchReqDTO batchReqDTO) { + + } + +} diff --git a/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/spu/ProductSpuApiImpl.java b/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/spu/ProductSpuApiImpl.java new file mode 100644 index 000000000..8f651f395 --- /dev/null +++ b/yudao-module-mall/yudao-module-product-biz/src/main/java/cn/iocoder/yudao/module/product/api/spu/ProductSpuApiImpl.java @@ -0,0 +1,20 @@ +package cn.iocoder.yudao.module.product.api.spu; + +import cn.iocoder.yudao.module.product.api.spu.dto.SpuInfoRespDTO; +import org.springframework.stereotype.Service; + +import java.util.Collection; +import java.util.List; + +/** + * todo 注释 + */ +@Service +public class ProductSpuApiImpl implements ProductSpuApi { + + @Override + public List getSpusByIds(Collection spuIds) { + return null; + } + +} diff --git a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/controller/app/order/vo/AppTradeOrderCreateReqVO.java b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/controller/app/order/vo/AppTradeOrderCreateReqVO.java index d454fd63c..54e856a6b 100644 --- a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/controller/app/order/vo/AppTradeOrderCreateReqVO.java +++ b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/controller/app/order/vo/AppTradeOrderCreateReqVO.java @@ -17,7 +17,7 @@ public class AppTradeOrderCreateReqVO { private Integer addressId; @ApiModelProperty(name = "优惠劵编号", example = "1024") - private Integer couponId; + private Long couponId; @ApiModelProperty(name = "备注", example = "1024") private String remark; diff --git a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderConvert.java b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderConvert.java index dd3cca38e..1b81212b8 100644 --- a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderConvert.java +++ b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderConvert.java @@ -4,6 +4,7 @@ import cn.iocoder.yudao.module.market.api.price.dto.PriceCalculateRespDTO; import cn.iocoder.yudao.module.trade.controller.app.order.vo.AppTradeOrderCreateReqVO; import cn.iocoder.yudao.module.trade.dal.dataobject.order.TradeOrderDO; import org.mapstruct.Mapper; +import org.mapstruct.Mapping; import org.mapstruct.factory.Mappers; /** @@ -15,6 +16,6 @@ public interface TradeOrderConvert { TradeOrderConvert INSTANCE = Mappers.getMapper(TradeOrderConvert.class); - + @Mapping(source = "order.couponId", target = "couponId") TradeOrderDO convert(AppTradeOrderCreateReqVO createReqVO, PriceCalculateRespDTO.Order order); } diff --git a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderItemConvert.java b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderItemConvert.java index f9c44b4a6..23113f9f3 100644 --- a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderItemConvert.java +++ b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderItemConvert.java @@ -29,5 +29,8 @@ public interface TradeOrderItemConvert { @Mapping(source = "tradeOrder.userId", target = "userId"), @Mapping(source = "tradeOrder.orderId", target = "orderId") }) - List convertList(TradeOrderDO tradeOrder, List items); + default List convertList(TradeOrderDO tradeOrder, List items) { + // TODO @Com: Mapstruct 生成会报错 + throw new UnsupportedOperationException("无法实现"); + } } diff --git a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/dal/mysql/order/TradeOrderMapper.java b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/dal/mysql/order/TradeOrderMapper.java index ed74f9b6c..3b963540b 100644 --- a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/dal/mysql/order/TradeOrderMapper.java +++ b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/dal/mysql/order/TradeOrderMapper.java @@ -2,10 +2,12 @@ package cn.iocoder.yudao.module.trade.dal.mysql.order; import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX; import cn.iocoder.yudao.module.trade.dal.dataobject.order.TradeOrderDO; +import org.apache.ibatis.annotations.Mapper; /** * @author LeeYan9 * @since 2022-08-26 */ +@Mapper public interface TradeOrderMapper extends BaseMapperX { } diff --git a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/dal/mysql/orderitem/TradeOrderItemMapper.java b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/dal/mysql/orderitem/TradeOrderItemMapper.java index 4e33cddd1..987d5a3f5 100644 --- a/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/dal/mysql/orderitem/TradeOrderItemMapper.java +++ b/yudao-module-mall/yudao-module-trade-biz/src/main/java/cn/iocoder/yudao/module/trade/dal/mysql/orderitem/TradeOrderItemMapper.java @@ -2,10 +2,12 @@ package cn.iocoder.yudao.module.trade.dal.mysql.orderitem; import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX; import cn.iocoder.yudao.module.trade.dal.dataobject.order.TradeOrderItemDO; +import org.apache.ibatis.annotations.Mapper; /** * @author LeeYan9 * @since 2022-08-26 */ +@Mapper public interface TradeOrderItemMapper extends BaseMapperX { } diff --git a/yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/api/PayOrderApiImpl.java b/yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/api/PayOrderApiImpl.java new file mode 100644 index 000000000..ff902be92 --- /dev/null +++ b/yudao-module-pay/yudao-module-pay-biz/src/main/java/cn/iocoder/yudao/module/pay/api/PayOrderApiImpl.java @@ -0,0 +1,18 @@ +package cn.iocoder.yudao.module.pay.api; + +import cn.iocoder.yudao.module.pay.api.order.PayOrderApi; +import cn.iocoder.yudao.module.pay.api.order.PayOrderDataCreateReqDTO; +import org.springframework.stereotype.Service; + +/** + * TODO 注释 + */ +@Service +public class PayOrderApiImpl implements PayOrderApi { + + @Override + public Long createPayOrder(PayOrderDataCreateReqDTO reqDTO) { + return null; + } + +}