master:销售/出库 优化;
parent
0994390826
commit
d58cc0d78f
|
|
@ -18,6 +18,8 @@ public class StoreSaleSnResVO {
|
|||
|
||||
@ApiModelProperty(value = "是否成功")
|
||||
private Boolean success;
|
||||
@ApiModelProperty(value = "销售:当前选择的客户名;退货:上一次销售的客户名")
|
||||
private String storeCusName;
|
||||
@ApiModelProperty(value = "档口商品ID")
|
||||
private Long storeProdId;
|
||||
@ApiModelProperty(value = "档口商品颜色尺码ID")
|
||||
|
|
@ -38,11 +40,11 @@ public class StoreSaleSnResVO {
|
|||
private Integer standard;
|
||||
@ApiModelProperty(value = "[退货扫码时才有]销售时间")
|
||||
private String soldTime;
|
||||
@ApiModelProperty(value = "[退货扫码时才有]优惠后销售单价")
|
||||
@ApiModelProperty(value = "优惠后销售单价")
|
||||
private BigDecimal discountedPrice;
|
||||
@ApiModelProperty(value = "[退货扫码时才有]销售金额")
|
||||
@ApiModelProperty(value = "销售金额")
|
||||
private BigDecimal amount;
|
||||
@ApiModelProperty(value = "[退货扫码时才有]销售数量")
|
||||
@ApiModelProperty(value = "销售数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,8 +13,7 @@ import javax.validation.constraints.NotNull;
|
|||
* @date 2025/3/27 15:12
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "档口销售条码查询model")
|
||||
|
||||
@ApiModel
|
||||
public class StoreSaleSnVO {
|
||||
|
||||
@NotNull(message = "档口ID不能为空!")
|
||||
|
|
@ -23,6 +22,8 @@ public class StoreSaleSnVO {
|
|||
@NotNull(message = "档口客户ID不能为空!")
|
||||
@ApiModelProperty(value = "档口客户ID", required = true)
|
||||
private Long storeCusId;
|
||||
@ApiModelProperty(value = "档口客户名称", required = true)
|
||||
private String storeCusName;
|
||||
@NotNull(message = "是否退货不能为空!")
|
||||
@ApiModelProperty(value = "是否退货", required = true)
|
||||
private Boolean refund;
|
||||
|
|
|
|||
|
|
@ -3,6 +3,8 @@ package com.ruoyi.xkt.dto.storeProdColorSize;
|
|||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
|
||||
/**
|
||||
* @author liujiang
|
||||
* @version v1.0
|
||||
|
|
@ -16,6 +18,8 @@ public class StoreSaleSnDTO {
|
|||
private Long storeId;
|
||||
@ApiModelProperty(value = "档口客户ID")
|
||||
private Long storeCusId;
|
||||
@ApiModelProperty(value = "档口客户名称")
|
||||
private String storeCusName;
|
||||
@ApiModelProperty(value = "是否退货")
|
||||
private Boolean refund;
|
||||
@ApiModelProperty(value = "条码")
|
||||
|
|
|
|||
|
|
@ -21,6 +21,8 @@ public class StoreSaleSnResDTO {
|
|||
private Long storeProdId;
|
||||
@ApiModelProperty(value = "档口商品颜色尺码ID")
|
||||
private Long storeProdColorId;
|
||||
@ApiModelProperty(value = "销售:当前选择的客户名;退货:上一次销售的客户名")
|
||||
private String storeCusName;
|
||||
@ApiModelProperty(value = "颜色")
|
||||
private String colorName;
|
||||
@ApiModelProperty(value = "尺码")
|
||||
|
|
|
|||
|
|
@ -526,7 +526,7 @@ public class StoreProductColorSizeServiceImpl implements IStoreProductColorSizeS
|
|||
.subtract(ObjectUtils.defaultIfNull(barcodeResDTO.getDiscount(), BigDecimal.ZERO));
|
||||
// 销售则数量为1 退货则数量为-1
|
||||
final BigDecimal quantity = snDTO.getRefund() ? BigDecimal.ONE.negate() : BigDecimal.ONE;
|
||||
return barcodeResDTO.setSuccess(Boolean.TRUE).setSn(snDTO.getSn()).setDiscountedPrice(discountedPrice)
|
||||
return barcodeResDTO.setSuccess(Boolean.TRUE).setSn(snDTO.getSn()).setStoreCusName(snDTO.getStoreCusName()).setDiscountedPrice(discountedPrice)
|
||||
.setQuantity(quantity).setAmount(discountedPrice.multiply(barcodeResDTO.getQuantity()));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
SELECT
|
||||
ssd.store_prod_id,
|
||||
ssd.store_prod_color_id,
|
||||
ssd.store_cus_name,
|
||||
ssd.color_name,
|
||||
ssd.size,
|
||||
ssd.prod_art_num,
|
||||
|
|
@ -27,7 +28,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
AND ssd.sale_type = 1
|
||||
AND ssd.sn = #{sn}
|
||||
AND ssd.store_id = #{storeId}
|
||||
AND ssd.store_cus_id = #{storeCusId}
|
||||
ORDER BY
|
||||
ssd.update_time DESC
|
||||
LIMIT 1
|
||||
|
|
@ -37,6 +37,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
SELECT
|
||||
ssd.store_prod_id,
|
||||
ssd.store_prod_color_id,
|
||||
ssd.store_cus_name,
|
||||
ssd.color_name,
|
||||
ssd.size,
|
||||
ssd.prod_art_num,
|
||||
|
|
@ -56,7 +57,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
AND ssd.sale_type = 1
|
||||
AND ssd.sn = #{sn}
|
||||
AND ssd.store_id = #{storeId}
|
||||
AND ssd.store_cus_id = #{storeCusId}
|
||||
ORDER BY
|
||||
ssd.update_time DESC
|
||||
LIMIT 1
|
||||
|
|
|
|||
Loading…
Reference in New Issue