| | |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import java.net.URISyntaxException; |
| | | import java.util.Date; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | |
| | | * @return |
| | | */ |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public LedV2RegisterResultEntity validateSN(String sn) { |
| | | public LedV2RegisterResultEntity validateSN(String name,String sn) throws URISyntaxException { |
| | | LedV2RegisterResultEntity ledV2RegisterResultEntity = new LedV2RegisterResultEntity(); |
| | | |
| | | // 判断数据库是否存在,若不存在,判断是否已经注册到Vnnox服务器 |
| | |
| | | } |
| | | |
| | | Integer page = 0; |
| | | Integer limit = 200; |
| | | Integer limit = 100; |
| | | List<VnnoxPlayerResponse> playerList; |
| | | // 获取Vnnox服务器列表 |
| | | VnnoxPlayerListResponse response = vnnoxAPIUtil.getPlayerList(limit, page); |
| | | VnnoxPlayerListResponse response = vnnoxAPIUtil.getPlayerList(limit, page,name); |
| | | playerList = response.getRows(); |
| | | Integer total = response.getTotal() - limit; |
| | | while (total > 0) { |
| | | page = page + 1; |
| | | total = total - limit; |
| | | response = vnnoxAPIUtil.getPlayerList(limit, page); |
| | | response = vnnoxAPIUtil.getPlayerList(limit, page,name); |
| | | playerList.addAll(response.getRows()); |
| | | } |
| | | ledPlayerEntity = new LedPlayerEntity(); |