refactor(game): 更新 PGXBetHistoryResponse 和 PGXClient

- 将 PGXBetHistoryResponse 中的 int 类型改为 Long 类型
- 修改 PGXClient 中的 API 调用地址
main-KM
shi 2025-03-31 16:55:26 +08:00
parent d211dd2d7e
commit ed4c981ef7
2 changed files with 22 additions and 1 deletions

View File

@ -110,6 +110,11 @@ public interface PGXClient {
PGXBetHistoryResponse getBetRecordByTime(@Var("parameters") String parameters);
@Get(url = "http://fetch.336699bet.com/fetchArchieve.aspx?{parameters}")
PGXBetHistoryResponse getBetRecordByHistoryTime(@Var("parameters") String parameters);
/**
*
*

View File

@ -474,7 +474,23 @@ public class GamesPGXServiceImpl implements IGamesService {
*/
@Override
public Boolean getBetRecordByHistoryTime(BetRecordByTimeDTO betRecordByTimeDTO) {
return null;
//请求参数
log.info("GamesPGXServiceImpl [getBetRecordByHistoryTime] 请求参数 {}", betRecordByTimeDTO);
Map<String, Object> paramsMap = new LinkedHashMap<>();
paramsMap.put("operatorcode", betRecordByTimeDTO.getAgentId());
String key = this.getKey(paramsMap, betRecordByTimeDTO);
paramsMap.put("versionkey", 0);
paramsMap.put("signature", key);
PGXBetHistoryResponse betRecordByTime = PGXClient.getBetRecordByHistoryTime(JsonUtil.mapToQueryString(paramsMap));
if (this.getIsSuccess(betRecordByTime.getErrCode())) {
List<PGXBetHistoryResponse.Result> results = JSON.parseArray(betRecordByTime.getResult(), PGXBetHistoryResponse.Result.class);
this.batchInsert(results, betRecordByTimeDTO);
return Boolean.TRUE;
} else {
log.error("GamesPGXServiceImpl [getBetRecordByHistoryTime] 获取投注记录失败,错误代码{},错误信息{}", betRecordByTime.getErrCode(), betRecordByTime.getErrMsg());
throw new BaseException(betRecordByTime.getErrMsg());
}
}
/**