提交 e89a6f0e 作者: xiaowang

新增:展示价格

上级 1f8456e7
...@@ -49,8 +49,8 @@ public class LeaseGoodsController extends BaseController { ...@@ -49,8 +49,8 @@ public class LeaseGoodsController extends BaseController {
@ApiOperation(value = "租赁商品详情") @ApiOperation(value = "租赁商品详情")
@PostMapping("leaseGoodsDetails") @PostMapping("leaseGoodsDetails")
@ApiResponses({@ApiResponse(code = 200, message = "OK", response = ResultBody.class)}) @ApiResponses({@ApiResponse(code = 200, message = "OK", response = LeaseGoodsVO.class)})
public ResultBody leaseGoodsDetails(@RequestParam Integer id) { public ResultBody<LeaseGoodsVO> leaseGoodsDetails(@RequestParam Integer id) {
return leaseGoodsService.leaseGoodsDetails(id); return leaseGoodsService.leaseGoodsDetails(id);
} }
......
...@@ -7,6 +7,7 @@ import lombok.NoArgsConstructor; ...@@ -7,6 +7,7 @@ import lombok.NoArgsConstructor;
import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.CollectionUtils;
import java.io.Serializable; import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date; import java.util.Date;
import java.util.List; import java.util.List;
import java.util.stream.Collectors; import java.util.stream.Collectors;
...@@ -89,6 +90,8 @@ public class LeaseGoodsDO implements Serializable { ...@@ -89,6 +90,8 @@ public class LeaseGoodsDO implements Serializable {
*/ */
private Integer userAccountId; private Integer userAccountId;
private BigDecimal showPrice;
private Date createTime; private Date createTime;
private Date updateTime; private Date updateTime;
...@@ -122,6 +125,7 @@ public class LeaseGoodsDO implements Serializable { ...@@ -122,6 +125,7 @@ public class LeaseGoodsDO implements Serializable {
this.productDetails = leaseGoodsVO.getProductDetails(); this.productDetails = leaseGoodsVO.getProductDetails();
this.minLeaseTerm = leaseGoodsVO.getMinLeaseTerm(); this.minLeaseTerm = leaseGoodsVO.getMinLeaseTerm();
this.maxLeaseTerm = leaseGoodsVO.getMaxLeaseTerm(); this.maxLeaseTerm = leaseGoodsVO.getMaxLeaseTerm();
this.showPrice = leaseGoodsVO.getShowPrice();
this.shipAddress = leaseGoodsVO.getShipAddress(); this.shipAddress = leaseGoodsVO.getShipAddress();
this.returnAddress = leaseGoodsVO.getReturnAddress(); this.returnAddress = leaseGoodsVO.getReturnAddress();
this.logisticsCompany = leaseGoodsVO.getLogisticsCompany(); this.logisticsCompany = leaseGoodsVO.getLogisticsCompany();
...@@ -130,7 +134,7 @@ public class LeaseGoodsDO implements Serializable { ...@@ -130,7 +134,7 @@ public class LeaseGoodsDO implements Serializable {
} }
public LeaseGoodsVO buildLeaseGoodsVO() { public LeaseGoodsVO buildLeaseGoodsVO() {
return LeaseGoodsVO.builder().id(id).tradeName(tradeName) return LeaseGoodsVO.builder().id(id).tradeName(tradeName).showPrice(showPrice)
.sellingPoint(sellingPoint).level(level).shelfStatus(shelfStatus) .sellingPoint(sellingPoint).level(level).shelfStatus(shelfStatus)
.productTypeId(productTypeId).brandInfoId(brandInfoId).deviceModeId(deviceModeId) .productTypeId(productTypeId).brandInfoId(brandInfoId).deviceModeId(deviceModeId)
.productParam(productParam).productDetails(productDetails).minLeaseTerm(minLeaseTerm) .productParam(productParam).productDetails(productDetails).minLeaseTerm(minLeaseTerm)
......
...@@ -60,10 +60,6 @@ public class LeasePriceStockDO implements Serializable { ...@@ -60,10 +60,6 @@ public class LeasePriceStockDO implements Serializable {
*/ */
private BigDecimal maxDaysRental; private BigDecimal maxDaysRental;
/** /**
* 展示最低价
*/
private BigDecimal showPrice;
/**
* 库存 * 库存
*/ */
private Integer stock; private Integer stock;
...@@ -87,7 +83,6 @@ public class LeasePriceStockDO implements Serializable { ...@@ -87,7 +83,6 @@ public class LeasePriceStockDO implements Serializable {
this.thirtyDaysRental = param.getThirtyDaysRental(); this.thirtyDaysRental = param.getThirtyDaysRental();
this.ninetyDaysRental = param.getNinetyDaysRental(); this.ninetyDaysRental = param.getNinetyDaysRental();
this.maxDaysRental = param.getMaxDaysRental(); this.maxDaysRental = param.getMaxDaysRental();
this.showPrice = param.getShowPrice();
this.stockOut = param.getStockOut(); this.stockOut = param.getStockOut();
} }
...@@ -96,7 +91,7 @@ public class LeasePriceStockDO implements Serializable { ...@@ -96,7 +91,7 @@ public class LeasePriceStockDO implements Serializable {
.cashPledge(cashPledge).threeDaysRental(threeDaysRental) .cashPledge(cashPledge).threeDaysRental(threeDaysRental)
.sevenDaysRental(sevenDaysRental).thirtyDaysRental(thirtyDaysRental) .sevenDaysRental(sevenDaysRental).thirtyDaysRental(thirtyDaysRental)
.ninetyDaysRental(ninetyDaysRental).maxDaysRental(maxDaysRental) .ninetyDaysRental(ninetyDaysRental).maxDaysRental(maxDaysRental)
.showPrice(showPrice).skuImage(skuImage).stock(stock).stockOut(stockOut).build(); .skuImage(skuImage).stock(stock).stockOut(stockOut).build();
} }
} }
...@@ -13,6 +13,7 @@ import lombok.NoArgsConstructor; ...@@ -13,6 +13,7 @@ import lombok.NoArgsConstructor;
import javax.validation.constraints.NotEmpty; import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull; import javax.validation.constraints.NotNull;
import java.io.Serializable; import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date; import java.util.Date;
import java.util.List; import java.util.List;
...@@ -96,6 +97,9 @@ public class LeaseGoodsVO implements Serializable { ...@@ -96,6 +97,9 @@ public class LeaseGoodsVO implements Serializable {
@ApiModelProperty(value = "配送方式") @ApiModelProperty(value = "配送方式")
private Integer modeOfDelivery; private Integer modeOfDelivery;
@ApiModelProperty(value = "展示最低价", example = "1")
private BigDecimal showPrice;
@ApiModelProperty(value = "创建时间 用作列表回显", hidden = true) @ApiModelProperty(value = "创建时间 用作列表回显", hidden = true)
private Date createTime; private Date createTime;
......
...@@ -50,9 +50,6 @@ public class LeasePriceStockVO implements Serializable { ...@@ -50,9 +50,6 @@ public class LeasePriceStockVO implements Serializable {
@ApiModelProperty(value = "180天租金", example = "1") @ApiModelProperty(value = "180天租金", example = "1")
private BigDecimal maxDaysRental; private BigDecimal maxDaysRental;
@ApiModelProperty(value = "展示最低价", example = "1")
private BigDecimal showPrice;
@ApiModelProperty(value = "sku图片", example = "https://pad-video-x.oss-cn-shenzhen.aliyuncs.com/file/35bbd044-7cd7-4c85-ba27-69776e03dbb2.jpg") @ApiModelProperty(value = "sku图片", example = "https://pad-video-x.oss-cn-shenzhen.aliyuncs.com/file/35bbd044-7cd7-4c85-ba27-69776e03dbb2.jpg")
private String skuImage; private String skuImage;
......
...@@ -33,10 +33,12 @@ ...@@ -33,10 +33,12 @@
mode_of_delivery, mode_of_delivery,
user_account_id, user_account_id,
district_code, district_code,
show_price,
sort) sort)
values (#{tradeName}, #{sellingPoint}, #{level}, #{shelfStatus}, #{productTypeId}, #{brandInfoId}, values (#{tradeName}, #{sellingPoint}, #{level}, #{shelfStatus}, #{productTypeId}, #{brandInfoId},
#{deviceModeId}, #{productParam}, #{productDetails}, #{minLeaseTerm}, #{maxLeaseTerm}, #{shipAddress}, #{deviceModeId}, #{productParam}, #{productDetails}, #{minLeaseTerm}, #{maxLeaseTerm}, #{shipAddress},
#{returnAddress}, #{logisticsCompany}, #{modeOfDelivery}, #{userAccountId}, #{districtCode}, #{sort}) #{returnAddress}, #{logisticsCompany}, #{modeOfDelivery}, #{userAccountId}, #{districtCode},
#{showPrice}, #{sort})
</insert> </insert>
<insert id="batchInsertLeaseGoodsResources"> <insert id="batchInsertLeaseGoodsResources">
insert into lease_goods_resources (lease_goods_id, insert into lease_goods_resources (lease_goods_id,
...@@ -235,6 +237,7 @@ ...@@ -235,6 +237,7 @@
mode_of_delivery, mode_of_delivery,
user_account_id, user_account_id,
create_time, create_time,
show_price,
sort sort
from lease_goods from lease_goods
where id = #{id} where id = #{id}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论