diff --git a/renren-admin/src/main/java/io/renren/modules/resource/controller/CIMController.java b/renren-admin/src/main/java/io/renren/modules/resource/controller/CIMController.java new file mode 100644 index 00000000..d8729b81 --- /dev/null +++ b/renren-admin/src/main/java/io/renren/modules/resource/controller/CIMController.java @@ -0,0 +1,30 @@ +package io.renren.modules.resource.controller; + +import io.renren.modules.resource.service.CIMService; +import io.renren.modules.sys.service.SysDeptService; +import io.swagger.annotations.Api; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +/** + * 资源表 + * + * @author dg + * @since 1.0 2022-04-13 + */ +@RestController +@RequestMapping("/resource") +@Api(tags = "资源表") +public class CIMController { + + private static final Logger logger = LoggerFactory.getLogger(ResourceController.class); + + @Autowired + private io.renren.modules.resource.service.CIMService CIMService; + + @Autowired + private SysDeptService sysDeptService; +} diff --git a/renren-admin/src/main/java/io/renren/modules/resource/service/CIMService.java b/renren-admin/src/main/java/io/renren/modules/resource/service/CIMService.java new file mode 100644 index 00000000..f8df6b10 --- /dev/null +++ b/renren-admin/src/main/java/io/renren/modules/resource/service/CIMService.java @@ -0,0 +1,4 @@ +package io.renren.modules.resource.service; + +public interface CIMService { +} diff --git a/renren-admin/src/main/java/io/renren/modules/resource/service/impl/CIMServiceImpl.java b/renren-admin/src/main/java/io/renren/modules/resource/service/impl/CIMServiceImpl.java new file mode 100644 index 00000000..a7be7bdf --- /dev/null +++ b/renren-admin/src/main/java/io/renren/modules/resource/service/impl/CIMServiceImpl.java @@ -0,0 +1,8 @@ +package io.renren.modules.resource.service.impl; + +import io.renren.modules.resource.service.CIMService; +import org.springframework.stereotype.Service; + +@Service +public class CIMServiceImpl implements CIMService { +} diff --git a/renren-admin/src/main/java/io/renren/modules/resource/service/impl/ResourceServiceImpl.java b/renren-admin/src/main/java/io/renren/modules/resource/service/impl/ResourceServiceImpl.java index ed7354a2..09970282 100644 --- a/renren-admin/src/main/java/io/renren/modules/resource/service/impl/ResourceServiceImpl.java +++ b/renren-admin/src/main/java/io/renren/modules/resource/service/impl/ResourceServiceImpl.java @@ -307,13 +307,13 @@ public class ResourceServiceImpl extends CrudServiceImpl attrEntities = dto.getInfoList(); - List attrEntities_ = new ArrayList<>(); + List attrEntityList = new ArrayList<>(); if (attrEntities != null) { attrEntities.forEach(item -> { item.setDelFlag(ResourceEntityDelFlag.NORMAL.getFlag()); item.setDataResourceId(resourceID); attrDao.insert(item); - attrEntities_.add(item); + attrEntityList.add(item); }); } for (AttrEntity attrEntity : resourceEntity.getInfoList()) { @@ -321,7 +321,6 @@ public class ResourceServiceImpl extends CrudServiceImpl carEntities = resourceCarDao.selectByMap(selectMap); - //TODO: 固定资源id改为配置文件 - if (carEntities.isEmpty() || dto.getResourceId() == 8888888880000000001L) { + if (carEntities.isEmpty() || dto.getResourceId() == Constant.CEMERALISTID) { ResourceCarEntity carEntity = new ResourceCarEntity(); dto.setUserId(userId); BeanUtils.copyProperties(dto, carEntity); diff --git a/renren-common/src/main/java/io/renren/common/constant/Constant.java b/renren-common/src/main/java/io/renren/common/constant/Constant.java index 0aa7039f..b5a5402a 100644 --- a/renren-common/src/main/java/io/renren/common/constant/Constant.java +++ b/renren-common/src/main/java/io/renren/common/constant/Constant.java @@ -94,6 +94,10 @@ public interface Constant { * 代码生成参数KEY */ String DEV_TOOLS_PARAM_KEY = "DEV_TOOLS_PARAM_KEY"; + /** + * 将视频资源申请全部视为一个特殊能力,使用此ID + */ + Long CEMERALISTID = 8888888880000000001L; /** * 定时任务状态