|
@@ -36,7 +36,9 @@ import org.springframework.stereotype.Service;
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
|
import java.time.LocalDateTime;
|
|
|
+import java.util.HashMap;
|
|
|
import java.util.List;
|
|
|
+import java.util.Map;
|
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
/**
|
|
@@ -95,6 +97,8 @@ public class GameBackPolicyServiceImpl extends ServiceImpl<GameBackPolicyMapper,
|
|
|
|
|
|
String actionType = gameTencentOrder.getOrderStatus().equals(PURCHASE) ?
|
|
|
ActionTypeEnum.PURCHASE.getActionType() : ActionTypeEnum.COMPLETE_ORDER.getActionType();
|
|
|
+ Map<String, Object> actionParam = new HashMap<>(2);
|
|
|
+ actionParam.put("claim_type", 0);
|
|
|
DataReportOfAppIdRpcDTO dataReportOfAppIdRpcDTO = DataReportOfAppIdRpcDTO.builder()
|
|
|
.appId(dto.getWechatAppId())
|
|
|
.userActionSetId(dto.getUserActionSetId())
|
|
@@ -105,6 +109,7 @@ public class GameBackPolicyServiceImpl extends ServiceImpl<GameBackPolicyMapper,
|
|
|
.wechatAppId(dto.getWechatAppId())
|
|
|
.wechatOpenid(dto.getWechatOpenid())
|
|
|
.build())
|
|
|
+ .actionParam(actionParam)
|
|
|
.build())
|
|
|
.build();
|
|
|
|
|
@@ -141,8 +146,10 @@ public class GameBackPolicyServiceImpl extends ServiceImpl<GameBackPolicyMapper,
|
|
|
ResultVO<Boolean> result = userActionSetRpc.reportByAppId(dataReportOfAppIdRpcDTO);
|
|
|
if (result.getCode() == HttpStatus.HTTP_OK) {
|
|
|
gameTencentOrder.setIsBack(BackStatusEnum.FAILED.getBackStatus());
|
|
|
+ gameTencentOrder.setBackLog("回传成功");
|
|
|
gameTencentOrderService.updateById(gameTencentOrder);
|
|
|
|
|
|
+ gameTencentBackLog.setBackLog("回传成功");
|
|
|
gameTencentBackLogService.save(gameTencentBackLog);
|
|
|
} else {
|
|
|
log.error("回传腾讯订单失败,失败原因:{}", result.getMsg());
|
|
@@ -184,6 +191,8 @@ public class GameBackPolicyServiceImpl extends ServiceImpl<GameBackPolicyMapper,
|
|
|
.build();
|
|
|
gameTencentUserService.save(gameTencentUser);
|
|
|
}
|
|
|
+ Map<String, Object> actionParam = new HashMap<>(2);
|
|
|
+ actionParam.put("claim_type", 0);
|
|
|
|
|
|
DataReportOfAppIdRpcDTO dataReportOfAppIdRpcDTO = DataReportOfAppIdRpcDTO.builder()
|
|
|
.appId(dto.getWechatAppId())
|
|
@@ -195,6 +204,7 @@ public class GameBackPolicyServiceImpl extends ServiceImpl<GameBackPolicyMapper,
|
|
|
.wechatAppId(dto.getWechatAppId())
|
|
|
.wechatOpenid(dto.getWechatOpenid())
|
|
|
.build())
|
|
|
+ .actionParam(actionParam)
|
|
|
.build())
|
|
|
.build();
|
|
|
|
|
@@ -211,8 +221,10 @@ public class GameBackPolicyServiceImpl extends ServiceImpl<GameBackPolicyMapper,
|
|
|
ResultVO<Boolean> result = userActionSetRpc.reportByAppId(dataReportOfAppIdRpcDTO);
|
|
|
if (result.getCode() == HttpStatus.HTTP_OK) {
|
|
|
gameTencentUser.setIsBack(BackStatusEnum.SUCCESS.getBackStatus());
|
|
|
+ gameTencentUser.setBackLog("回传成功");
|
|
|
gameTencentUserService.updateById(gameTencentUser);
|
|
|
|
|
|
+ gameTencentBackLog.setBackLog("回传成功");
|
|
|
gameTencentBackLogService.save(gameTencentBackLog);
|
|
|
} else {
|
|
|
log.error("回传腾讯用户失败,失败原因:{}", result.getMsg());
|