赞
踩
实现查询商品列表功能
- public List<GoodListMangeDto> getAllGoodListByMerch(String merchId) {
- MPJLambdaWrapper<GoodListMangeDto> wrapper=new MPJLambdaWrapper<GoodListMangeDto>()
- .selectAll(GoodListMangeDto.class)
- .selectAs(MarketGoodListDto::getGoodName,GoodListMangeDto::getGoodName)
- .selectAs(MarketGoodListDto::getGoodLogo,GoodListMangeDto::getGoodLogo)
- .selectAs(MarketGoodListDto::getMarketPrice,GoodListMangeDto::getMarketPrice)
- .leftJoin(MarketGoodListDto.class,MarketGoodListDto::getGoodId,GoodMangeDto::getGoodId)
- .eq(GoodListMangeDto::getMerchId,merchId);
- List<GoodListMangeDto> list = goodListManagerDtoMapper.selectJoinList(GoodListMangeDto.class, wrapper);
- return list;
- }
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。