提交 24982ff2 作者: xiaowang

Merge branch 'develop'

...@@ -18,4 +18,4 @@ patches: ...@@ -18,4 +18,4 @@ patches:
images: images:
- name: REGISTRY/NAMESPACE/IMAGE:TAG - name: REGISTRY/NAMESPACE/IMAGE:TAG
newName: mmc-registry.cn-shenzhen.cr.aliyuncs.com/sharefly-dev/pms newName: mmc-registry.cn-shenzhen.cr.aliyuncs.com/sharefly-dev/pms
newTag: eebdf3dd0f1a02d80d325291be9ab36093d8f496 newTag: e00d10cefb341b9b5ab38a774728fa4c968bcaf2
...@@ -28,9 +28,9 @@ public class ProductReportController { ...@@ -28,9 +28,9 @@ public class ProductReportController {
@ApiOperation(value = "获取用户报表数据") @ApiOperation(value = "获取用户报表数据")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = ProductReportDTO.class)}) @ApiResponses({@ApiResponse(code = 200, message = "OK", response = ProductReportDTO.class)})
@GetMapping("/getUserReportData") @GetMapping("/getProductReportData")
public ResultBody<ProductReportDTO> getUserReportData() { public ResultBody<ProductReportDTO> getProductReportData() {
return productReportService.getUserReportData(); return productReportService.getProductReportData();
} }
} }
...@@ -83,7 +83,7 @@ public class MallGoodsDO implements Serializable { ...@@ -83,7 +83,7 @@ public class MallGoodsDO implements Serializable {
private Integer imgId; private Integer imgId;
private List<MallGoodsDO> mallGoodsDOList; private List<MallGoodsDO> mallGoodsDOList;
private PriceStockDO priceStockDO; private List<PriceStockDO> priceStockDOS;
public MallGoodsDO(MallGoodsVO mallGoodsVO) { public MallGoodsDO(MallGoodsVO mallGoodsVO) {
this.id = mallGoodsVO.getId(); this.id = mallGoodsVO.getId();
...@@ -118,9 +118,7 @@ public class MallGoodsDO implements Serializable { ...@@ -118,9 +118,7 @@ public class MallGoodsDO implements Serializable {
public UavCartDTO buildUavCartDTO() { public UavCartDTO buildUavCartDTO() {
return UavCartDTO.builder().mallGoodsId(id).thirdBackUserAccountId(userAccountId).tradeName(tradeName) return UavCartDTO.builder().mallGoodsId(id).thirdBackUserAccountId(userAccountId).tradeName(tradeName)
.productSpec(priceStockDO.getProductSpec()).salePrice(priceStockDO.getSalePrice()) .priceShow(priceShow).deleted(deleted).shelfStatus(shelfStatus).build();
.skuImage(priceStockDO.getSkuImage() == null ? url : priceStockDO.getSkuImage())
.skuNo(priceStockDO.getSkuNo()).priceShow(priceShow).deleted(deleted).shelfStatus(shelfStatus).build();
} }
} }
...@@ -9,6 +9,6 @@ import com.mmc.pms.model.data.dto.ProductReportDTO; ...@@ -9,6 +9,6 @@ import com.mmc.pms.model.data.dto.ProductReportDTO;
* 概要: * 概要:
*/ */
public interface ProductReportService { public interface ProductReportService {
ResultBody<ProductReportDTO> getUserReportData(); ResultBody<ProductReportDTO> getProductReportData();
} }
...@@ -31,7 +31,7 @@ public class ProductReportServiceImpl implements ProductReportService { ...@@ -31,7 +31,7 @@ public class ProductReportServiceImpl implements ProductReportService {
ImsAppApi imsAppApi; ImsAppApi imsAppApi;
@Override @Override
public ResultBody<ProductReportDTO> getUserReportData() { public ResultBody<ProductReportDTO> getProductReportData() {
// 获取入驻商家总数 // 获取入驻商家总数
ProductReportDTO joinStoreNumber = userAppApi.getJoinStoreNumber(); ProductReportDTO joinStoreNumber = userAppApi.getJoinStoreNumber();
// 获取销售商品个数 // 获取销售商品个数
......
...@@ -3,12 +3,14 @@ package com.mmc.pms.service.mall.impl; ...@@ -3,12 +3,14 @@ package com.mmc.pms.service.mall.impl;
import com.mmc.pms.common.ResultBody; import com.mmc.pms.common.ResultBody;
import com.mmc.pms.dao.mall.AppMallGoodsDao; import com.mmc.pms.dao.mall.AppMallGoodsDao;
import com.mmc.pms.entity.mall.MallGoodsDO; import com.mmc.pms.entity.mall.MallGoodsDO;
import com.mmc.pms.entity.mall.PriceStockDO;
import com.mmc.pms.model.mall.GoodsListVO; import com.mmc.pms.model.mall.GoodsListVO;
import com.mmc.pms.model.mall.MallGoodsVO; import com.mmc.pms.model.mall.MallGoodsVO;
import com.mmc.pms.model.mall.UavCartDTO; import com.mmc.pms.model.mall.UavCartDTO;
import com.mmc.pms.model.qo.mall.PriceStockQO; import com.mmc.pms.model.qo.mall.PriceStockQO;
import com.mmc.pms.service.mall.AppMallGoodsService; import com.mmc.pms.service.mall.AppMallGoodsService;
import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import javax.annotation.Resource; import javax.annotation.Resource;
...@@ -69,6 +71,19 @@ public class AppMallGoodsServiceImpl implements AppMallGoodsService { ...@@ -69,6 +71,19 @@ public class AppMallGoodsServiceImpl implements AppMallGoodsService {
public List<UavCartDTO> listPriceStock(List<PriceStockQO> param) { public List<UavCartDTO> listPriceStock(List<PriceStockQO> param) {
// 根据商品id和规格套装查询 // 根据商品id和规格套装查询
List<MallGoodsDO> mallGoodsList = appMallGoodsDao.listPriceStock(param); List<MallGoodsDO> mallGoodsList = appMallGoodsDao.listPriceStock(param);
return mallGoodsList.stream().map(MallGoodsDO::buildUavCartDTO).collect(Collectors.toList()); List<UavCartDTO> uavCartDTOS = new ArrayList<UavCartDTO>();
for (MallGoodsDO mallGoodsDO : mallGoodsList) {
if (CollectionUtils.isNotEmpty(mallGoodsDO.getPriceStockDOS())) {
for (PriceStockDO priceStockDO : mallGoodsDO.getPriceStockDOS()) {
UavCartDTO uavCartDTO = mallGoodsDO.buildUavCartDTO();
uavCartDTO.setSkuImage(StringUtils.isBlank(priceStockDO.getSkuImage()) ? mallGoodsDO.getUrl() : priceStockDO.getSkuImage());
uavCartDTO.setProductSpec(priceStockDO.getProductSpec());
uavCartDTO.setSalePrice(priceStockDO.getSalePrice());
uavCartDTO.setSkuNo(priceStockDO.getSkuNo());
uavCartDTOS.add(uavCartDTO);
}
}
}
return uavCartDTOS;
} }
} }
...@@ -105,11 +105,9 @@ ...@@ -105,11 +105,9 @@
where id = #{id} where id = #{id}
</update> </update>
<update id="remove"> <delete id="remove">
update company_inspection delete from company_inspection where id = #{id}
set is_deleted = 1 </delete>
where id = #{id}
</update>
<update id="updateRemark"> <update id="updateRemark">
update company_inspection update company_inspection
......
...@@ -74,12 +74,13 @@ ...@@ -74,12 +74,13 @@
<result column="url" property="url"/> <result column="url" property="url"/>
<result column="is_deleted" property="deleted"/> <result column="is_deleted" property="deleted"/>
<result column="shelf_status" property="shelfStatus"/> <result column="shelf_status" property="shelfStatus"/>
<association property="priceStockDO" javaType="com.mmc.pms.entity.mall.PriceStockDO"> <collection property="priceStockDOS" ofType="com.mmc.pms.entity.mall.PriceStockDO" >
<id column="productSpecId" property="id"/>
<result column="product_spec" property="productSpec"/> <result column="product_spec" property="productSpec"/>
<result column="sku_image" property="skuImage"/> <result column="sku_image" property="skuImage"/>
<result column="sale_price" property="salePrice"/> <result column="sale_price" property="salePrice"/>
<result column="sku_no" property="skuNo"/> <result column="sku_no" property="skuNo"/>
</association> </collection>
</resultMap> </resultMap>
<select id="listPriceStock" resultMap="resultMallGoodsMap"> <select id="listPriceStock" resultMap="resultMallGoodsMap">
SELECT SELECT
...@@ -90,6 +91,7 @@ ...@@ -90,6 +91,7 @@
mg.is_deleted, mg.is_deleted,
mg.shelf_status, mg.shelf_status,
mgr.url url, mgr.url url,
ps.id as productSpecId,
ps.product_spec, ps.product_spec,
ps.sale_price, ps.sale_price,
ps.sku_image, ps.sku_image,
......
...@@ -22,6 +22,7 @@ data-filter: ...@@ -22,6 +22,7 @@ data-filter:
- /pms/category/appCategoryInfo - /pms/category/appCategoryInfo
- /pms/app/goods/queryBrandGoods - /pms/app/goods/queryBrandGoods
- /pms/app/goods/queryGoodsInfoByCategorySub - /pms/app/goods/queryGoodsInfoByCategorySub
- /pms/app/goods/listPriceStock
- /pms/mall/goods/feignRemoveGoodsByBackUserAccountId - /pms/mall/goods/feignRemoveGoodsByBackUserAccountId
- /pms/app/lease/leaseGoodsDetails - /pms/app/lease/leaseGoodsDetails
- /pms/app/lease/leaseGoodsList - /pms/app/lease/leaseGoodsList
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论