当前位置:   article > 正文

springboot项目之商品查询功能_springboot查询商品操作

springboot查询商品操作

实现查询商品列表功能

  1. public List<GoodListMangeDto> getAllGoodListByMerch(String merchId) {
  2. MPJLambdaWrapper<GoodListMangeDto> wrapper=new MPJLambdaWrapper<GoodListMangeDto>()
  3. .selectAll(GoodListMangeDto.class)
  4. .selectAs(MarketGoodListDto::getGoodName,GoodListMangeDto::getGoodName)
  5. .selectAs(MarketGoodListDto::getGoodLogo,GoodListMangeDto::getGoodLogo)
  6. .selectAs(MarketGoodListDto::getMarketPrice,GoodListMangeDto::getMarketPrice)
  7. .leftJoin(MarketGoodListDto.class,MarketGoodListDto::getGoodId,GoodMangeDto::getGoodId)
  8. .eq(GoodListMangeDto::getMerchId,merchId);
  9. List<GoodListMangeDto> list = goodListManagerDtoMapper.selectJoinList(GoodListMangeDto.class, wrapper);
  10. return list;
  11. }

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/不正经/article/detail/355617
推荐阅读
相关标签
  

闽ICP备14008679号