|
|
|
@ -212,4 +212,30 @@ public class IcdFileConfigServiceImpl implements IcdFileConfigService {
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public void generateParamindex() throws Exception {
|
|
|
|
|
List<IcdConfigType> typeLIst = configRepository.findAll();
|
|
|
|
|
for (IcdConfigType type : typeLIst) {
|
|
|
|
|
List<IcdConfigTypeInst> instList = instRepository.findByIcdConfigTypeId(type.getId());
|
|
|
|
|
List<IcdConfigTypeAtt> attList = attRepository.findByIcdConfigTypeId(type.getId());
|
|
|
|
|
for (IcdConfigTypeInst inst : instList) {
|
|
|
|
|
String param = type.getIedName() + type.getLdeviceInst() + "/" + type.getLnClass()
|
|
|
|
|
+ inst.getInst();
|
|
|
|
|
for (IcdConfigTypeAtt att : attList) {
|
|
|
|
|
if (att.containInst(inst.getInst())) {
|
|
|
|
|
String paramindex = param + "$" + att.getParam();
|
|
|
|
|
List<Rptparamindex> rptList = rptparamindexRepository.findAllByParamindexEquals(paramindex);
|
|
|
|
|
if (CollectionUtils.isEmpty(rptList)) {
|
|
|
|
|
Rptparamindex rpt = Rptparamindex.builder()
|
|
|
|
|
.paramindex(paramindex)
|
|
|
|
|
.objid(0)
|
|
|
|
|
.build();
|
|
|
|
|
rptparamindexRepository.save(rpt);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|