2204A-cyj(添加 11.26)
parent
78c47a1d90
commit
f041621ae4
|
@ -0,0 +1,23 @@
|
||||||
|
{
|
||||||
|
"拼团名称": "String",
|
||||||
|
"商品活动图": "String",
|
||||||
|
"商品ID": "Long",
|
||||||
|
"策略ID": "Long",
|
||||||
|
"团购活动ID": "Long",
|
||||||
|
"商品sku": [
|
||||||
|
"Long","Long"
|
||||||
|
],
|
||||||
|
"轮播图": [
|
||||||
|
|
||||||
|
],
|
||||||
|
"活动排序": "",
|
||||||
|
"活动详情": "",
|
||||||
|
|
||||||
|
"策略类型": "",
|
||||||
|
|
||||||
|
"库存": "",
|
||||||
|
"活动状态": "",
|
||||||
|
"活动结束时间": "",
|
||||||
|
"商品状态": "",
|
||||||
|
|
||||||
|
}
|
|
@ -60,6 +60,6 @@ public class ActivityTeamProductSkuInfo extends BaseEntity {
|
||||||
.teamStock(activityTeamProductSkuAddModel.getTeamStock())
|
.teamStock(activityTeamProductSkuAddModel.getTeamStock())
|
||||||
.remainStock(activityTeamProductSkuAddModel.getTeamStock())
|
.remainStock(activityTeamProductSkuAddModel.getTeamStock())
|
||||||
.teamPrice(activityTeamProductSkuAddModel.getTeamPrice())
|
.teamPrice(activityTeamProductSkuAddModel.getTeamPrice())
|
||||||
.build()
|
.build();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -85,12 +85,8 @@ public class ActivityTeamInfoAddModel {
|
||||||
|
|
||||||
/** addReq 转话addModel模型**/
|
/** addReq 转话addModel模型**/
|
||||||
public static ActivityTeamInfoAddModel convertAddModel(ActivityTeamInfoSaveReq addReq) {
|
public static ActivityTeamInfoAddModel convertAddModel(ActivityTeamInfoSaveReq addReq) {
|
||||||
List<ProjectSkuInfoAddReq> addReqList = addReq.getProjectSkuInfoAddReqList();
|
|
||||||
addReqList.stream().map(skuInfoAdd->{ActivityTeamProductSkuAddModel.convertProductSkuList(skuInfoAdd);
|
|
||||||
} ).toList();
|
|
||||||
|
|
||||||
ActivityTeamProductSkuAddModel.convertProductSkuList();
|
return ActivityTeamInfoAddModel.builder()
|
||||||
return ActivityTeamInfoAddModel.builder()
|
|
||||||
.name(addReq.getName())
|
.name(addReq.getName())
|
||||||
.productId(addReq.getProductId())
|
.productId(addReq.getProductId())
|
||||||
.productImage(addReq.getProductImage())
|
.productImage(addReq.getProductImage())
|
||||||
|
@ -99,7 +95,10 @@ public class ActivityTeamInfoAddModel {
|
||||||
.imageList(addReq.getImageList())
|
.imageList(addReq.getImageList())
|
||||||
.endTime(addReq.getEndTime())
|
.endTime(addReq.getEndTime())
|
||||||
.sort(addReq.getSort())
|
.sort(addReq.getSort())
|
||||||
.activityTeamProductSkuAddModelList(addModelList)
|
.activityTeamProductSkuAddModelList(addReq.getProjectSkuInfoAddReqList()
|
||||||
|
.stream()
|
||||||
|
.map(projectSkuInfoAddReq -> ActivityTeamProductSkuAddModel.convertProductSkuList(projectSkuInfoAddReq, addReq))
|
||||||
|
.toList())
|
||||||
.content(addReq.getContent())
|
.content(addReq.getContent())
|
||||||
.status(addReq.getStatus())
|
.status(addReq.getStatus())
|
||||||
.strategyType(addReq.getStrategyType())
|
.strategyType(addReq.getStrategyType())
|
||||||
|
|
|
@ -49,12 +49,13 @@ public class ActivityTeamProductSkuAddModel {
|
||||||
private Long teamStock;
|
private Long teamStock;
|
||||||
|
|
||||||
/** ProjectSkuInfoAddReq 转换 ProductSkuAddModel **/
|
/** ProjectSkuInfoAddReq 转换 ProductSkuAddModel **/
|
||||||
public static ActivityTeamProductSkuAddModel convertProductSkuList(ProjectSkuInfoAddReq skuInfoAdd) {
|
public static ActivityTeamProductSkuAddModel convertProductSkuList(ProjectSkuInfoAddReq skuInfoAdd,ActivityTeamInfoSaveReq addReq) {
|
||||||
return ActivityTeamProductSkuAddModel
|
return ActivityTeamProductSkuAddModel
|
||||||
.builder()
|
.builder()
|
||||||
.sku(skuInfoAdd.getSku())
|
.sku(skuInfoAdd.getSku())
|
||||||
.teamPrice(skuInfoAdd.getTeamPrice())
|
.teamPrice(skuInfoAdd.getTeamPrice())
|
||||||
.teamStock(skuInfoAdd.getTeamStock())
|
.teamStock(skuInfoAdd.getTeamStock())
|
||||||
|
.productId(addReq.getProductId())
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,72 @@
|
||||||
|
package com.muyu.marketing.domain.resp;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.muyu.marketing.domain.req.ProjectSkuInfoAddReq;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/** 拼团活动回显对象*/
|
||||||
|
public class ActivityTeamInfoResp {
|
||||||
|
/**
|
||||||
|
* 活动id
|
||||||
|
*/
|
||||||
|
private Long teamId;
|
||||||
|
/**
|
||||||
|
* 拼团名称
|
||||||
|
*/
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 商品ID
|
||||||
|
*/
|
||||||
|
private Long productId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 商品活动图
|
||||||
|
*/
|
||||||
|
private String productImage;
|
||||||
|
/**
|
||||||
|
* 活动简介
|
||||||
|
*/
|
||||||
|
private String introduction;
|
||||||
|
/**
|
||||||
|
* 单位
|
||||||
|
*/
|
||||||
|
|
||||||
|
private String unit;
|
||||||
|
/**
|
||||||
|
* 轮播图
|
||||||
|
*/
|
||||||
|
|
||||||
|
private String imageList;
|
||||||
|
/**
|
||||||
|
* 活动结束时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd")
|
||||||
|
private Date endTime;
|
||||||
|
/**
|
||||||
|
* 活动排序
|
||||||
|
*/
|
||||||
|
private Integer sort;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 商品SkU集合
|
||||||
|
*/
|
||||||
|
private List<ProjectSkuInfoAddResp> projectSkuInfoAddList;
|
||||||
|
/**
|
||||||
|
* 活动详情
|
||||||
|
*/
|
||||||
|
private String content;
|
||||||
|
/**
|
||||||
|
* 活动状态
|
||||||
|
*/
|
||||||
|
private String status;
|
||||||
|
/**
|
||||||
|
* 策略类型
|
||||||
|
*/
|
||||||
|
private String strategyType;
|
||||||
|
/**
|
||||||
|
* 策略ID
|
||||||
|
*/
|
||||||
|
private Long strategyId;
|
||||||
|
}
|
|
@ -0,0 +1,23 @@
|
||||||
|
package com.muyu.marketing.domain.resp;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
public class ProjectSkuInfoAddResp {
|
||||||
|
/**
|
||||||
|
* 规格SKU
|
||||||
|
*/
|
||||||
|
private String sku;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 拼团价格
|
||||||
|
*/
|
||||||
|
private BigDecimal teamPrice;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 拼团库存
|
||||||
|
*/
|
||||||
|
private Long teamStock;
|
||||||
|
|
||||||
|
/** 规格id*/
|
||||||
|
private Integer ruleId;
|
||||||
|
}
|
Loading…
Reference in New Issue