|
@@ -10,6 +10,7 @@ import com.fdkankan.manage_jp.config.FyunConfig;
|
|
|
import com.fdkankan.manage_jp.exception.BusinessException;
|
|
|
import com.fdkankan.manage_jp.httpClient.client.FdKKClient;
|
|
|
import com.fdkankan.manage_jp.httpClient.param.UploadEditSceneParam;
|
|
|
+import com.fdkankan.redis.util.RedisUtil;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
@@ -105,11 +106,19 @@ public class UploadController extends BaseController{
|
|
|
return Result.success(map);
|
|
|
}
|
|
|
|
|
|
+ @Autowired
|
|
|
+ RedisUtil redisUtil;
|
|
|
@PostMapping("/relevanceE57")
|
|
|
public Result relevanceE57( @RequestParam(value = "isObj",required = false)Integer isObj,
|
|
|
@RequestParam(value = "title",required = false)String title,
|
|
|
@RequestParam(value = "newFileName",required = false)String newFileName ){
|
|
|
|
|
|
+ String redisKey = "manage:e57:create:lock:"+ newFileName;
|
|
|
+ if(redisUtil.hasKey(redisKey)){
|
|
|
+ throw new BusinessException(ResultCode.REPEAT_ERROR);
|
|
|
+ }
|
|
|
+ redisUtil.set(redisKey,newFileName,48 * 60 * 60);
|
|
|
+
|
|
|
if(StringUtils.isBlank(newFileName)){
|
|
|
throw new BusinessException(ResultCode.PARAM_ERROR);
|
|
|
}
|