记得上下班打卡 | git大法好,push需谨慎

Commit 208328ca authored by 张禹's avatar 张禹

Merge branch 'pre' into 'master'

Pre

See merge request !282
parents 772fec1f 3ae53b3b
package com.liquidnet.service.dragon.constant;
/**
* 扫码错误码(暂时用不上、。)
*/
public enum DragonMicropayWepayCodeEnum {
SYSTEMERROR("SYSTEMERROR","接口返回错误(系统超时)"),
PARAM_ERROR("PARAM_ERROR","参数错误"),
ORDERPAID("ORDERPAID","订单已支付(订单号重复)"),
NOAUTH("NOAUTH","商户无权限"),
AUTHCODEEXPIRE("AUTHCODEEXPIRE","二维码已过期,请用户在微信上刷新后再试"),
NOTENOUGH("NOTENOUGH","余额不足"),
NOTSUPORTCARD("NOTSUPORTCARD","不支持卡类型"),
ORDERCLOSED("ORDERCLOSED","订单已关闭"),
ORDERREVERSED("ORDERREVERSED","当前订单已经被撤销"),
BANKERROR("BANKERROR","银行端超时"),
USERPAYING("USERPAYING","用户支付中,需要输入密码"),
AUTH_CODE_ERROR("AUTH_CODE_ERROR","付款码参数错误"),
AUTH_CODE_INVALID("AUTH_CODE_INVALID","扫描的不是微信支付的条码"),
XML_FORMAT_ERROR("XML_FORMAT_ERROR","XML格式错误"),
REQUIRE_POST_METHOD("REQUIRE_POST_METHOD","请使用post方法"),
SIGNERROR("SIGNERROR","参数签名结果不正确"),
LACK_PARAMS("LACK_PARAMS","缺少必要的请求参数"),
NOT_UTF8("NOT_UTF8","未使用指定编码格式"),
BUYER_MISMATCH("BUYER_MISMATCH","支付账号错误"),
APPID_NOT_EXIST("APPID_NOT_EXIST","参数中缺少APPID"),
MCHID_NOT_EXIST("MCHID_NOT_EXIST","参数中缺少MCHID"),
OUT_TRADE_NO_USED("OUT_TRADE_NO_USED","同一笔交易不能多次提交"),
APPID_MCHID_NOT_MATCH("APPID_MCHID_NOT_MATCH","appid和mch_id不匹配"),
INVALID_REQUEST("无效请求","商户系统异常导致,商户权限异常、重复请求支付、证书错误、频率限制等"),
TRADE_ERROR("TRADE_ERROR","交易错误");
private String code;
private String message;
DragonMicropayWepayCodeEnum(String code, String message) {
this.code = code;
this.message = message;
}
public String getCode() {
return code;
}
public static String getValue(String code) {
DragonMicropayWepayCodeEnum[] carTypeEnums = values();
for (DragonMicropayWepayCodeEnum carTypeEnum : carTypeEnums) {
if (carTypeEnum.code.equals(code)) {
return carTypeEnum.getMessage();
}
}
return "未知错误";
}
public String getMessage() {
return message;
}
}
...@@ -40,6 +40,9 @@ public class DragonPayBaseRespDto implements Serializable { ...@@ -40,6 +40,9 @@ public class DragonPayBaseRespDto implements Serializable {
private String productId; private String productId;
//为了应对扫码支付错误码信息
private String msg;
@Data @Data
@JsonInclude(JsonInclude.Include.NON_NULL) @JsonInclude(JsonInclude.Include.NON_NULL)
......
...@@ -110,7 +110,7 @@ public class GoblinStoreMgtDigitalGoodsAddSkuParam implements Serializable { ...@@ -110,7 +110,7 @@ public class GoblinStoreMgtDigitalGoodsAddSkuParam implements Serializable {
private String intro; private String intro;
@ApiModelProperty(position = 30, required = true, value = "详情[256]", example = "详情...") @ApiModelProperty(position = 30, required = true, value = "详情[256]", example = "详情...")
@NotBlank(message = "藏品详情不能为空") @NotBlank(message = "藏品详情不能为空")
@Size(max = 2000, message = "藏品详情内容过长") @Size(max = 10000, message = "藏品详情内容过长")
private String details; private String details;
// @ApiModelProperty(position = 31, required = true, value = "上架处理方式[1-等待手动上架|2-直接上架售卖|3-预约定时上架]", example = "1") // @ApiModelProperty(position = 31, required = true, value = "上架处理方式[1-等待手动上架|2-直接上架售卖|3-预约定时上架]", example = "1")
......
...@@ -102,7 +102,7 @@ public class GoblinStoreMgtGoodsAddParam implements Serializable { ...@@ -102,7 +102,7 @@ public class GoblinStoreMgtGoodsAddParam implements Serializable {
**/ **/
@ApiModelProperty(position = 27, required = true, value = "商品详情", example = "商品详情...") @ApiModelProperty(position = 27, required = true, value = "商品详情", example = "商品详情...")
@Size(max = 5000, message = "商品详情内容过长") @Size(max = 10000, message = "商品详情内容过长")
private String details; private String details;
/** /**
......
package com.liquidnet.service.goblin.dto.vo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.List;
@Api
@Data
public class CouponCountVo implements Serializable, Cloneable {
@ApiModelProperty(dataType = "String", name = "storeCouponIds", value = "券ID",example = "1",required = true)
@NotNull @NotBlank
private String storeCouponId;
@ApiModelProperty(dataType = "Integer", name = "count", value = "领取数量",example = "10",required = true)
@NotNull @NotBlank
private Integer count;
private static final CouponCountVo obj = new CouponCountVo();
public static CouponCountVo getNew() {
try {
return (CouponCountVo) obj.clone();
} catch (CloneNotSupportedException e) {
e.printStackTrace();
}
return new CouponCountVo();
}
}
...@@ -43,6 +43,8 @@ public class GoblinGoodsSkuInfoDetailVo implements Serializable, Cloneable { ...@@ -43,6 +43,8 @@ public class GoblinGoodsSkuInfoDetailVo implements Serializable, Cloneable {
@ApiModelProperty(position = 26, value = "限量[0-无限制|X:限购数量]") @ApiModelProperty(position = 26, value = "限量[0-无限制|X:限购数量]")
private Integer buyLimit; private Integer buyLimit;
@ApiModelProperty(position = 27, value = "剩余库存")
private Integer restStock;
private static final GoblinGoodsSkuInfoDetailVo obj = new GoblinGoodsSkuInfoDetailVo(); private static final GoblinGoodsSkuInfoDetailVo obj = new GoblinGoodsSkuInfoDetailVo();
......
...@@ -62,7 +62,12 @@ public class GoblinOrderSkuVo implements Serializable, Cloneable { ...@@ -62,7 +62,12 @@ public class GoblinOrderSkuVo implements Serializable, Cloneable {
private BigDecimal priceVoucher; private BigDecimal priceVoucher;
@ApiModelProperty(value = "创建时间") @ApiModelProperty(value = "创建时间")
private String createdAt; private String createdAt;
@ApiModelProperty(value = "核销时间")
private String pushTime;
public String getPushTime() {
return pushTime==null?"":pushTime;
}
public GoblinOrderSkuVo copy(GoblinOrderSku source) { public GoblinOrderSkuVo copy(GoblinOrderSku source) {
if (null == source) return this; if (null == source) return this;
......
...@@ -18,6 +18,11 @@ public class GoblinPayInnerResultVo implements Serializable, Cloneable { ...@@ -18,6 +18,11 @@ public class GoblinPayInnerResultVo implements Serializable, Cloneable {
private String returnUrl; private String returnUrl;
private BigDecimal price; private BigDecimal price;
private Object payData; private Object payData;
private String msg;
public String getMsg() {
return msg == null ? "" : msg;
}
private static final GoblinPayInnerResultVo obj = new GoblinPayInnerResultVo(); private static final GoblinPayInnerResultVo obj = new GoblinPayInnerResultVo();
......
...@@ -14,6 +14,7 @@ public class GoblinPosGoodsVo implements Serializable, Cloneable { ...@@ -14,6 +14,7 @@ public class GoblinPosGoodsVo implements Serializable, Cloneable {
private BigDecimal price; private BigDecimal price;
private String spuId; private String spuId;
private String spuName; private String spuName;
private Integer restStock;
private static final GoblinPosGoodsVo obj = new GoblinPosGoodsVo(); private static final GoblinPosGoodsVo obj = new GoblinPosGoodsVo();
......
...@@ -125,6 +125,12 @@ public class GoblinStoreOrderVo implements Serializable, Cloneable { ...@@ -125,6 +125,12 @@ public class GoblinStoreOrderVo implements Serializable, Cloneable {
private String mixId; private String mixId;
@ApiModelProperty(value = "混合售名称") @ApiModelProperty(value = "混合售名称")
private String mixName; private String mixName;
@ApiModelProperty(value = "核销时间")
private String pushTime;
public String getPushTime() {
return pushTime==null?"":pushTime;
}
public BigDecimal getPriceModify() { public BigDecimal getPriceModify() {
if (priceModify == null) { if (priceModify == null) {
......
...@@ -22,6 +22,8 @@ public class TempCouponVo implements Cloneable{ ...@@ -22,6 +22,8 @@ public class TempCouponVo implements Cloneable{
private String storeCouponId; private String storeCouponId;
@ApiModelProperty(position = 7, value = "是否默认用券") @ApiModelProperty(position = 7, value = "是否默认用券")
private int isDefault; private int isDefault;
@ApiModelProperty(position = 8, value = "券vo")
private GoblinStoreCouponVo vo;
private static final TempCouponVo obj = new TempCouponVo(); private static final TempCouponVo obj = new TempCouponVo();
......
package com.liquidnet.service.goblin.param;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.List;
@Api
@Data
public class CouponCountParam implements Serializable, Cloneable {
@ApiModelProperty(dataType = "String", name = "storeCouponIds", value = "券ID数组",example = "1",required = true)
@NotNull @NotBlank
private List<String> storeCouponIds;
@ApiModelProperty(dataType = "String", name = "uid", value = "用户id",example = "10",required = true)
@NotNull @NotBlank
private String uid;
private static final CouponCountParam obj = new CouponCountParam();
public static CouponCountParam getNew() {
try {
return (CouponCountParam) obj.clone();
} catch (CloneNotSupportedException e) {
e.printStackTrace();
}
return new CouponCountParam();
}
}
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
<label class="col-sm-3 control-label is-required">头像:</label> <label class="col-sm-3 control-label is-required">头像:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<!-- <input name="img" class="form-control" type="text" th:value="*{img}" readonly required>--> <!-- <input name="img" class="form-control" type="text" th:value="*{img}" readonly required>-->
<img class="img-details" style="height: 400px;" name="img" th:src="*{img}" <img class="img-details" style="height: 400px;" name="img" th:src="*{img+'?x-oss-process=image/resize,s_400'}"
th:onclick="click_big([[*{img}]])"> th:onclick="click_big([[*{img}]])">
</div> </div>
</div> </div>
......
...@@ -70,7 +70,7 @@ ...@@ -70,7 +70,7 @@
选择演出: 选择演出:
</span> </span>
<div class="input-group" style="width: 300px;"> <div class="input-group" style="width: 300px;">
<input type="text" class="form-control" id="selectShow" placeholder=""> <input type="text" class="form-control select-show editDisabled" id="selectShow" placeholder="">
<div class="input-group-btn"> <div class="input-group-btn">
<button type="button" class="btn btn-white dropdown-toggle" data-toggle="dropdown"> <button type="button" class="btn btn-white dropdown-toggle" data-toggle="dropdown">
<span class="caret"></span> <span class="caret"></span>
...@@ -78,7 +78,7 @@ ...@@ -78,7 +78,7 @@
<ul class="dropdown-menu dropdown-menu-right" role="menu"> <ul class="dropdown-menu dropdown-menu-right" role="menu">
</ul> </ul>
</div> </div>
<!-- /btn-group --> <!-- /btn-group 11 -->
</div> </div>
</div> </div>
<div class="basis_data"> <div class="basis_data">
...@@ -86,13 +86,13 @@ ...@@ -86,13 +86,13 @@
<em class="required">*</em> <em class="required">*</em>
有效期: 有效期:
</span> </span>
<input type="text" class="layui-input form-control" id="startTime" autocomplete="off" placeholder="请选择活动开始时间"> <input type="text" class="layui-input form-control editDisabled" id="startTime" autocomplete="off" placeholder="请选择活动开始时间">
~ ~
<input type="text" class="layui-input form-control" id="endTime" style="margin-left: 10px;" autocomplete="off" placeholder="请选择活动结束时间"> <input type="text" class="layui-input form-control editDisabled" id="endTime" style="margin-left: 10px;" autocomplete="off" placeholder="请选择活动结束时间">
</div>
<div class="first_footer" style="padding-left: 60px;margin-top: 12px;">
<button class="btn btn-primary" onclick="nextBtn()">确定</button>
</div> </div>
<div class="first_footer editshow" style="padding-left: 60px;margin-top: 12px;">
<button class="btn btn-primary" onclick="nextBtn()">确定</button>
</div>
</div> </div>
<div class="content_item" style="display: none;"> <div class="content_item" style="display: none;">
<div class="content_title"> <div class="content_title">
...@@ -153,6 +153,8 @@ ...@@ -153,6 +153,8 @@
common (); common ();
if (r) { if (r) {
marketId = unescape(r[2]); marketId = unescape(r[2]);
$(".editDisabled").attr('disabled', true);
$(".editshow").hide()
let data = { let data = {
marketId marketId
} }
...@@ -173,6 +175,8 @@ ...@@ -173,6 +175,8 @@
}) })
}) })
} }
}) })
function common () { function common () {
$("#selectShow").bsSuggest({ $("#selectShow").bsSuggest({
...@@ -219,13 +223,13 @@ ...@@ -219,13 +223,13 @@
if (item) { if (item) {
body+=`<div class="activityStore_item" data-newTag=""> body+=`<div class="activityStore_item" data-newTag="">
<div class="input-group" style="margin-right: 12px;"> <div class="input-group" style="margin-right: 12px;">
<input type="text" class="form-control storeList item${count}" data-id="${item.storeId}" value="${item.storeName}" placeholder="搜索店铺名称"> <input type="text" class="form-control storeList item${count} itemDisabled" data-id="${item.storeId}" value="${item.storeName}" placeholder="搜索店铺名称">
<div class="input-group-btn"> <div class="input-group-btn">
<ul class="dropdown-menu dropdown-menu-right" role="menu"> <ul class="dropdown-menu dropdown-menu-right" role="menu">
</ul> </ul>
</div> </div>
</div> </div>
<input type="text" class="layui-input form-control timeSp startTime${count}" id="startTime" value="${item.showTime}" autocomplete="off" placeholder="配置活动时间"> <input type="text" class="layui-input form-control timeSp startTime${count} itemDisabled" id="startTime" value="${item.showTime}" autocomplete="off" placeholder="配置活动时间">
</div>` </div>`
} else { } else {
body+=`<div class="activityStore_item" data-newTag="1"> body+=`<div class="activityStore_item" data-newTag="1">
...@@ -239,9 +243,9 @@ ...@@ -239,9 +243,9 @@
<input type="text" class="layui-input form-control timeSp startTime${count}" id="startTime" autocomplete="off" placeholder="配置活动时间"> <input type="text" class="layui-input form-control timeSp startTime${count}" id="startTime" autocomplete="off" placeholder="配置活动时间">
</div>` </div>`
} }
$(".activityStore").append(body) $(".activityStore").append(body)
common () common ()
$(".itemDisabled").attr('disabled', true);
layui.use('laydate', function(){ layui.use('laydate', function(){
var laydate = layui.laydate; var laydate = layui.laydate;
//执行一个laydate实例 //执行一个laydate实例
......
...@@ -53,7 +53,7 @@ public class GoblinZhengzaiMarketServiceImpl implements IGoblinZhengzaiMarketSer ...@@ -53,7 +53,7 @@ public class GoblinZhengzaiMarketServiceImpl implements IGoblinZhengzaiMarketSer
GoblinMarketingZhengzaiRelationMapper goblinMarketingZhengzaiRelationMapper; GoblinMarketingZhengzaiRelationMapper goblinMarketingZhengzaiRelationMapper;
@Override @Override
public ResponseDto<List<GoblinSelfMarketingDto>> zhengzaiList(int page,int size, String purchaseName, int status, String st, String et, String ct) { public ResponseDto<List<GoblinSelfMarketingDto>> zhengzaiList(int page, int size, String purchaseName, int status, String st, String et, String ct) {
// LambdaUpdateWrapper<GoblinSelfMarketing> queryMapper = Wrappers.lambdaUpdate(GoblinSelfMarketing.getNew()).eq(GoblinSelfMarketing::getDelFlag, 0); // LambdaUpdateWrapper<GoblinSelfMarketing> queryMapper = Wrappers.lambdaUpdate(GoblinSelfMarketing.getNew()).eq(GoblinSelfMarketing::getDelFlag, 0);
// switch (status) { // switch (status) {
// case 0://未开始 // case 0://未开始
......
...@@ -129,6 +129,8 @@ public class GoblinOrderSku implements Serializable,Cloneable { ...@@ -129,6 +129,8 @@ public class GoblinOrderSku implements Serializable,Cloneable {
private LocalDateTime updatedAt; private LocalDateTime updatedAt;
private LocalDateTime pushTime;
private String comment; private String comment;
private static final GoblinOrderSku obj = new GoblinOrderSku(); private static final GoblinOrderSku obj = new GoblinOrderSku();
......
...@@ -324,6 +324,8 @@ public class GoblinStoreOrder implements Serializable,Cloneable { ...@@ -324,6 +324,8 @@ public class GoblinStoreOrder implements Serializable,Cloneable {
private LocalDateTime updatedAt; private LocalDateTime updatedAt;
private LocalDateTime pushTime;
private String comment; private String comment;
private static final GoblinStoreOrder obj = new GoblinStoreOrder(); private static final GoblinStoreOrder obj = new GoblinStoreOrder();
......
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
<select id="getZhengzaiStoreList" resultMap="goblinZhengzaiStoreListDtoResult"> <select id="getZhengzaiStoreList" resultMap="goblinZhengzaiStoreListDtoResult">
select d.store_id, select b.store_id,
c.store_name, c.store_name,
b.show_time, b.show_time,
IFNull(count(distinct d.spu_id), 0) as 'spu_count', IFNull(count(distinct d.spu_id), 0) as 'spu_count',
...@@ -51,7 +51,7 @@ from goblin_self_marketing as a ...@@ -51,7 +51,7 @@ from goblin_self_marketing as a
inner join goblin_store_info as c on c.store_id = b.store_id inner join goblin_store_info as c on c.store_id = b.store_id
left join goblin_marketing_zhengzai as d on d.store_id = b.store_id and d.self_market_id = b.self_market_id left join goblin_marketing_zhengzai as d on d.store_id = b.store_id and d.self_market_id = b.self_market_id
where a.self_market_id = #{marketId} where a.self_market_id = #{marketId}
GROUP BY d.store_id GROUP BY b.store_id
</select> </select>
<select id="getZhengzaiStoreDetails" resultMap="goblinZhengzaiStoreDetailsDtoResult"> <select id="getZhengzaiStoreDetails" resultMap="goblinZhengzaiStoreDetailsDtoResult">
......
...@@ -56,6 +56,10 @@ public class AlipayStrategyMicropayImpl extends AbstractAlipayStrategy { ...@@ -56,6 +56,10 @@ public class AlipayStrategyMicropayImpl extends AbstractAlipayStrategy {
@Override @Override
DragonPayBaseRespDto buildResponseDto(DragonPayBaseRespDto payBaseRespDto, Map<String, Object> respResult) { DragonPayBaseRespDto buildResponseDto(DragonPayBaseRespDto payBaseRespDto, Map<String, Object> respResult) {
// payBaseRespDto.getPayData().setRedirectUrl(alipayGatewayUrl + "?" + respResult.get("body")); // payBaseRespDto.getPayData().setRedirectUrl(alipayGatewayUrl + "?" + respResult.get("body"));
//判断是否成功
if(respResult.get("code")!=null&&!respResult.get("code").equals("10000")){
payBaseRespDto.setMsg(respResult.get("subMsg")==null?"":respResult.get("subMsg").toString());
}
return payBaseRespDto; return payBaseRespDto;
} }
} }
...@@ -58,6 +58,10 @@ public class WepayPayRespDto { ...@@ -58,6 +58,10 @@ public class WepayPayRespDto {
private String attach; private String attach;
@XStreamAlias("time_end") @XStreamAlias("time_end")
private String time_end; private String time_end;
@XStreamAlias("err_code")
private String err_code;
@XStreamAlias("err_code_des")
private String err_code_des;
public static void xmlToBean(){ public static void xmlToBean(){
String xmlStr = "<xml><return_code><![CDATA[SUCCESS]]></return_code>\n" + String xmlStr = "<xml><return_code><![CDATA[SUCCESS]]></return_code>\n" +
......
...@@ -101,12 +101,14 @@ public abstract class AbstractWepayStrategy implements IWepayStrategy { ...@@ -101,12 +101,14 @@ public abstract class AbstractWepayStrategy implements IWepayStrategy {
throw new LiquidnetServiceException(DragonErrorCodeEnum.TRADE_PARAM_ERROR.getCode(),DragonErrorCodeEnum.TRADE_PARAM_ERROR.getMessage()); throw new LiquidnetServiceException(DragonErrorCodeEnum.TRADE_PARAM_ERROR.getCode(),DragonErrorCodeEnum.TRADE_PARAM_ERROR.getMessage());
} }
if(WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getReturnCode())){ if(WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getReturnCode())){
if(WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getResultCode())){ if(WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getResultCode())||dragonPayBaseReqDto.getDeviceFrom().equals(DragonConstant.DeviceFromEnum.MICROPAY.getCode())){
//构造公共返回参数 //构造公共返回参数
DragonPayBaseRespDto respPayDto = this.buildCommonRespDto(dragonPayBaseReqDto,respWepayDto); DragonPayBaseRespDto respPayDto = this.buildCommonRespDto(dragonPayBaseReqDto,respWepayDto);
//构造自定义返回参数 //构造自定义返回参数
this.buildResponseDto(respPayDto,respWepayDto); this.buildResponseDto(respPayDto,respWepayDto);
if(!WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getResultCode())&&dragonPayBaseReqDto.getDeviceFrom().equals(DragonConstant.DeviceFromEnum.MICROPAY.getCode())) {
respPayDto.setMsg(respWepayDto.getErr_code_des());
}
//支付订单持久化 //支付订单持久化
dragonServiceCommonBiz.buildPayOrders(dragonPayBaseReqDto,respPayDto); dragonServiceCommonBiz.buildPayOrders(dragonPayBaseReqDto,respPayDto);
log.info("wepay-->dragonPay--> 耗时:{}",(System.currentTimeMillis() - startTimeTotal)+"毫秒"); log.info("wepay-->dragonPay--> 耗时:{}",(System.currentTimeMillis() - startTimeTotal)+"毫秒");
......
...@@ -68,3 +68,13 @@ ALTER TABLE goblin_nft_order ...@@ -68,3 +68,13 @@ ALTER TABLE goblin_nft_order
ADD mix_id VARCHAR(64) NOT NULL DEFAULT '' COMMENT '组合售id'; ADD mix_id VARCHAR(64) NOT NULL DEFAULT '' COMMENT '组合售id';
ALTER TABLE goblin_store_order ALTER TABLE goblin_store_order
ADD mix_id VARCHAR(64) NOT NULL DEFAULT '' COMMENT '组合售id'; ADD mix_id VARCHAR(64) NOT NULL DEFAULT '' COMMENT '组合售id';
-- 2022年07月28日11:00:36 增加 核销时间字段
ALTER TABLE goblin_order_sku
ADD push_time datetime DEFAULT NULL COMMENT '核销时间';
ALTER TABLE goblin_store_order
ADD push_time datetime DEFAULT NULL COMMENT '核销时间';
ALTER TABLE goblin_store_order
ADD mix_code varchar(128) DEFAULT NULL COMMENT '混合售订单号';
ALTER TABLE goblin_nft_order
ADD mix_code varchar(128) DEFAULT NULL COMMENT '混合售订单号';
\ No newline at end of file
...@@ -6,7 +6,9 @@ import com.liquidnet.common.exception.constant.ErrorCode; ...@@ -6,7 +6,9 @@ import com.liquidnet.common.exception.constant.ErrorCode;
import com.liquidnet.commons.lang.util.CurrentUtil; import com.liquidnet.commons.lang.util.CurrentUtil;
import com.liquidnet.service.base.ErrorMapping; import com.liquidnet.service.base.ErrorMapping;
import com.liquidnet.service.base.ResponseDto; import com.liquidnet.service.base.ResponseDto;
import com.liquidnet.service.goblin.constant.GoblinStatusConst;
import com.liquidnet.service.goblin.dto.vo.*; import com.liquidnet.service.goblin.dto.vo.*;
import com.liquidnet.service.goblin.param.CouponCountParam;
import com.liquidnet.service.goblin.service.GoblinCouponService; import com.liquidnet.service.goblin.service.GoblinCouponService;
import com.liquidnet.service.goblin.util.GoblinRedisUtils; import com.liquidnet.service.goblin.util.GoblinRedisUtils;
import com.liquidnet.service.goblin.util.ObjectUtil; import com.liquidnet.service.goblin.util.ObjectUtil;
...@@ -100,11 +102,61 @@ public class GoblinPosController { ...@@ -100,11 +102,61 @@ public class GoblinPosController {
posGoodsVo.setPrice(goodsSkuInfoVo.getPrice()); posGoodsVo.setPrice(goodsSkuInfoVo.getPrice());
posGoodsVo.setSpuId(spuId); posGoodsVo.setSpuId(spuId);
posGoodsVo.setSpuName(goodsInfoVo.getName()); posGoodsVo.setSpuName(goodsInfoVo.getName());
String pre = GoblinStatusConst.MarketPreStatus.getPre(spuId);
posGoodsVoList.add(posGoodsVo); int stock = goblinRedisUtils.getSkuStock(pre, skuId);
posGoodsVo.setRestStock(stock);
if (stock > 0) {
posGoodsVoList.add(posGoodsVo);
}
} }
} }
} }
return ResponseDto.success(posGoodsVoList); return ResponseDto.success(posGoodsVoList);
} }
// @PostMapping("coupon/count")
// @ApiOperation("券领取次数")
// @ResponseBody
// public ResponseDto<List<CouponCountVo>> couponCount(@RequestBody CouponCountParam param) {
// String uid = param.getUid();
// List<String> storeCouponIds = param.getStoreCouponIds();
// List<GoblinUserCouponVo> userCouponVos = goblinRedisUtils.getUserCouponVos(uid);
// List<CouponCountVo> voList = ObjectUtil.couponCountVos();
// for (String storeCouponId : storeCouponIds) {
// if (!CollectionUtils.isEmpty(userCouponVos)) {
// int beforeSize = userCouponVos.size();
// userCouponVos.removeIf(vo -> vo.getStoreCouponId().equals(storeCouponId));
// int receiveCount = (beforeSize - userCouponVos.size());
// CouponCountVo single = CouponCountVo.getNew();
// single.setStoreCouponId(storeCouponId);
// single.setCount(receiveCount);
// voList.add(single);
// }
// }
// return ResponseDto.success(voList);
// }
@PostMapping("coupon/count")
@ApiOperation("券领取次数")
@ApiImplicitParams({
@ApiImplicitParam(type = "form", required = true, dataType = " List<String>", name = "storeCouponId", value = "平台券id"),
@ApiImplicitParam(type = "form", required = true, dataType = "String", name = "uid", value = "UID"),
})
public ResponseDto<List<CouponCountVo>> couponCount(@NotBlank(message = "参数无效:storeCouponId") @RequestParam("storeCouponId") List<String> storeCouponIds,
@NotBlank(message = "参数无效:uid") @RequestParam("uid") String uid) {
List<GoblinUserCouponVo> userCouponVos = goblinRedisUtils.getUserCouponVos(uid);
List<CouponCountVo> voList = ObjectUtil.couponCountVos();
for (String storeCouponId : storeCouponIds) {
if (!CollectionUtils.isEmpty(userCouponVos)) {
int beforeSize = userCouponVos.size();
userCouponVos.removeIf(vo -> vo.getStoreCouponId().equals(storeCouponId));
int receiveCount = (beforeSize - userCouponVos.size());
CouponCountVo single = CouponCountVo.getNew();
single.setStoreCouponId(storeCouponId);
single.setCount(receiveCount);
voList.add(single);
}
}
return ResponseDto.success(voList);
}
} }
...@@ -51,15 +51,15 @@ public class GoblinStoreZhengzaiController { ...@@ -51,15 +51,15 @@ public class GoblinStoreZhengzaiController {
return goblinStoreZhengzaiService.orderList(page); return goblinStoreZhengzaiService.orderList(page);
} }
@PostMapping("orderPush") // @PostMapping("orderPush")
@ApiOperation("正在下单-出货") // @ApiOperation("正在下单-出货")
@ApiResponse(code = 200, message = "接口返回对象参数") // @ApiResponse(code = 200, message = "接口返回对象参数")
@ApiImplicitParams({ // @ApiImplicitParams({
@ApiImplicitParam(type = "form", required = true, dataType = "String", name = "orderMasterCode", value = "主订单号"), // @ApiImplicitParam(type = "form", required = true, dataType = "String", name = "orderMasterCode", value = "主订单号"),
}) // })
public ResponseDto<Boolean> orderPush(@RequestParam("orderMasterCode") @Valid String orderMasterCode) { // public ResponseDto<Boolean> orderPush(@RequestParam("orderMasterCode") @Valid String orderMasterCode) {
return goblinStoreZhengzaiService.orderPush(orderMasterCode); // return goblinStoreZhengzaiService.orderPush(orderMasterCode);
} // }
@PostMapping("listByCode") @PostMapping("listByCode")
@ApiOperation("列表[根据masterCode]") @ApiOperation("列表[根据masterCode]")
......
...@@ -15,6 +15,7 @@ import org.springframework.stereotype.Service; ...@@ -15,6 +15,7 @@ import org.springframework.stereotype.Service;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.time.LocalDateTime; import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.LinkedList; import java.util.LinkedList;
import java.util.List; import java.util.List;
import java.util.stream.Collectors; import java.util.stream.Collectors;
...@@ -91,8 +92,8 @@ public class GoblinAppZhengzaiServiceImpl implements IGoblinAppZhengzaiService { ...@@ -91,8 +92,8 @@ public class GoblinAppZhengzaiServiceImpl implements IGoblinAppZhengzaiService {
LinkedList<String> sqls = CollectionUtil.linkedListString(); LinkedList<String> sqls = CollectionUtil.linkedListString();
LinkedList<Object[]> sqlDataOrder = CollectionUtil.linkedListObjectArr(); LinkedList<Object[]> sqlDataOrder = CollectionUtil.linkedListObjectArr();
LinkedList<Object[]> sqlDataSku = CollectionUtil.linkedListObjectArr(); LinkedList<Object[]> sqlDataSku = CollectionUtil.linkedListObjectArr();
sqls.add(SqlMapping.get("goblin_order.store.orderStatus")); sqls.add(SqlMapping.get("goblin_order.store.orderPush"));
sqls.add(SqlMapping.get("goblin_order.store.orderSkuStatus")); sqls.add(SqlMapping.get("goblin_order.store.orderSkuPush"));
String uid = CurrentUtil.getCurrentUid(); String uid = CurrentUtil.getCurrentUid();
GoblinStoreInfoVo storeInfoVo = redisUtils.getStoreInfoVoByUid(uid); GoblinStoreInfoVo storeInfoVo = redisUtils.getStoreInfoVoByUid(uid);
if (storeInfoVo == null) { if (storeInfoVo == null) {
...@@ -103,7 +104,7 @@ public class GoblinAppZhengzaiServiceImpl implements IGoblinAppZhengzaiService { ...@@ -103,7 +104,7 @@ public class GoblinAppZhengzaiServiceImpl implements IGoblinAppZhengzaiService {
} else { } else {
for (String orderId : orderIds) { for (String orderId : orderIds) {
GoblinStoreOrderVo storeOrderVo = redisUtils.getGoblinOrder(orderId); GoblinStoreOrderVo storeOrderVo = redisUtils.getGoblinOrder(orderId);
if (!storeInfoVo.getStoreId().equals(storeOrderVo.getStoreId())|| !(storeOrderVo.getWriteOffCode().equals(offCode))) { if (!storeInfoVo.getStoreId().equals(storeOrderVo.getStoreId()) || !(storeOrderVo.getWriteOffCode().equals(offCode))) {
continue; continue;
} }
if (storeOrderVo.getStatus().equals(GoblinStatusConst.Status.ORDER_STATUS_0.getValue())) { if (storeOrderVo.getStatus().equals(GoblinStatusConst.Status.ORDER_STATUS_0.getValue())) {
...@@ -117,16 +118,18 @@ public class GoblinAppZhengzaiServiceImpl implements IGoblinAppZhengzaiService { ...@@ -117,16 +118,18 @@ public class GoblinAppZhengzaiServiceImpl implements IGoblinAppZhengzaiService {
} }
storeOrderVo.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue()); storeOrderVo.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue());
storeOrderVo.setZhengzaiStatus(1); storeOrderVo.setZhengzaiStatus(1);
storeOrderVo.setPushTime(now.format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss")));
sqlDataOrder.add(new Object[]{ sqlDataOrder.add(new Object[]{
storeOrderVo.getStatus(),storeOrderVo.getZhengzaiStatus(), now, storeOrderVo.getStatus(), storeOrderVo.getZhengzaiStatus(), now, now,
storeOrderVo.getOrderId(), now, now storeOrderVo.getOrderId(), now, now
}); });
List<String> skuIds = storeOrderVo.getOrderSkuVoIds(); List<String> skuIds = storeOrderVo.getOrderSkuVoIds();
for (String skuId : skuIds) { for (String skuId : skuIds) {
GoblinOrderSkuVo skuInfoVo = redisUtils.getGoblinOrderSkuVo(skuId); GoblinOrderSkuVo skuInfoVo = redisUtils.getGoblinOrderSkuVo(skuId);
skuInfoVo.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue()); skuInfoVo.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue());
skuInfoVo.setPushTime(now.format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss")));
sqlDataSku.add(new Object[]{ sqlDataSku.add(new Object[]{
skuInfoVo.getStatus(), now, skuInfoVo.getStatus(), now, now,
skuInfoVo.getOrderSkuId(), now, now skuInfoVo.getOrderSkuId(), now, now
}); });
redisUtils.setGoblinOrderSku(skuInfoVo.getOrderSkuId(), skuInfoVo); redisUtils.setGoblinOrderSku(skuInfoVo.getOrderSkuId(), skuInfoVo);
...@@ -202,7 +205,7 @@ public class GoblinAppZhengzaiServiceImpl implements IGoblinAppZhengzaiService { ...@@ -202,7 +205,7 @@ public class GoblinAppZhengzaiServiceImpl implements IGoblinAppZhengzaiService {
mongoUtils.updateGoblinStoreOrderVo(storeOrderVo.getOrderId(), storeOrderVo); mongoUtils.updateGoblinStoreOrderVo(storeOrderVo.getOrderId(), storeOrderVo);
//redis //redis
redisUtils.setGoblinOrder(storeOrderVo.getOrderId(), storeOrderVo); redisUtils.setGoblinOrder(storeOrderVo.getOrderId(), storeOrderVo);
redisUtils.addZhengzaiOrderList(uid,orderId); redisUtils.addZhengzaiOrderList(uid, orderId);
//mysql //mysql
queueUtils.sendMsgByRedis(MQConst.GoblinQueue.GOBLIN_STORE_ORDER_OPERA.getKey(), queueUtils.sendMsgByRedis(MQConst.GoblinQueue.GOBLIN_STORE_ORDER_OPERA.getKey(),
SqlMapping.get("goblin_order.zhengzai.bind", SqlMapping.get("goblin_order.zhengzai.bind",
......
...@@ -327,6 +327,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService { ...@@ -327,6 +327,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
} else { } else {
goblinGoodsSkuInfoDetailVo.setStockLess(false); goblinGoodsSkuInfoDetailVo.setStockLess(false);
} }
goblinGoodsSkuInfoDetailVo.setRestStock(stock);
list.add(goblinGoodsSkuInfoDetailVo); list.add(goblinGoodsSkuInfoDetailVo);
} }
} }
...@@ -380,7 +381,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService { ...@@ -380,7 +381,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
} }
goblinFrontCubeVo.setGoblinGoodsInfoVoList(goblinGoodsInfoVoArrayList); goblinFrontCubeVo.setGoblinGoodsInfoVoList(goblinGoodsInfoVoArrayList);
}else{ } else {
return null; return null;
} }
return goblinFrontCubeVo; return goblinFrontCubeVo;
...@@ -465,11 +466,11 @@ public class GoblinFrontServiceImpl implements GoblinFrontService { ...@@ -465,11 +466,11 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
} }
public GoblinGoodsInfoListVoo searchGoodesName(String name,int page,int pageSize) { public GoblinGoodsInfoListVoo searchGoodesName(String name, int page, int pageSize) {
List<String> listStore = mongoUtils.getStoreInfoVoRegexName(name); List<String> listStore = mongoUtils.getStoreInfoVoRegexName(name);
Pattern pattern = Pattern.compile("^.*" + name + ".*$", Pattern.CASE_INSENSITIVE); Pattern pattern = Pattern.compile("^.*" + name + ".*$", Pattern.CASE_INSENSITIVE);
Query query = new Query(); Query query = new Query();
query.addCriteria(Criteria.where("spuAppear").is("0").and("delFlg").is("0").and("shelvesStatus").is("3").and("marketId").is(null).and("cateFid").nin("22196120924543","22196122839313").andOperator( query.addCriteria(Criteria.where("spuAppear").is("0").and("delFlg").is("0").and("shelvesStatus").is("3").and("marketId").is(null).and("cateFid").nin("22196120924543", "22196122839313").andOperator(
new Criteria().orOperator( new Criteria().orOperator(
Criteria.where("name").regex(pattern), Criteria.where("name").regex(pattern),
Criteria.where("storeId").in(listStore), Criteria.where("storeId").in(listStore),
...@@ -484,7 +485,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService { ...@@ -484,7 +485,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
)); ));
List<GoblinGoodsInfoVo> list = mongoTemplate.find(query, GoblinGoodsInfoVo.class, GoblinGoodsInfoVo.class.getSimpleName()); List<GoblinGoodsInfoVo> list = mongoTemplate.find(query, GoblinGoodsInfoVo.class, GoblinGoodsInfoVo.class.getSimpleName());
GoblinGoodsInfoListVoo goblinGoodsInfoListVoo=GoblinGoodsInfoListVoo.getNew(); GoblinGoodsInfoListVoo goblinGoodsInfoListVoo = GoblinGoodsInfoListVoo.getNew();
goblinGoodsInfoListVoo.setCount(count); goblinGoodsInfoListVoo.setCount(count);
ArrayList<GoblinGoodsInfoListVo> list1 = ObjectUtil.getGoblinGoodsInfoListVo(); ArrayList<GoblinGoodsInfoListVo> list1 = ObjectUtil.getGoblinGoodsInfoListVo();
//遍历 //遍历
...@@ -530,7 +531,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService { ...@@ -530,7 +531,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
} }
// //
Query query = new Query(); Query query = new Query();
query.addCriteria(Criteria.where("storeId").is(storeId).and("spuAppear").is("0").and("delFlg").is("0").and("shelvesStatus").is("3").and("marketId").is(null).and("cateFid").nin("22196120924543","22196122839313")); query.addCriteria(Criteria.where("storeId").is(storeId).and("spuAppear").is("0").and("delFlg").is("0").and("shelvesStatus").is("3").and("marketId").is(null).and("cateFid").nin("22196120924543", "22196122839313"));
if (StringUtil.isNotBlank(categoryId)) { if (StringUtil.isNotBlank(categoryId)) {
query.addCriteria(new Criteria().orOperator( query.addCriteria(new Criteria().orOperator(
Criteria.where("storeCateFid").is(categoryId), Criteria.where("storeCateFid").is(categoryId),
...@@ -857,7 +858,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService { ...@@ -857,7 +858,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
for (String id : spuids) { for (String id : spuids) {
GoblinGoodsInfoVo goblinGoodsInfoVo = goblinRedisUtils.getGoodsInfoVo(id); GoblinGoodsInfoVo goblinGoodsInfoVo = goblinRedisUtils.getGoodsInfoVo(id);
if (null != goblinGoodsInfoVo) { if (null != goblinGoodsInfoVo) {
if(isHidden(goblinGoodsInfoVo.getCateFid())){ if (isHidden(goblinGoodsInfoVo.getCateFid())) {
continue; continue;
} }
goblinGoodsInfoVoArrayList.add(goblinGoodsInfoVo); goblinGoodsInfoVoArrayList.add(goblinGoodsInfoVo);
...@@ -912,7 +913,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService { ...@@ -912,7 +913,7 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
for (int i = 0; i < end; i++) { for (int i = 0; i < end; i++) {
if (i >= start) { if (i >= start) {
GoblinGoodsInfoVo goblinGoodsInfoVo = goblinRedisUtils.getGoodsInfoVo(spuidss[i]); GoblinGoodsInfoVo goblinGoodsInfoVo = goblinRedisUtils.getGoodsInfoVo(spuidss[i]);
if(isHidden(goblinGoodsInfoVo.getCateFid())){ if (isHidden(goblinGoodsInfoVo.getCateFid())) {
continue; continue;
} }
goblinGoodsInfoVoArrayList.add(goblinGoodsInfoVo); goblinGoodsInfoVoArrayList.add(goblinGoodsInfoVo);
...@@ -1424,11 +1425,11 @@ public class GoblinFrontServiceImpl implements GoblinFrontService { ...@@ -1424,11 +1425,11 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
} }
private boolean isHidden(String fcateId){ private boolean isHidden(String fcateId) {
ArrayList<String> hiddenIds = CollectionUtil.arrayListString(); ArrayList<String> hiddenIds = CollectionUtil.arrayListString();
hiddenIds.add("22196120924543"); hiddenIds.add("22196120924543");
hiddenIds.add("22196122839313"); hiddenIds.add("22196122839313");
if(hiddenIds.contains(fcateId)){ if (hiddenIds.contains(fcateId)) {
return true; return true;
} }
return false; return false;
......
...@@ -79,6 +79,9 @@ public class GoblinMixAppServiceImpl implements IGoblinMixAppService { ...@@ -79,6 +79,9 @@ public class GoblinMixAppServiceImpl implements IGoblinMixAppService {
@Override @Override
public ResponseDto<GoblinMixAppDetailsVo> mixDetails(String mixId) { public ResponseDto<GoblinMixAppDetailsVo> mixDetails(String mixId) {
GoblinMixDetailsVo baseVo = redisUtils.getMixDetails(mixId); GoblinMixDetailsVo baseVo = redisUtils.getMixDetails(mixId);
if(baseVo==null){
return ResponseDto.failure("参数异常");
}
GoblinStoreInfoVo storeInfoVo = redisUtils.getStoreInfoVo(baseVo.getStoreId()); GoblinStoreInfoVo storeInfoVo = redisUtils.getStoreInfoVo(baseVo.getStoreId());
GoblinMixAppDetailsVo vo = GoblinMixAppDetailsVo.getNew().copy(baseVo, storeInfoVo.getStoreName()); GoblinMixAppDetailsVo vo = GoblinMixAppDetailsVo.getNew().copy(baseVo, storeInfoVo.getStoreName());
int stock = 0; int stock = 0;
......
...@@ -67,6 +67,7 @@ public class GoblinInnerServiceImpl implements IGoblinInnerService { ...@@ -67,6 +67,7 @@ public class GoblinInnerServiceImpl implements IGoblinInnerService {
List<String> ucouponIds = redisUtils.getMarketTempCoupon(performanceId); List<String> ucouponIds = redisUtils.getMarketTempCoupon(performanceId);
for (String ucouponId : ucouponIds) { for (String ucouponId : ucouponIds) {
TempCouponVo tempCouponVo = redisUtils.getTempCoupon(ucouponId); TempCouponVo tempCouponVo = redisUtils.getTempCoupon(ucouponId);
tempCouponVo.setVo(redisUtils.getStoreCouponVo(tempCouponVo.getStoreCouponId()));
tempCouponVos.add(tempCouponVo); tempCouponVos.add(tempCouponVo);
} }
vo.setTempCouponVos(tempCouponVos); vo.setTempCouponVos(tempCouponVos);
......
...@@ -99,13 +99,20 @@ public class ObjectUtil { ...@@ -99,13 +99,20 @@ public class ObjectUtil {
private static final ArrayList<GoblinMixDetailsItemVo> goblinMixDetailsItemVo = new ArrayList<>(); private static final ArrayList<GoblinMixDetailsItemVo> goblinMixDetailsItemVo = new ArrayList<>();
private static final ArrayList<GoblinMixManageListVo> goblinMixManageListVo = new ArrayList<>(); private static final ArrayList<GoblinMixManageListVo> goblinMixManageListVo = new ArrayList<>();
private static final ArrayList<GoblinMixAppListVo> goblinMixAppListVo = new ArrayList<>(); private static final ArrayList<GoblinMixAppListVo> goblinMixAppListVo = new ArrayList<>();
private static final ArrayList<CouponCountVo> couponCountVos = new ArrayList<>();
private static final ArrayList<GoblinMixDetailsVo> goblinMixDetailsVo = new ArrayList<>(); private static final ArrayList<GoblinMixDetailsVo> goblinMixDetailsVo = new ArrayList<>();
private static final HashMap<String, String[]> mixIdMap = new HashMap(); private static final HashMap<String, String[]> mixIdMap = new HashMap();
public static HashMap<String, String[]> mixIdMap() { public static HashMap<String, String[]> mixIdMap() {
return (HashMap<String, String[]>) mixIdMap.clone(); return (HashMap<String, String[]>) mixIdMap.clone();
} }
public static ArrayList<CouponCountVo> couponCountVos() {
return (ArrayList<CouponCountVo>) couponCountVos.clone();
}
public static ArrayList<GoblinMixAppListVo> goblinMixAppListVo() { public static ArrayList<GoblinMixAppListVo> goblinMixAppListVo() {
return (ArrayList<GoblinMixAppListVo>) goblinMixAppListVo.clone(); return (ArrayList<GoblinMixAppListVo>) goblinMixAppListVo.clone();
} }
......
...@@ -85,18 +85,18 @@ goblin.store.market.delSpuRelation=UPDATE goblin_store_market_purchasing SET del ...@@ -85,18 +85,18 @@ goblin.store.market.delSpuRelation=UPDATE goblin_store_market_purchasing SET del
goblin.self.market.insertRelation=INSERT INTO goblin_marketing_zhengzai (`zhengzai_id`,`self_market_id`,`spu_id`,`sku_id`,`store_id`,`price_marketing`,`stock_marketing`,`buy_factor`,`buy_roster`,`buy_limit`,`del_flag`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?) goblin.self.market.insertRelation=INSERT INTO goblin_marketing_zhengzai (`zhengzai_id`,`self_market_id`,`spu_id`,`sku_id`,`store_id`,`price_marketing`,`stock_marketing`,`buy_factor`,`buy_roster`,`buy_limit`,`del_flag`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?)
goblin.self.market.updateRelation=UPDATE goblin_marketing_zhengzai SET price_marketing=? ,stock_marketing=? , buy_factor=?,buy_roster=?,buy_limit=?,updated_at=? WHERE self_market_id =? and store_id =? goblin.self.market.updateRelation=UPDATE goblin_marketing_zhengzai SET price_marketing=? ,stock_marketing=? , buy_factor=?,buy_roster=?,buy_limit=?,updated_at=? WHERE self_market_id =? and store_id =?
goblin.self.market.delSpuRelation=UPDATE goblin_marketing_zhengzai SET del_flag = ?,updated_at = ? WHERE self_market_id =? and store_id =? and spu_id=? goblin.self.market.delSpuRelation=UPDATE goblin_marketing_zhengzai SET del_flag = ?,updated_at = ? WHERE self_market_id =? and store_id =? and spu_id=?
#---- \u8BA2\u5355\u521B\u5EFA&\u652F\u4ED8
goblin_order.pay.order=UPDATE goblin_store_order SET payment_type = ? ,payment_id=?,pay_code = ? ,pay_time = ?,write_off_code = ? ,zhengzai_status =?,status = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.pay.sku=UPDATE goblin_order_sku SET status = ? ,updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
#---- \u8BA2\u5355\u7ED1\u5B9A[\u6B63\u5728\u4E0B\u5355] \u51FA\u8D27 #---- \u8BA2\u5355\u7ED1\u5B9A[\u6B63\u5728\u4E0B\u5355] \u51FA\u8D27
goblin_order.zhengzai.bind=UPDATE goblin_store_order SET user_id = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.zhengzai.bind=UPDATE goblin_store_order SET user_id = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.zhengzai.push=UPDATE goblin_store_order SET zhengzai_status = ? ,status = ?,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.zhengzai.push=UPDATE goblin_store_order SET zhengzai_status = ? ,status = ?,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
#---- \u5546\u94FA\u8BA2\u5355\u64CD\u4F5C #---- \u5546\u94FA\u8BA2\u5355\u64CD\u4F5C
goblin_order.store.cancel=UPDATE goblin_store_order SET status = ? ,cancel_time = ? , cancel_reason = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.cancel=UPDATE goblin_store_order SET status = ? ,cancel_time = ? , cancel_reason = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.orderSkuStatus=UPDATE goblin_order_sku SET status = ? , updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.orderSkuStatus=UPDATE goblin_order_sku SET status = ? , updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.orderSkuPush=UPDATE goblin_order_sku SET status = ? , updated_at = ?,push_time = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.orderPush=UPDATE goblin_store_order SET status = ? ,zhengzai_status=?, updated_at = ?,push_time = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.express=UPDATE goblin_store_order SET status = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.express=UPDATE goblin_store_order SET status = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.mail=INSERT INTO goblin_mail (`mail_id`,`order_id`,`mail_no`,`delivery_time`,`logistics_company`,`order_sku_ids`,`created_at`) VALUES (?,?,?,?,?,?,?) goblin_order.mail=INSERT INTO goblin_mail (`mail_id`,`order_id`,`mail_no`,`delivery_time`,`logistics_company`,`order_sku_ids`,`created_at`) VALUES (?,?,?,?,?,?,?)
goblin_order.mail.update=UPDATE goblin_mail SET mail_no = ? , updated_at = ? WHERE mail_id = ? goblin_order.mail.update=UPDATE goblin_mail SET mail_no = ? , updated_at = ? WHERE mail_id = ?
goblin_order.store.address=UPDATE goblin_order_attr SET express_contacts = ? ,express_address_detail = ? , express_phone = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.address=UPDATE goblin_order_attr SET express_contacts = ? ,express_address_detail = ? , express_phone = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.orderPrice=UPDATE goblin_store_order SET price_modify = ? ,price_voucher = ? , price_actual = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.orderPrice=UPDATE goblin_store_order SET price_modify = ? ,price_voucher = ? , price_actual = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.orderSkuPrice=UPDATE goblin_order_sku SET price_modify = ? ,price_voucher = ? , sku_price_actual = ? , updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.orderSkuPrice=UPDATE goblin_order_sku SET price_modify = ? ,price_voucher = ? , sku_price_actual = ? , updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
......
...@@ -444,7 +444,7 @@ public class KylinPerformancesServiceImpl implements IKylinPerformancesService { ...@@ -444,7 +444,7 @@ public class KylinPerformancesServiceImpl implements IKylinPerformancesService {
performancesInfo.setMessage(KylinPerformanceStatusEnum.getName(performancesInfo.getAppStatus())); performancesInfo.setMessage(KylinPerformanceStatusEnum.getName(performancesInfo.getAppStatus()));
PayDetailVo payDetailVo = new PayDetailVo(); PayDetailVo payDetailVo = new PayDetailVo();
if (ticketVo.getIsExpress() == 1) { if (ticketVo!=null && ticketVo.getIsExpress() == 1) {
KylinTicketExpressModuleVo expressModuleVo = dataUtils.getTEMVo(ticketsId); KylinTicketExpressModuleVo expressModuleVo = dataUtils.getTEMVo(ticketsId);
payDetailVo.setExpressModuleList(expressModuleVo == null ? null : expressModuleVo.getProduceCodeList()); payDetailVo.setExpressModuleList(expressModuleVo == null ? null : expressModuleVo.getProduceCodeList());
} else { } else {
......
...@@ -270,6 +270,7 @@ public class DataUtils { ...@@ -270,6 +270,7 @@ public class DataUtils {
if (obj != null) { if (obj != null) {
return (KylinPerformanceVo) obj; return (KylinPerformanceVo) obj;
} else { } else {
KylinPerformanceVo performanceData = mongoTemplate.findOne(Query.query(Criteria.where("performancesId").is(performanceId)), KylinPerformanceVo.class, KylinPerformanceVo.class.getSimpleName()); KylinPerformanceVo performanceData = mongoTemplate.findOne(Query.query(Criteria.where("performancesId").is(performanceId)), KylinPerformanceVo.class, KylinPerformanceVo.class.getSimpleName());
redisUtil.set(KylinRedisConst.PERFORMANCES + performanceId, performanceData); redisUtil.set(KylinRedisConst.PERFORMANCES + performanceId, performanceData);
return performanceData; return performanceData;
......
...@@ -58,6 +58,11 @@ public class WepayPayRespDto { ...@@ -58,6 +58,11 @@ public class WepayPayRespDto {
private String attach; private String attach;
@XStreamAlias("time_end") @XStreamAlias("time_end")
private String time_end; private String time_end;
@XStreamAlias("err_code")
private String err_code;
@XStreamAlias("err_code_des")
private String err_code_des;
public static void xmlToBean(){ public static void xmlToBean(){
String xmlStr = "<xml><return_code><![CDATA[SUCCESS]]></return_code>\n" + String xmlStr = "<xml><return_code><![CDATA[SUCCESS]]></return_code>\n" +
......
...@@ -101,12 +101,14 @@ public abstract class AbstractWepayStrategy implements IWepayStrategy { ...@@ -101,12 +101,14 @@ public abstract class AbstractWepayStrategy implements IWepayStrategy {
throw new LiquidnetServiceException(DragonErrorCodeEnum.TRADE_PARAM_ERROR.getCode(),DragonErrorCodeEnum.TRADE_PARAM_ERROR.getMessage()); throw new LiquidnetServiceException(DragonErrorCodeEnum.TRADE_PARAM_ERROR.getCode(),DragonErrorCodeEnum.TRADE_PARAM_ERROR.getMessage());
} }
if(WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getReturnCode())){ if(WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getReturnCode())){
if(WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getResultCode())){ if(WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getResultCode())||dragonPayBaseReqDto.getDeviceFrom().equals("micropay")){
//构造公共返回参数 //构造公共返回参数
DragonPayBaseRespDto respPayDto = this.buildCommonRespDto(dragonPayBaseReqDto,respWepayDto); DragonPayBaseRespDto respPayDto = this.buildCommonRespDto(dragonPayBaseReqDto,respWepayDto);
//构造自定义返回参数 //构造自定义返回参数
this.buildResponseDto(respPayDto,respWepayDto); this.buildResponseDto(respPayDto,respWepayDto);
if(!WepayConstant.WeixinTradeStateEnum.SUCCESS.getCode().equalsIgnoreCase(respWepayDto.getResultCode())&&dragonPayBaseReqDto.getDeviceFrom().equals("micropay")) {
respPayDto.setMsg(respWepayDto.getErr_code_des());
}
//支付订单持久化 //支付订单持久化
dragonServiceCommonBiz.buildPayOrders(dragonPayBaseReqDto,respPayDto); dragonServiceCommonBiz.buildPayOrders(dragonPayBaseReqDto,respPayDto);
log.info("wepay-->dragonPay--> 耗时:{}",(System.currentTimeMillis() - startTimeTotal)+"毫秒"); log.info("wepay-->dragonPay--> 耗时:{}",(System.currentTimeMillis() - startTimeTotal)+"毫秒");
......
...@@ -497,7 +497,7 @@ public class GoblinNftOrderServiceImpl implements IGoblinNftOrderService { ...@@ -497,7 +497,7 @@ public class GoblinNftOrderServiceImpl implements IGoblinNftOrderService {
nftOrder.getNum(), nftOrder.getStoreId(), nftOrder.getStoreName(), nftOrder.getOrderCode(), nftOrder.getUserId(), nftOrder.getUserName(), nftOrder.getUserMobile(), nftOrder.getPriceTotal(), nftOrder.getPriceCoupon(), nftOrder.getNum(), nftOrder.getStoreId(), nftOrder.getStoreName(), nftOrder.getOrderCode(), nftOrder.getUserId(), nftOrder.getUserName(), nftOrder.getUserMobile(), nftOrder.getPriceTotal(), nftOrder.getPriceCoupon(),
nftOrder.getStorePriceCoupon(), nftOrder.getPriceRedEnvelope(), nftOrder.getPriceVoucher(), nftOrder.getPriceActual(), nftOrder.getUcouponId(), nftOrder.getStoreCouponId(), nftOrder.getRedEnvelopeCode(), nftOrder.getStatus(), nftOrder.getSource(), nftOrder.getStorePriceCoupon(), nftOrder.getPriceRedEnvelope(), nftOrder.getPriceVoucher(), nftOrder.getPriceActual(), nftOrder.getUcouponId(), nftOrder.getStoreCouponId(), nftOrder.getRedEnvelopeCode(), nftOrder.getStatus(), nftOrder.getSource(),
nftOrder.getOrderType(), nftOrder.getPayType(), nftOrder.getDeviceFrom(), nftOrder.getVersion(), nftOrder.getPayCountdownMinute(), nftOrder.getIpAddress(), nftOrder.getCreatedAt(), nftOrder.getPayCode(), nftOrder.getOrderType(), nftOrder.getPayType(), nftOrder.getDeviceFrom(), nftOrder.getVersion(), nftOrder.getPayCountdownMinute(), nftOrder.getIpAddress(), nftOrder.getCreatedAt(), nftOrder.getPayCode(),
nftOrder.getSkuTitle(), nftOrder.getListId(), nftOrder.getExCode(),"" nftOrder.getSkuTitle(), nftOrder.getListId(), nftOrder.getExCode(),"",""
}); });
// 订单vo // 订单vo
...@@ -908,7 +908,7 @@ public class GoblinNftOrderServiceImpl implements IGoblinNftOrderService { ...@@ -908,7 +908,7 @@ public class GoblinNftOrderServiceImpl implements IGoblinNftOrderService {
nftOrder.getNum(), nftOrder.getStoreId(), nftOrder.getStoreName(), nftOrder.getOrderCode(), nftOrder.getUserId(), nftOrder.getUserName(), nftOrder.getUserMobile(), nftOrder.getPriceTotal(), nftOrder.getPriceCoupon(), nftOrder.getNum(), nftOrder.getStoreId(), nftOrder.getStoreName(), nftOrder.getOrderCode(), nftOrder.getUserId(), nftOrder.getUserName(), nftOrder.getUserMobile(), nftOrder.getPriceTotal(), nftOrder.getPriceCoupon(),
nftOrder.getStorePriceCoupon(), nftOrder.getPriceRedEnvelope(), nftOrder.getPriceVoucher(), nftOrder.getPriceActual(), nftOrder.getUcouponId(), nftOrder.getStoreCouponId(), nftOrder.getRedEnvelopeCode(), orderVo.getStatus(), nftOrder.getSource(), nftOrder.getStorePriceCoupon(), nftOrder.getPriceRedEnvelope(), nftOrder.getPriceVoucher(), nftOrder.getPriceActual(), nftOrder.getUcouponId(), nftOrder.getStoreCouponId(), nftOrder.getRedEnvelopeCode(), orderVo.getStatus(), nftOrder.getSource(),
nftOrder.getOrderType(), orderVo.getPayType(), nftOrder.getDeviceFrom(), nftOrder.getVersion(), nftOrder.getPayCountdownMinute(), nftOrder.getIpAddress(), nftOrder.getCreatedAt(), orderVo.getPayCode(), nftOrder.getOrderType(), orderVo.getPayType(), nftOrder.getDeviceFrom(), nftOrder.getVersion(), nftOrder.getPayCountdownMinute(), nftOrder.getIpAddress(), nftOrder.getCreatedAt(), orderVo.getPayCode(),
nftOrder.getSkuTitle(), nftOrder.getListId(), nftOrder.getExCode(),"" nftOrder.getSkuTitle(), nftOrder.getListId(), nftOrder.getExCode(),"",""
}); });
String sqlData = SqlMapping.gets(sqls, sqlDataCode, sqlDataOrder); String sqlData = SqlMapping.gets(sqls, sqlDataCode, sqlDataOrder);
queueUtils.sendMsgByRedis(MQConst.GoblinQueue.GOBLIN_NFT_ORDER.getKey(), sqlData); queueUtils.sendMsgByRedis(MQConst.GoblinQueue.GOBLIN_NFT_ORDER.getKey(), sqlData);
......
...@@ -463,6 +463,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -463,6 +463,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
payInnerResultVo.setPayData(dto.getData().getPayData()); payInnerResultVo.setPayData(dto.getData().getPayData());
payInnerResultVo.setPayType(preParam.getPayType()); payInnerResultVo.setPayType(preParam.getPayType());
payInnerResultVo.setPrice(preParam.getPriceActual()); payInnerResultVo.setPrice(preParam.getPriceActual());
payInnerResultVo.setMsg(dto.getData().getMsg());
payCode = payInnerResultVo.getCode(); payCode = payInnerResultVo.getCode();
payInnerResultVo.setShowUrl(preParam.getShowUrl()); payInnerResultVo.setShowUrl(preParam.getShowUrl());
payInnerResultVo.setReturnUrl(preParam.getReturnUrl()); payInnerResultVo.setReturnUrl(preParam.getReturnUrl());
...@@ -573,7 +574,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -573,7 +574,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
sqlDataOrder.add(new Object[]{ sqlDataOrder.add(new Object[]{
storeOrder.getMasterOrderCode(), storeOrder.getOrderId(), storeOrder.getStoreId(), storeOrder.getStoreName(), storeOrder.getOrderCode(), storeOrder.getUserId(), storeOrder.getUserName(), storeOrder.getUserMobile(), storeOrder.getPriceTotal(), storeOrder.getPayCode(), storeOrder.getMasterOrderCode(), storeOrder.getOrderId(), storeOrder.getStoreId(), storeOrder.getStoreName(), storeOrder.getOrderCode(), storeOrder.getUserId(), storeOrder.getUserName(), storeOrder.getUserMobile(), storeOrder.getPriceTotal(), storeOrder.getPayCode(),
storeOrder.getPriceActual(), storeOrder.getPriceRefund(), storeOrder.getPriceExpress(), storeOrder.getPriceCoupon(), storeOrder.getStorePriceCoupon(), storeOrder.getPriceVoucher(), storeOrder.getStatus(), storeOrder.getUcouponId(), storeOrder.getStoreCouponId(), storeOrder.getPayType(), storeOrder.getDeviceFrom(), storeOrder.getPriceActual(), storeOrder.getPriceRefund(), storeOrder.getPriceExpress(), storeOrder.getPriceCoupon(), storeOrder.getStorePriceCoupon(), storeOrder.getPriceVoucher(), storeOrder.getStatus(), storeOrder.getUcouponId(), storeOrder.getStoreCouponId(), storeOrder.getPayType(), storeOrder.getDeviceFrom(),
storeOrder.getSource(), storeOrder.getVersion(), storeOrder.getIsMember(), storeOrder.getOrderType(), storeOrder.getWriteOffCode(), storeOrder.getPayCountdownMinute(), storeOrder.getIpAddress(), storeOrder.getMarketId(), storeOrder.getMarketType(), storeOrder.getCreatedAt(), "" storeOrder.getSource(), storeOrder.getVersion(), storeOrder.getIsMember(), storeOrder.getOrderType(), storeOrder.getWriteOffCode(), storeOrder.getPayCountdownMinute(), storeOrder.getIpAddress(), storeOrder.getMarketId(), storeOrder.getMarketType(), storeOrder.getCreatedAt(), "",""
}); });
GoblinOrderAttr orderAttr = item.getOrderAttr(); GoblinOrderAttr orderAttr = item.getOrderAttr();
sqlDataAttr.add(new Object[]{ sqlDataAttr.add(new Object[]{
...@@ -798,11 +799,13 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -798,11 +799,13 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
if (orderVo.getDeviceFrom().equals("micropay") && GoblinStatusConst.MarketPreStatus.MARKET_PRE_ZHENGZAI.getValue().equals(orderVo.getMarketType())) { if (orderVo.getDeviceFrom().equals("micropay") && GoblinStatusConst.MarketPreStatus.MARKET_PRE_ZHENGZAI.getValue().equals(orderVo.getMarketType())) {
storeOrder.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue()); storeOrder.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue());
storeOrder.setZhengzaiStatus(1); storeOrder.setZhengzaiStatus(1);
storeOrder.setPushTime(now);
orderVo.setPushTime(now.format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss")));
} }
storeOrder.setUpdatedAt(now); storeOrder.setUpdatedAt(now);
sqls.add(SqlMapping.get("goblin_order.pay.order")); sqls.add(SqlMapping.get("goblin_order.pay.order"));
sqlDataOrder.add(new Object[]{ sqlDataOrder.add(new Object[]{
storeOrder.getPaymentType(), storeOrder.getPaymentId(), storeOrder.getPayCode(), storeOrder.getPayTime(), storeOrder.getWriteOffCode(), storeOrder.getZhengzaiStatus(), storeOrder.getStatus(), storeOrder.getUpdatedAt(), storeOrder.getPaymentType(), storeOrder.getPaymentId(), storeOrder.getPayCode(), storeOrder.getPayTime(), storeOrder.getWriteOffCode(), storeOrder.getZhengzaiStatus(), storeOrder.getStatus(), storeOrder.getUpdatedAt(),storeOrder.getPushTime(),
orderId, now, now orderId, now, now
}); });
sqls.add(SqlMapping.get("goblin_order.pay.sku")); sqls.add(SqlMapping.get("goblin_order.pay.sku"));
...@@ -813,6 +816,10 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -813,6 +816,10 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
log.debug("增加销量 spuId=" + orderSkuVo.getSpuId() + ",skuId=" + orderSkuVo.getSkuId()); log.debug("增加销量 spuId=" + orderSkuVo.getSpuId() + ",skuId=" + orderSkuVo.getSkuId());
redisUtils.incrSkuSaleCount(orderSkuVo.getSpuId(), orderSkuVo.getSkuId(), orderSkuVo.getNum()); redisUtils.incrSkuSaleCount(orderSkuVo.getSpuId(), orderSkuVo.getSkuId(), orderSkuVo.getNum());
orderSkuVo.setStatus(GoblinStatusConst.Status.ORDER_STATUS_2.getValue()); orderSkuVo.setStatus(GoblinStatusConst.Status.ORDER_STATUS_2.getValue());
if (orderVo.getDeviceFrom().equals("micropay") && GoblinStatusConst.MarketPreStatus.MARKET_PRE_ZHENGZAI.getValue().equals(orderVo.getMarketType())) {
orderSkuVo.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue());
orderSkuVo.setPushTime(now.format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss")));
}
//redis //redis
redisUtils.setGoblinOrderSku(orderSkuVo.getOrderSkuId(), orderSkuVo); redisUtils.setGoblinOrderSku(orderSkuVo.getOrderSkuId(), orderSkuVo);
//mongo //mongo
...@@ -840,7 +847,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -840,7 +847,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
mongoUtils.insertGoblinOrderLogVo(logVo); mongoUtils.insertGoblinOrderLogVo(logVo);
//mysql //mysql
sqlDataSku.add(new Object[]{ sqlDataSku.add(new Object[]{
GoblinStatusConst.Status.ORDER_STATUS_2.getValue(), now, orderSkuVo.getStatus(), now,orderSkuVo.getStatus()==4?now:null,
orderSkuVo.getOrderSkuId(), now, now orderSkuVo.getOrderSkuId(), now, now
}); });
} }
...@@ -1104,9 +1111,10 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -1104,9 +1111,10 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
storeOrder.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue()); storeOrder.setStatus(GoblinStatusConst.Status.ORDER_STATUS_4.getValue());
storeOrder.setZhengzaiStatus(1); storeOrder.setZhengzaiStatus(1);
storeOrder.setUpdatedAt(now); storeOrder.setUpdatedAt(now);
storeOrder.setPushTime(now);
sqls.add(SqlMapping.get("goblin_order.pay.order")); sqls.add(SqlMapping.get("goblin_order.pay.order"));
sqlDataOrder.add(new Object[]{ sqlDataOrder.add(new Object[]{
storeOrder.getPaymentType(), storeOrder.getPaymentId(), storeOrder.getPayCode(), storeOrder.getPayTime(), storeOrder.getWriteOffCode(), storeOrder.getZhengzaiStatus(), storeOrder.getStatus(), storeOrder.getUpdatedAt(), storeOrder.getPaymentType(), storeOrder.getPaymentId(), storeOrder.getPayCode(), storeOrder.getPayTime(), storeOrder.getWriteOffCode(), storeOrder.getZhengzaiStatus(), storeOrder.getStatus(), storeOrder.getUpdatedAt(),storeOrder.getPushTime(),
orderId, now, now orderId, now, now
}); });
sqls.add(SqlMapping.get("goblin_order.pay.sku")); sqls.add(SqlMapping.get("goblin_order.pay.sku"));
...@@ -1143,7 +1151,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -1143,7 +1151,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
mongoUtils.insertGoblinOrderLogVo(logVo); mongoUtils.insertGoblinOrderLogVo(logVo);
//mysql //mysql
sqlDataSku.add(new Object[]{ sqlDataSku.add(new Object[]{
orderSkuVo.getStatus(), now, orderSkuVo.getStatus(), now,now,
orderSkuVo.getOrderSkuId(), now, now orderSkuVo.getOrderSkuId(), now, now
}); });
} }
......
...@@ -1079,12 +1079,12 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsOrderServ ...@@ -1079,12 +1079,12 @@ public class KylinOrderTicketsServiceImpl implements IKylinOrderTicketsOrderServ
public ResponseDto<Integer> checkOrderResult(String orderId) { public ResponseDto<Integer> checkOrderResult(String orderId) {
String uid = CurrentUtil.getCurrentUid(); String uid = CurrentUtil.getCurrentUid();
KylinOrderTicketVo orderTicketData = dataUtils.getOrderTicketVo(orderId); KylinOrderTicketVo orderTicketData = dataUtils.getOrderTicketVo(orderId);
if (!orderTicketData.getUserId().equals(uid)) {
return null;
}
if (orderTicketData == null) { if (orderTicketData == null) {
return ResponseDto.failure(ErrorMapping.get("20024")); return ResponseDto.failure(ErrorMapping.get("20024"));
} else { } else {
if (!orderTicketData.getUserId().equals(uid)) {
return null;
}
String returnCheckData = HttpUtil.get(checkUrl + "?code=" + orderTicketData.getPayCode(), null); String returnCheckData = HttpUtil.get(checkUrl + "?code=" + orderTicketData.getPayCode(), null);
SyncOrderDtoParam syncOrderDtoParam = JsonUtils.fromJson(returnCheckData, SyncOrderDtoParam.class); SyncOrderDtoParam syncOrderDtoParam = JsonUtils.fromJson(returnCheckData, SyncOrderDtoParam.class);
if (syncOrderDtoParam.getData().getStatus() == 1) { if (syncOrderDtoParam.getData().getStatus() == 1) {
......
...@@ -187,7 +187,7 @@ public class MixOrderServiceImpl implements IMixOrderService { ...@@ -187,7 +187,7 @@ public class MixOrderServiceImpl implements IMixOrderService {
//生成goblin订单 //生成goblin订单
GoblinOrderPreParam preParam = null; GoblinOrderPreParam preParam = null;
if (skuInfoList.size() > 0) { if (skuInfoList.size() > 0) {
preParam = goblinOrder(skuInfoList, skuMix, param.getAddressesVo(), mobile, source, version, nickName, nt, uid, param.getPayType(), param.getDeviceFrom(),orderMasterCode); preParam = goblinOrder(skuInfoList, skuMix, param.getAddressesVo(), mobile, source, version, nickName, nt, uid, param.getPayType(), param.getDeviceFrom(), orderMasterCode);
} }
return ResponseDto.success(payOrder(nftOrderList, preParam, orderMasterCode, param.getShowUrl(), param.getReturnUrl(), param.getDeviceFrom(), param.getPayType(), mixId, mixVo.getName(), param.getOpenId(), nt, storeName)); return ResponseDto.success(payOrder(nftOrderList, preParam, orderMasterCode, param.getShowUrl(), param.getReturnUrl(), param.getDeviceFrom(), param.getPayType(), mixId, mixVo.getName(), param.getOpenId(), nt, storeName));
} catch (Exception e) { } catch (Exception e) {
...@@ -198,7 +198,7 @@ public class MixOrderServiceImpl implements IMixOrderService { ...@@ -198,7 +198,7 @@ public class MixOrderServiceImpl implements IMixOrderService {
} }
//商品订单 //商品订单
private GoblinOrderPreParam goblinOrder(List<GoblinGoodsSkuInfoVo> skuVoList, HashMap<String, Object> skuMix, AddressVo addressVo, String mobile, String source, String version, String nickName, LocalDateTime now, String uid, String payType, String deviceFrom,String masterCode) { private GoblinOrderPreParam goblinOrder(List<GoblinGoodsSkuInfoVo> skuVoList, HashMap<String, Object> skuMix, AddressVo addressVo, String mobile, String source, String version, String nickName, LocalDateTime now, String uid, String payType, String deviceFrom, String masterCode) {
String orderMasterCode = masterCode; String orderMasterCode = masterCode;
String orderId = IDGenerator.nextSnowId(); String orderId = IDGenerator.nextSnowId();
String orderCode = IDGenerator.storeCode(orderId); String orderCode = IDGenerator.storeCode(orderId);
...@@ -453,7 +453,7 @@ public class MixOrderServiceImpl implements IMixOrderService { ...@@ -453,7 +453,7 @@ public class MixOrderServiceImpl implements IMixOrderService {
nftItem.getNum(), nftItem.getStoreId(), nftItem.getStoreName(), nftItem.getOrderCode(), nftItem.getUserId(), nftItem.getUserName(), nftItem.getUserMobile(), nftItem.getPriceTotal(), nftItem.getPriceCoupon(), nftItem.getNum(), nftItem.getStoreId(), nftItem.getStoreName(), nftItem.getOrderCode(), nftItem.getUserId(), nftItem.getUserName(), nftItem.getUserMobile(), nftItem.getPriceTotal(), nftItem.getPriceCoupon(),
nftItem.getStorePriceCoupon(), nftItem.getPriceRedEnvelope(), nftItem.getPriceVoucher(), nftItem.getPriceActual(), nftItem.getUcouponId(), nftItem.getStoreCouponId(), nftItem.getRedEnvelopeCode(), nftItem.getStatus(), nftItem.getSource(), nftItem.getStorePriceCoupon(), nftItem.getPriceRedEnvelope(), nftItem.getPriceVoucher(), nftItem.getPriceActual(), nftItem.getUcouponId(), nftItem.getStoreCouponId(), nftItem.getRedEnvelopeCode(), nftItem.getStatus(), nftItem.getSource(),
nftItem.getOrderType(), nftItem.getPayType(), nftItem.getDeviceFrom(), nftItem.getVersion(), nftItem.getPayCountdownMinute(), nftItem.getIpAddress(), nftItem.getCreatedAt(), nftItem.getPayCode(), nftItem.getOrderType(), nftItem.getPayType(), nftItem.getDeviceFrom(), nftItem.getVersion(), nftItem.getPayCountdownMinute(), nftItem.getIpAddress(), nftItem.getCreatedAt(), nftItem.getPayCode(),
nftItem.getSkuTitle(), nftItem.getListId(), nftItem.getExCode(), mixId nftItem.getSkuTitle(), nftItem.getListId(), nftItem.getExCode(), mixId,masterCode
}); });
// 订单vo redis // 订单vo redis
GoblinNftOrderVo orderVo = GoblinNftOrderVo.getNew().copyMix(nftItem, mixId, mixName); GoblinNftOrderVo orderVo = GoblinNftOrderVo.getNew().copyMix(nftItem, mixId, mixName);
...@@ -486,7 +486,7 @@ public class MixOrderServiceImpl implements IMixOrderService { ...@@ -486,7 +486,7 @@ public class MixOrderServiceImpl implements IMixOrderService {
sqlDataGoblin.add(new Object[]{ sqlDataGoblin.add(new Object[]{
storeOrder.getMasterOrderCode(), storeOrder.getOrderId(), storeOrder.getStoreId(), storeOrder.getStoreName(), storeOrder.getOrderCode(), storeOrder.getUserId(), storeOrder.getUserName(), storeOrder.getUserMobile(), storeOrder.getPriceTotal(), storeOrder.getPayCode(), storeOrder.getMasterOrderCode(), storeOrder.getOrderId(), storeOrder.getStoreId(), storeOrder.getStoreName(), storeOrder.getOrderCode(), storeOrder.getUserId(), storeOrder.getUserName(), storeOrder.getUserMobile(), storeOrder.getPriceTotal(), storeOrder.getPayCode(),
storeOrder.getPriceActual(), storeOrder.getPriceRefund(), storeOrder.getPriceExpress(), storeOrder.getPriceCoupon(), storeOrder.getStorePriceCoupon(), storeOrder.getPriceVoucher(), storeOrder.getStatus(), storeOrder.getUcouponId(), storeOrder.getStoreCouponId(), storeOrder.getPayType(), storeOrder.getDeviceFrom(), storeOrder.getPriceActual(), storeOrder.getPriceRefund(), storeOrder.getPriceExpress(), storeOrder.getPriceCoupon(), storeOrder.getStorePriceCoupon(), storeOrder.getPriceVoucher(), storeOrder.getStatus(), storeOrder.getUcouponId(), storeOrder.getStoreCouponId(), storeOrder.getPayType(), storeOrder.getDeviceFrom(),
storeOrder.getSource(), storeOrder.getVersion(), storeOrder.getIsMember(), storeOrder.getOrderType(), storeOrder.getWriteOffCode(), storeOrder.getPayCountdownMinute(), storeOrder.getIpAddress(), storeOrder.getMarketId(), storeOrder.getMarketType(), storeOrder.getCreatedAt(), "" storeOrder.getSource(), storeOrder.getVersion(), storeOrder.getIsMember(), storeOrder.getOrderType(), storeOrder.getWriteOffCode(), storeOrder.getPayCountdownMinute(), storeOrder.getIpAddress(), storeOrder.getMarketId(), storeOrder.getMarketType(), storeOrder.getCreatedAt(), mixId,masterCode
}); });
GoblinOrderAttr orderAttr = preParam.getOrderAttr(); GoblinOrderAttr orderAttr = preParam.getOrderAttr();
sqlDataAttr.add(new Object[]{ sqlDataAttr.add(new Object[]{
...@@ -617,7 +617,7 @@ public class MixOrderServiceImpl implements IMixOrderService { ...@@ -617,7 +617,7 @@ public class MixOrderServiceImpl implements IMixOrderService {
storeOrder.setUpdatedAt(now); storeOrder.setUpdatedAt(now);
sqls.add(SqlMapping.get("goblin_order.pay.order")); sqls.add(SqlMapping.get("goblin_order.pay.order"));
sqlDataOrder.add(new Object[]{ sqlDataOrder.add(new Object[]{
storeOrder.getPaymentType(), storeOrder.getPaymentId(), storeOrder.getPayCode(), storeOrder.getPayTime(), storeOrder.getWriteOffCode(), storeOrder.getZhengzaiStatus(),storeOrder.getStatus(), storeOrder.getUpdatedAt(), storeOrder.getPaymentType(), storeOrder.getPaymentId(), storeOrder.getPayCode(), storeOrder.getPayTime(), storeOrder.getWriteOffCode(), storeOrder.getZhengzaiStatus(), storeOrder.getStatus(), storeOrder.getUpdatedAt(), null,
orderId, now, now orderId, now, now
}); });
sqls.add(SqlMapping.get("goblin_order.pay.sku")); sqls.add(SqlMapping.get("goblin_order.pay.sku"));
...@@ -654,7 +654,7 @@ public class MixOrderServiceImpl implements IMixOrderService { ...@@ -654,7 +654,7 @@ public class MixOrderServiceImpl implements IMixOrderService {
//mysql //mysql
sqlDataSku.add(new Object[]{ sqlDataSku.add(new Object[]{
GoblinStatusConst.Status.ORDER_STATUS_2.getValue(), now, GoblinStatusConst.Status.ORDER_STATUS_2.getValue(), now, orderSkuVo.getStatus() == 4 ? now : null,
orderSkuVo.getOrderSkuId(), now, now orderSkuVo.getOrderSkuId(), now, now
}); });
} }
......
...@@ -30,14 +30,14 @@ kylin_order_refund_entities.overtimeRefund=INSERT INTO kylin_order_refund_entiti ...@@ -30,14 +30,14 @@ kylin_order_refund_entities.overtimeRefund=INSERT INTO kylin_order_refund_entiti
#-------- \u5546\u57CE ------- #-------- \u5546\u57CE -------
goblin.order.create.order_insert=INSERT INTO goblin_store_order (`master_order_code`,`order_id`,`store_id`,`store_name`,`order_code`,`user_id`,`user_name`,`user_mobile`,`price_total`,`pay_code`,`price_actual`,`price_refund`,`price_express`,`price_coupon`,`store_price_coupon`,`price_voucher`,`status`,`ucoupon_id`,`store_coupon_id`,`pay_type`,`device_from`,`source`,`version`,`is_member`,`order_type`,`write_off_code`,`pay_countdown_minute`,`ip_address`,`market_id`,`market_type`,`created_at`,`mix_id`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin.order.create.order_insert=INSERT INTO goblin_store_order (`master_order_code`,`order_id`,`store_id`,`store_name`,`order_code`,`user_id`,`user_name`,`user_mobile`,`price_total`,`pay_code`,`price_actual`,`price_refund`,`price_express`,`price_coupon`,`store_price_coupon`,`price_voucher`,`status`,`ucoupon_id`,`store_coupon_id`,`pay_type`,`device_from`,`source`,`version`,`is_member`,`order_type`,`write_off_code`,`pay_countdown_minute`,`ip_address`,`market_id`,`market_type`,`created_at`,`mix_id`,`mix_code`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin.order.create.attr_insert=INSERT INTO goblin_order_attr (`order_attr_id`,`order_id`,`express_contacts`,`express_address`,`express_address_detail`,`express_phone`,`express_type`,`created_at`) VALUES (?,?,?,?,?,?,?,?) goblin.order.create.attr_insert=INSERT INTO goblin_order_attr (`order_attr_id`,`order_id`,`express_contacts`,`express_address`,`express_address_detail`,`express_phone`,`express_type`,`created_at`) VALUES (?,?,?,?,?,?,?,?)
goblin.order.create.sku_insert=INSERT INTO goblin_order_sku (`order_sku_id`,`order_id`,`spu_id`,`spu_name`,`spu_pic`,`sku_id`,`num`,`sku_price`,`sku_price_actual`,`sku_name`,`sku_no`,`sku_image`,`sku_specs`,`price_voucher`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin.order.create.sku_insert=INSERT INTO goblin_order_sku (`order_sku_id`,`order_id`,`spu_id`,`spu_name`,`spu_pic`,`sku_id`,`num`,`sku_price`,`sku_price_actual`,`sku_name`,`sku_no`,`sku_image`,`sku_specs`,`price_voucher`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
#---- \u518D\u6B21\u652F\u4ED8 #---- \u518D\u6B21\u652F\u4ED8
goblin_order.pay.again=UPDATE goblin_store_order SET pay_type = ? ,device_from = ? ,pay_code = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.pay.again=UPDATE goblin_store_order SET pay_type = ? ,device_from = ? ,pay_code = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
#---- \u8BA2\u5355\u521B\u5EFA&\u652F\u4ED8 #---- \u8BA2\u5355\u521B\u5EFA&\u652F\u4ED8
goblin_order.pay.order=UPDATE goblin_store_order SET payment_type = ? ,payment_id=?,pay_code = ? ,pay_time = ?,write_off_code = ? ,zhengzai_status =?,status = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.pay.order=UPDATE goblin_store_order SET payment_type = ? ,payment_id=?,pay_code = ? ,pay_time = ?,write_off_code = ? ,zhengzai_status =?,status = ? ,updated_at = ?,push_time = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.pay.sku=UPDATE goblin_order_sku SET status = ? ,updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.pay.sku=UPDATE goblin_order_sku SET status = ? ,updated_at = ? ,push_time = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.refundPrice=UPDATE goblin_store_order SET price_refund = ? ,status = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.refundPrice=UPDATE goblin_store_order SET price_refund = ? ,status = ? , updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.refundSkuPrice=UPDATE goblin_order_sku SET price_refund = ? ,status = ? , updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.refundSkuPrice=UPDATE goblin_order_sku SET price_refund = ? ,status = ? , updated_at = ? WHERE order_sku_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_order.store.refundBackOrder=UPDATE goblin_back_order SET status = ? ,refund_at=?, updated_at = ? WHERE back_order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.store.refundBackOrder=UPDATE goblin_back_order SET status = ? ,refund_at=?, updated_at = ? WHERE back_order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
...@@ -47,7 +47,7 @@ goblin_order.store.refundLog=INSERT INTO goblin_back_order_log (`back_order_log_ ...@@ -47,7 +47,7 @@ goblin_order.store.refundLog=INSERT INTO goblin_back_order_log (`back_order_log_
goblin_order.store.backOrder=INSERT INTO goblin_back_order (`back_order_id`,`back_code`,`order_id`,`order_code`,`store_id`,`user_id`,`sku_id_nums`,`type`,`reason`,`describes`,`real_back_price`,`status`,`created_at`,`audit_at`,`error_reason`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin_order.store.backOrder=INSERT INTO goblin_back_order (`back_order_id`,`back_code`,`order_id`,`order_code`,`store_id`,`user_id`,`sku_id_nums`,`type`,`reason`,`describes`,`real_back_price`,`status`,`created_at`,`audit_at`,`error_reason`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
#-------- NFT ------- #-------- NFT -------
goblin_nft_order.insert=INSERT INTO goblin_nft_order (`order_id`,`spu_id`,`sku_id`,`box_sku_id`,`num`,`store_id`,`store_name`,`order_code`,`user_id`,`user_name`,`user_mobile`,`price_total`,`price_coupon`,`store_price_coupon`,`price_red_envelope`,`price_voucher`,`price_actual`,`ucoupon_id`,`store_coupon_id`,`red_envelope_code`,`status`,`source`,`order_type`,`pay_type`,`device_from`,`version`,`pay_countdown_minute`,`ip_address`,`created_at`,`pay_code`,sku_title,list_id,ex_code,mix_id) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin_nft_order.insert=INSERT INTO goblin_nft_order (`order_id`,`spu_id`,`sku_id`,`box_sku_id`,`num`,`store_id`,`store_name`,`order_code`,`user_id`,`user_name`,`user_mobile`,`price_total`,`price_coupon`,`store_price_coupon`,`price_red_envelope`,`price_voucher`,`price_actual`,`ucoupon_id`,`store_coupon_id`,`red_envelope_code`,`status`,`source`,`order_type`,`pay_type`,`device_from`,`version`,`pay_countdown_minute`,`ip_address`,`created_at`,`pay_code`,sku_title,list_id,ex_code,mix_id,`mix_code`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin_nft_order.update.pay=UPDATE goblin_nft_order SET payment_type = ?, payment_id=?, pay_code = ?, pay_time = ?, status = ?, updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_nft_order.update.pay=UPDATE goblin_nft_order SET payment_type = ?, payment_id=?, pay_code = ?, pay_time = ?, status = ?, updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_nft_order.update.refund=UPDATE goblin_nft_order SET status = ?, updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_nft_order.update.refund=UPDATE goblin_nft_order SET status = ?, updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
goblin_nft_order_refund.insert=INSERT INTO goblin_nft_order_refund (`order_refund_id`,`refund_code`,`order_id`,`order_code`,`store_id`,`user_id`,`price`,`status`,`error_reason`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?) goblin_nft_order_refund.insert=INSERT INTO goblin_nft_order_refund (`order_refund_id`,`refund_code`,`order_id`,`order_code`,`store_id`,`user_id`,`price`,`status`,`error_reason`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?)
......
...@@ -232,9 +232,11 @@ public class SlimeStationService { ...@@ -232,9 +232,11 @@ public class SlimeStationService {
* @return SlimeStationCheckRefreshVo * @return SlimeStationCheckRefreshVo
*/ */
public SlimeStationCheckRefreshVo downloadRefreshTicketData(SlimeAuthorizationPerformanceVo authorizationPerformanceVo, String performanceId, String latestUpdateAt) { public SlimeStationCheckRefreshVo downloadRefreshTicketData(SlimeAuthorizationPerformanceVo authorizationPerformanceVo, String performanceId, String latestUpdateAt) {
Criteria criteria = Criteria.where("performanceId").is(performanceId).and("isPayment").is(1); Criteria criteria = Criteria.where("performanceId").is(performanceId);
if (StringUtils.isNotEmpty(latestUpdateAt)) { if (StringUtils.isNotEmpty(latestUpdateAt)) {
criteria.and("updatedAt").gte(latestUpdateAt); criteria.and("updatedAt").gte(latestUpdateAt).and("isPayment").in(1, 2, 3);
} else {
criteria.and("isPayment").is(1);
} }
// 查取演出对应的订单票明细 // 查取演出对应的订单票明细
Query orderTicketEntitiesVoQuery = Query.query(criteria); Query orderTicketEntitiesVoQuery = Query.query(criteria);
......
...@@ -153,7 +153,7 @@ public class MongoSlimeUtils { ...@@ -153,7 +153,7 @@ public class MongoSlimeUtils {
} }
public List<KylinTicketPartnerVo> getTicketPartnerVoList(String timesId) { public List<KylinTicketPartnerVo> getTicketPartnerVoList(String timesId) {
return mongoTemplate.find(Query.query(Criteria.where("timesId").is(timesId)), KylinTicketPartnerVo.class, KylinTicketPartnerVo.class.getSimpleName()); return mongoTemplate.find(Query.query(Criteria.where("timesId").is(timesId)).with(Sort.by(Sort.Direction.ASC, "createdAt")), KylinTicketPartnerVo.class, KylinTicketPartnerVo.class.getSimpleName());
} }
public void updatePerformancePartnerVoById(PerformancePartnerVo data) { public void updatePerformancePartnerVoById(PerformancePartnerVo data) {
......
...@@ -367,7 +367,7 @@ public class PerformanceUtils { ...@@ -367,7 +367,7 @@ public class PerformanceUtils {
tickets.setUseEnd(LocalDateTime.parse(ticketTimeItem.getUseEnd(), DTF_YMD_HMS)); tickets.setUseEnd(LocalDateTime.parse(ticketTimeItem.getUseEnd(), DTF_YMD_HMS));
tickets.setSaleRemindMinute(60); tickets.setSaleRemindMinute(60);
tickets.setAdvanceMinuteMember(5); tickets.setAdvanceMinuteMember(5);
tickets.setCreatedAt(LocalDateTime.parse(ticketTimeItem.getCreatedAt(), DTF_YMD_HMS)); tickets.setCreatedAt(LocalDateTime.parse(kylinTicketPartnerVo.getCreatedAt(), DTF_YMD_HMS));
tickets.setUpdatedAt(updatedAt); tickets.setUpdatedAt(updatedAt);
ticketStatus.setTicketStatusId(IDGenerator.nextSnowId()); ticketStatus.setTicketStatusId(IDGenerator.nextSnowId());
ticketStatus.setTicketId(tickets.getTicketsId()); ticketStatus.setTicketId(tickets.getTicketsId());
......
...@@ -2,6 +2,7 @@ package com.liquidnet.service.service.impl; ...@@ -2,6 +2,7 @@ package com.liquidnet.service.service.impl;
import com.liquidnet.commons.lang.util.CollectionUtil; import com.liquidnet.commons.lang.util.CollectionUtil;
import com.liquidnet.commons.lang.util.CurrentUtil; import com.liquidnet.commons.lang.util.CurrentUtil;
import com.liquidnet.commons.lang.util.IDCard;
import com.liquidnet.service.base.ResponseDto; import com.liquidnet.service.base.ResponseDto;
import com.liquidnet.service.base.SqlMapping; import com.liquidnet.service.base.SqlMapping;
import com.liquidnet.service.base.constant.MQConst; import com.liquidnet.service.base.constant.MQConst;
...@@ -110,6 +111,10 @@ public class SmileVolunteerServerImpl implements SmileVolunteersService { ...@@ -110,6 +111,10 @@ public class SmileVolunteerServerImpl implements SmileVolunteersService {
if (smileRedisUtils.getProjectIdCard(param.getProjectId(), param.getIdCard()) != null) { if (smileRedisUtils.getProjectIdCard(param.getProjectId(), param.getIdCard()) != null) {
return ResponseDto.failure("该证件已经报名"); return ResponseDto.failure("该证件已经报名");
} }
int age = IDCard.getAgeByIdCard(param.getIdCard());
if (age < 18) {
return ResponseDto.failure("招募对象为年满18岁的成年公民");
}
if (!utils.validate(param.getName(), param.getIdCard())) { if (!utils.validate(param.getName(), param.getIdCard())) {
return ResponseDto.failure("验证身份证失败!"); return ResponseDto.failure("验证身份证失败!");
......
...@@ -60,6 +60,7 @@ public class SweetPerformanceServiceImpl extends ServiceImpl<SweetPerformanceMap ...@@ -60,6 +60,7 @@ public class SweetPerformanceServiceImpl extends ServiceImpl<SweetPerformanceMap
show.setPicTwo(picTwo); show.setPicTwo(picTwo);
show.setArUrl(arUrl); show.setArUrl(arUrl);
show.setArName(arName); show.setArName(arName);
show.setStatus(0);
show.setOfflineUrl(offlineUrl); show.setOfflineUrl(offlineUrl);
show.setFileSize(fileSize); show.setFileSize(fileSize);
show.setTimeStart(LocalDateTime.parse(timeStart,DTF_YMD_HMS)); show.setTimeStart(LocalDateTime.parse(timeStart,DTF_YMD_HMS));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment