|
|
|
@ -7,9 +7,9 @@ import com.xydl.cac.entity.constants.Constants;
|
|
|
|
|
import com.xydl.cac.exception.BusinessException;
|
|
|
|
|
import com.xydl.cac.iec.IecServerService;
|
|
|
|
|
import com.xydl.cac.model.Response;
|
|
|
|
|
import com.xydl.cac.model.StaticVariable;
|
|
|
|
|
import com.xydl.cac.service.IcdFileConfigService;
|
|
|
|
|
import com.xydl.cac.service.IcdTransformService;
|
|
|
|
|
import com.xydl.cac.service.impl.IcdTransformServiceImpl;
|
|
|
|
|
import io.swagger.annotations.Api;
|
|
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
|
@ -128,11 +128,15 @@ public class IecServerController extends BasicController {
|
|
|
|
|
public Response<List<IcdTransform>> listTransform() throws Exception {
|
|
|
|
|
List<IcdTransform> result = transformService.listTransform();
|
|
|
|
|
for (IcdTransform item : result) {
|
|
|
|
|
if (IcdTransformServiceImpl.rptFromActiveMap.containsKey(item.getRptFrom())) {
|
|
|
|
|
if (StaticVariable.rptFromActiveMap.containsKey(item.getRptFrom())) {
|
|
|
|
|
item.setFromActive(true);
|
|
|
|
|
} else {
|
|
|
|
|
item.setFromActive(false);
|
|
|
|
|
}
|
|
|
|
|
if (IcdTransformServiceImpl.rptToActiveMap.containsKey(item.getRptTo())) {
|
|
|
|
|
if (StaticVariable.rptToActiveMap.containsKey(item.getRptTo())) {
|
|
|
|
|
item.setToActive(true);
|
|
|
|
|
} else {
|
|
|
|
|
item.setToActive(false);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return Response.success(result);
|
|
|
|
|