|
@@ -335,10 +335,10 @@ public class MeterTreeController extends BladeController {
|
|
String redisKey = "meter:project:refresh-tree:" + projectId;
|
|
String redisKey = "meter:project:refresh-tree:" + projectId;
|
|
String redisValue = bladeRedis.get(redisKey);
|
|
String redisValue = bladeRedis.get(redisKey);
|
|
if (StringUtils.isNotEmpty(redisValue) && redisValue.equals("1")) {
|
|
if (StringUtils.isNotEmpty(redisValue) && redisValue.equals("1")) {
|
|
- return R.fail(400, "请勿重复提交,60秒后再尝试");
|
|
|
|
|
|
+ return R.fail(400, "请勿重复提交,30秒后再尝试");
|
|
}
|
|
}
|
|
bladeRedis.set(redisKey, "1");
|
|
bladeRedis.set(redisKey, "1");
|
|
- bladeRedis.expire(redisKey, 60);
|
|
|
|
|
|
+ bladeRedis.expire(redisKey, 30);
|
|
|
|
|
|
/*初始化 或 增量同步 项目计量树*/
|
|
/*初始化 或 增量同步 项目计量树*/
|
|
return meterTreeProjectService.projectTreeInitOrSync(projectInfo.getMeterTemplateId(), Long.parseLong(projectId));
|
|
return meterTreeProjectService.projectTreeInitOrSync(projectInfo.getMeterTemplateId(), Long.parseLong(projectId));
|
|
@@ -531,10 +531,10 @@ public class MeterTreeController extends BladeController {
|
|
String redisKey = "meter:contract:refresh-tree:" + projectId + "_" + contractId;
|
|
String redisKey = "meter:contract:refresh-tree:" + projectId + "_" + contractId;
|
|
String redisValue = bladeRedis.get(redisKey);
|
|
String redisValue = bladeRedis.get(redisKey);
|
|
if (StringUtils.isNotEmpty(redisValue) && redisValue.equals("1")) {
|
|
if (StringUtils.isNotEmpty(redisValue) && redisValue.equals("1")) {
|
|
- return R.fail(400, "请勿重复提交,60秒后再尝试");
|
|
|
|
|
|
+ return R.fail(400, "请勿重复提交,30秒后再尝试");
|
|
}
|
|
}
|
|
bladeRedis.set(redisKey, "1");
|
|
bladeRedis.set(redisKey, "1");
|
|
- bladeRedis.expire(redisKey, 60);
|
|
|
|
|
|
+ bladeRedis.expire(redisKey, 30);
|
|
|
|
|
|
/*首先判断是否存在项目树*/
|
|
/*首先判断是否存在项目树*/
|
|
MeterTreeProject rootNode = meterTreeProjectService.getBaseMapper().selectOne(Wrappers.<MeterTreeProject>lambdaQuery()
|
|
MeterTreeProject rootNode = meterTreeProjectService.getBaseMapper().selectOne(Wrappers.<MeterTreeProject>lambdaQuery()
|