diff --git a/src/main/java/com/loafle/bridge/discoveryport/DiscoveryPortController.java b/src/main/java/com/loafle/bridge/discoveryport/DiscoveryPortController.java index 47523f4..08ed111 100644 --- a/src/main/java/com/loafle/bridge/discoveryport/DiscoveryPortController.java +++ b/src/main/java/com/loafle/bridge/discoveryport/DiscoveryPortController.java @@ -6,6 +6,8 @@ import com.loafle.bridge.discoveryhost.DiscoveryHost; import com.loafle.bridge.discoveryport.type.PortType; import com.loafle.bridge.discoveryservice.DiscoveryService; import com.loafle.bridge.discoveryzone.DiscoveryZone; +import com.loafle.bridge.discoveryzone.HostScanHistory; +import com.loafle.bridge.discoveryzone.ResultType; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestMapping; @@ -64,7 +66,21 @@ public class DiscoveryPortController { z.setIp(Long.parseLong(ip)); d.setZone(z); + // host scan histories + List hostScanHistories = new ArrayList(); + for( int indexI = 0 ; indexI < 5; ++indexI) { + HostScanHistory hostScanHistory = new HostScanHistory(); + hostScanHistory.setIp(Long.parseLong(ip)); + hostScanHistory.setCreateDate(new Date()); + hostScanHistory.setSendDate(new Date()); + hostScanHistory.setResultDate(new Date()); + hostScanHistory.setDescription("hgihihihih"); + hostScanHistory.setResultType(ResultType.Success); + hostScanHistory.setZone(z); + hostScanHistories.add(hostScanHistory); + } + z.setHostScanHistories(hostScanHistories); List hl = new ArrayList<>();