mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-07-24 16:05:08 +08:00
订单中心+营销活动:完善部分 TODO 提到的问题
This commit is contained in:
@ -2,7 +2,6 @@ package cn.iocoder.yudao.module.promotion.api.bargain.dto;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
// TODO @芋艿:这块要在看看
|
||||
@ -40,17 +39,7 @@ public class BargainRecordCreateReqDTO {
|
||||
*/
|
||||
@NotNull(message = "订单编号不能为空")
|
||||
private Long orderId;
|
||||
// TODO @puhui999:spuName、picUrl、 之类字段不用传递;
|
||||
/**
|
||||
* 商品名字
|
||||
*/
|
||||
@NotEmpty(message = "商品名字不能为空")
|
||||
private String spuName;
|
||||
/**
|
||||
* 商品图片
|
||||
*/
|
||||
@NotEmpty(message = "商品图片不能为空")
|
||||
private String picUrl;
|
||||
|
||||
/**
|
||||
* 砍价商品单价
|
||||
*/
|
||||
@ -61,17 +50,7 @@ public class BargainRecordCreateReqDTO {
|
||||
*/
|
||||
@NotNull(message = "商品原价不能为空")
|
||||
private Integer price;
|
||||
// TODO @puhui999:nickname、avatar 不用传递,去查询;
|
||||
/**
|
||||
* 用户昵称
|
||||
*/
|
||||
@NotEmpty(message = "用户昵称不能为空")
|
||||
private String nickname;
|
||||
/**
|
||||
* 用户头像
|
||||
*/
|
||||
@NotEmpty(message = "用户头像不能为空")
|
||||
private String avatar;
|
||||
|
||||
/**
|
||||
* 开团状态:进行中 砍价成功 砍价失败
|
||||
*/
|
||||
|
@ -2,9 +2,9 @@ package cn.iocoder.yudao.module.promotion.api.combination;
|
||||
|
||||
import cn.iocoder.yudao.module.promotion.api.combination.dto.CombinationRecordCreateReqDTO;
|
||||
import cn.iocoder.yudao.module.promotion.api.combination.dto.CombinationRecordRespDTO;
|
||||
import cn.iocoder.yudao.module.promotion.api.combination.dto.CombinationRecordUpdateStatusReqDTO;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
// TODO @芋艿:后面也再撸撸这几个接口
|
||||
@ -51,13 +51,29 @@ public interface CombinationRecordApi {
|
||||
*/
|
||||
void validateCombinationLimitCount(Long activityId, Integer count, Integer sumCount);
|
||||
|
||||
// TODO @puhui999:是不是搞成具体的方法,拼团成功,拼团失败,这种方法;
|
||||
/**
|
||||
* 更新拼团状态为 成功
|
||||
*
|
||||
* @param userId 用户编号
|
||||
* @param orderId 订单编号
|
||||
*/
|
||||
void updateRecordStatusToSuccess(Long userId, Long orderId);
|
||||
|
||||
/**
|
||||
* 更新开团记录状态
|
||||
* 更新拼团状态为 失败
|
||||
*
|
||||
* @param reqDTO 请求 DTO
|
||||
* @param userId 用户编号
|
||||
* @param orderId 订单编号
|
||||
*/
|
||||
void updateCombinationRecordStatus(CombinationRecordUpdateStatusReqDTO reqDTO);
|
||||
void updateRecordStatusToFailed(Long userId, Long orderId);
|
||||
|
||||
/**
|
||||
* 更新拼团状态为 进行中
|
||||
*
|
||||
* @param userId 用户编号
|
||||
* @param orderId 订单编号
|
||||
* @param startTime 开始时间
|
||||
*/
|
||||
void updateRecordStatusToInProgress(Long userId, Long orderId, LocalDateTime startTime);
|
||||
|
||||
}
|
||||
|
@ -1,39 +0,0 @@
|
||||
package cn.iocoder.yudao.module.promotion.api.combination.dto;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* 拼团记录的更新状态 Request DTO
|
||||
*
|
||||
* @author HUIHUI
|
||||
*/
|
||||
@Data
|
||||
public class CombinationRecordUpdateStatusReqDTO {
|
||||
|
||||
/**
|
||||
* 用户编号
|
||||
*/
|
||||
@NotNull(message = "用户编号不能为空")
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 订单编号
|
||||
*/
|
||||
@NotNull(message = "订单编号不能为空")
|
||||
private Long orderId;
|
||||
|
||||
/**
|
||||
* 开团状态:正在开团 拼团成功 拼团失败
|
||||
*/
|
||||
@NotNull(message = "开团状态不能为空")
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* 团开始时间
|
||||
*/
|
||||
private LocalDateTime startTime;
|
||||
|
||||
}
|
@ -51,7 +51,7 @@ public interface ErrorCodeConstants {
|
||||
|
||||
// ========== 秒杀活动 1013008000 ==========
|
||||
ErrorCode SECKILL_ACTIVITY_NOT_EXISTS = new ErrorCode(1013008000, "秒杀活动不存在");
|
||||
ErrorCode SECKILL_ACTIVITY_SPU_CONFLICTS = new ErrorCode(1013008002, "存在商品参加了其它秒杀活动");
|
||||
ErrorCode SECKILL_ACTIVITY_SPU_CONFLICTS = new ErrorCode(1013008002, "存在商品参加了其它秒杀活动,秒杀时段冲突");
|
||||
ErrorCode SECKILL_ACTIVITY_UPDATE_FAIL_STATUS_CLOSED = new ErrorCode(1013008003, "秒杀活动已关闭,不能修改");
|
||||
ErrorCode SECKILL_ACTIVITY_DELETE_FAIL_STATUS_NOT_CLOSED_OR_END = new ErrorCode(1013008004, "秒杀活动未关闭或未结束,不能删除");
|
||||
ErrorCode SECKILL_ACTIVITY_CLOSE_FAIL_STATUS_CLOSED = new ErrorCode(1013008005, "秒杀活动已关闭,不能重复关闭");
|
||||
|
Reference in New Issue
Block a user