refactor(video): 移除模板占位符检查逻辑
All checks were successful
ZhenTu-BE/pipeline/head This commit looks good

- 删除了模板占位符验证相关代码
- 简化了设备计数逻辑
- 移除了不必要的模板占位符列表操作
This commit is contained in:
2026-02-24 17:07:16 +08:00
parent 47ae60b203
commit f87a4f2311

View File

@@ -91,17 +91,13 @@ public class VideoTaskRepository {
return 1;
}
AtomicInteger deviceCount = new AtomicInteger();
List<String> templatePlaceholder = templateRepository.getTemplatePlaceholder(task.getTemplateId());
paramJson.entrySet().stream()
.filter(entry -> StringUtils.isNumeric(entry.getKey()))
.forEach(entry -> {
List<Object> jsonArray = JacksonUtil.parseArray(JacksonUtil.toJSONString(entry.getValue()), Object.class);
if (jsonArray != null && !jsonArray.isEmpty()) {
for (Object ignored : jsonArray) {
if (templatePlaceholder.contains(entry.getKey())) {
deviceCount.getAndIncrement();
templatePlaceholder.remove(entry.getKey());
}
}
}
});