时间格式化加上timezone=GMT+8,修复首页redis缓存导致销量不一致的问题
This commit is contained in:
@ -59,7 +59,7 @@ public class ApiResult<T> implements Serializable {
|
||||
* 响应时间
|
||||
*/
|
||||
@JSONField(format = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date time;
|
||||
|
||||
public ApiResult() {
|
||||
|
@ -23,11 +23,11 @@ public class BaseDomain implements Serializable {
|
||||
|
||||
|
||||
@TableField(fill= FieldFill.INSERT)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
@TableField(fill= FieldFill.UPDATE)
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date updateTime;
|
||||
|
||||
@TableLogic
|
||||
|
@ -67,7 +67,7 @@ public class YxStoreCombinationDto implements Serializable {
|
||||
private Integer stock;
|
||||
|
||||
// 添加时间
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
// 推荐
|
||||
|
@ -52,7 +52,7 @@ public class YxStoreCouponDto implements Serializable {
|
||||
private List<YxStoreProduct> product;
|
||||
|
||||
// 兑换项目添加时间
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
|
||||
|
@ -48,7 +48,7 @@ public class YxStoreCouponIssueDto implements Serializable {
|
||||
|
||||
|
||||
/** 优惠券添加时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
}
|
||||
|
@ -32,7 +32,7 @@ public class StoreCouponUserVo implements Serializable
|
||||
private Double useMinPrice;
|
||||
|
||||
/** 优惠券结束时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
|
||||
private Date endTime;
|
||||
|
||||
private Integer type;
|
||||
|
@ -31,11 +31,11 @@ public class YxStoreCouponIssueQueryVo implements Serializable {
|
||||
private Integer ctype;
|
||||
|
||||
@ApiModelProperty(value = "优惠券领取开启时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
|
||||
private Date startTime;
|
||||
|
||||
@ApiModelProperty(value = "优惠券领取结束时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
|
||||
private Date endTime;
|
||||
|
||||
@ApiModelProperty(value = "优惠券领取数量")
|
||||
|
@ -40,11 +40,11 @@ public class YxStoreCouponUserQueryVo implements Serializable {
|
||||
@ApiModelProperty(value = "最低消费多少金额可用优惠券")
|
||||
private BigDecimal useMinPrice;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
@ApiModelProperty(value = "优惠券结束时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
|
||||
private Date endTime;
|
||||
|
||||
@ApiModelProperty(value = "使用时间")
|
||||
|
@ -413,6 +413,7 @@ public class YxStoreOrderServiceImpl extends BaseServiceImpl<StoreOrderMapper, Y
|
||||
* @return YxStoreOrder
|
||||
*/
|
||||
@Override
|
||||
@CacheEvict(cacheNames = ShopConstants.YSHOP_REDIS_INDEX_KEY,allEntries = true)
|
||||
public YxStoreOrder createOrder(YxUser userInfo, String key, OrderParam param) {
|
||||
|
||||
ComputeVo computeVo = this.computedOrder(userInfo,key,param.getCouponId(),
|
||||
|
@ -92,7 +92,7 @@ public class YxStoreOrderQueryVo implements Serializable {
|
||||
private String payType;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
@ApiModelProperty(value = "订单状态(-1 : 申请退款 -2 : 退货成功 0:待发货;1:待收货;2:已收货;3:待评价;-1:已退款)")
|
||||
|
@ -64,7 +64,7 @@ public class YxStoreProductReplyQueryVo implements Serializable {
|
||||
@ApiModelProperty(value = "管理员回复时间")
|
||||
private Date merchantReplyTime;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
private String star;
|
||||
|
@ -50,7 +50,7 @@ public class YxUserBillDto implements Serializable {
|
||||
private String mark;
|
||||
|
||||
/** 添加时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
/** 0 = 带确定 1 = 有效 -1 = 无效 */
|
||||
|
@ -57,7 +57,7 @@ public class YxUserDto implements Serializable {
|
||||
private String phone;
|
||||
|
||||
/** 添加时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
/** 添加ip */
|
||||
|
@ -41,7 +41,7 @@ public class YxUserBillQueryVo implements Serializable {
|
||||
private String mark;
|
||||
|
||||
@ApiModelProperty(value = "添加时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
|
||||
|
@ -57,7 +57,7 @@ public class YxArticleDto implements Serializable {
|
||||
private Integer status;
|
||||
|
||||
/** 添加时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
|
||||
private Date createTime;
|
||||
|
||||
/** 是否隐藏 */
|
||||
|
Reference in New Issue
Block a user