pipIrr-platform/pipIrr-web/pipIrr-web-project/src/main/java/com/dy/pipIrrProject/video/CameraCtrl.java
@@ -44,8 +44,6 @@ this.sv = sv ; } @Value("${video.types}") private String[] types; /** * 客户端请求得到所有摄像机类型 * @return 所有摄像机类型 @@ -64,8 +62,8 @@ public BaseResponse<QueryResultVo<List<TypesVo>>> types() { try { List<TypesVo> list = new ArrayList<>() ; if(types != null && types.length > 0){ for (String type : types) { if(CameraTypesConfig.types != null && CameraTypesConfig.types.size() > 0){ for (String type : CameraTypesConfig.types) { String[] typeGrp = type.split(","); if(typeGrp.length == 2){ TypesVo vo = new TypesVo() ; pipIrr-platform/pipIrr-web/pipIrr-web-project/src/main/java/com/dy/pipIrrProject/video/CameraTypesConfig.java
New file @@ -0,0 +1,27 @@ package com.dy.pipIrrProject.video; import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.context.annotation.Configuration; import java.util.List; /** * @Author: liurunyu * @Date: 2025/6/9 14:21 * @Description */ @Configuration @ConfigurationProperties(prefix = "video") public class CameraTypesConfig { public static List<String> types; public List<String> getTypes(){ return types; } public void setTypes(List<String> types){ CameraTypesConfig.types = types ; } }