update 广播信息中英翻译功能,用户个人中心apikey失效修改问题

This commit is contained in:
yyb
2025-07-02 16:18:06 +08:00
parent 5a8e59336a
commit c698a8244c
17 changed files with 504 additions and 61 deletions

View File

@@ -516,7 +516,11 @@ public class UserMinerServiceImpl implements UserMinserService {
}
}
int count = uaMapper.getApiKeyCountByUser(user);
List<UserApi> list = uaMapper.getAPIListByUser(user);
long count = list.stream().filter(e -> {
OpenApiKeyInfo openApiKeyInfo = openApiService.getOpenApiKeyInfo(e.getKey());
return openApiKeyInfo != null;
}).count();
if(count >= 5){
return AjaxResult.error("apiKey创建次数已达上限5");
}
@@ -576,7 +580,10 @@ public class UserMinerServiceImpl implements UserMinserService {
return null;
}
List<UserApi> list = uaMapper.getAPIListByUser(user);
List<UserApiDto> returnList = list.stream().map(e -> {
List<UserApiDto> returnList = list.stream().filter(e -> {
OpenApiKeyInfo openApiKeyInfo = openApiService.getOpenApiKeyInfo(e.getKey());
return openApiKeyInfo != null;
}).map(e -> {
UserApiDto dto = new UserApiDto();
BeanUtils.copyProperties(e,dto);
if(StringUtils.isNull(e.getPerms())){
@@ -661,8 +668,9 @@ public class UserMinerServiceImpl implements UserMinserService {
}
OpenApiKeyInfo info = openApiService.getOpenApiKeyInfo(userApi.getKey());
System.out.println("info:"+info);
boolean result = uaMapper.updateApiKey(vo,user);
if(result){
info.setApiIp(vo.getIp());
info.setPermissions(permsSet);

View File

@@ -48,7 +48,7 @@ public class DataTask {
private static final Logger log = LoggerFactory.getLogger(DataTask.class);
@Scheduled(cron = "20 1,3,10,31,33,40 * * * ?")
@Scheduled(cron = "20 1,3,10,31,33,40 * * * ?")
public void NEXA30mDataToDB(){
//String nowStr = DateUtils.dateTimeNow("yyyy-MM-dd HH:mm:00");
@@ -227,7 +227,7 @@ public class DataTask {
}
@Scheduled(cron = "0 1,3,5 0 * * ?")
@Scheduled(cron = "0 1,3,5 0 * * ?")
public void NEXADailyDataToDB(){
String nowStr = DateUtils.dateTimeNow(DateUtils.YYYY_MM_DD);
Date now = DateUtils.parseDate( nowStr);
@@ -379,7 +379,7 @@ public class DataTask {
}
}
@Scheduled(cron = "50 0,1,30,31 * * * ?")
@Scheduled(cron = "50 0,1,30,31 * * * ?")
public void NEXAUserPowerRatioDataToDB(){
//String nowStr = DateUtils.dateTimeNow("yyyy-MM-dd HH:mm:00");
@@ -405,7 +405,7 @@ public class DataTask {
@Scheduled(cron = "30 3 0/1 * * ?")
@Scheduled(cron = "30 3 0/1 * * ?")
//@Scheduled(cron = "0 0/2 * * * ?")
public void NEXALuckyDataToDB(){
log.info("nexa幸运值---定时任务开始");
@@ -497,7 +497,7 @@ public class DataTask {
}
@Scheduled(cron = "11 1,3,11,31,33,41 * * * ?")
@Scheduled(cron = "11 1,3,11,31,33,41 * * * ?")
public void GRS30mDataToDB(){
//String nowStr = DateUtils.dateTimeNow("yyyy-MM-dd HH:mm:00");
@@ -663,7 +663,7 @@ public class DataTask {
}
@Scheduled(cron = "1 1,3,5 0 * * ?")
@Scheduled(cron = "1 1,3,5 0 * * ?")
public void GRSDailyDataToDB(){
String nowStr = DateUtils.dateTimeNow(DateUtils.YYYY_MM_DD);
Date now = DateUtils.parseDate( nowStr);
@@ -816,7 +816,7 @@ public class DataTask {
}
}
@Scheduled(cron = "51 0,1,30,31 * * * ?")
@Scheduled(cron = "51 0,1,30,31 * * * ?")
public void GRSUserPowerRatioDataToDB(){
//String nowStr = DateUtils.dateTimeNow("yyyy-MM-dd HH:mm:00");
@@ -846,7 +846,7 @@ public class DataTask {
}
@Scheduled(cron = "31 3 0/1 * * ?")
@Scheduled(cron = "31 3 0/1 * * ?")
//@Scheduled(cron = "0 0/2 * * * ?")
public void GRSLuckyDataToDB(){
log.info("GRS幸运值---定时任务开始");
@@ -909,7 +909,7 @@ public class DataTask {
dto.getLuck3d(),dto.getLuck7d(),dto.getLuck30d(),dto.getLuck90d());;
}
@Scheduled(cron = "12 1,3,12,31,33,42 * * * ?")
@Scheduled(cron = "12 1,3,12,31,33,42 * * * ?")
public void MONA30mDataToDB(){
//String nowStr = DateUtils.dateTimeNow("yyyy-MM-dd HH:mm:00");
@@ -1072,7 +1072,7 @@ public class DataTask {
}
@Scheduled(cron = "2 1,3,5 0 * * ?")
@Scheduled(cron = "2 1,3,5 0 * * ?")
public void MONADailyDataToDB(){
String nowStr = DateUtils.dateTimeNow(DateUtils.YYYY_MM_DD);
Date now = DateUtils.parseDate( nowStr);
@@ -1227,7 +1227,7 @@ public class DataTask {
}
}
@Scheduled(cron = "52 0,1,30,31 * * * ?")
@Scheduled(cron = "52 0,1,30,31 * * * ?")
public void MONAUserPowerRatioDataToDB(){
//String nowStr = DateUtils.dateTimeNow("yyyy-MM-dd HH:mm:00");

View File

@@ -42,7 +42,7 @@ public class NeaxPriceTask {
private RedisService redisService;
//@Scheduled(cron = "0 0/1 * * * ?")
@Scheduled(cron = "0 0,3,30,33 * * * ?")
@Scheduled(cron = "0 0,3,30,33 * * * ?")
public void NEXAPriceToRedis()
{
Map<String, BigDecimal> map = getResultFromNetByAllCoins();