| | |
| | | import org.springframework.retry.backoff.Sleeper; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | import java.util.function.BiConsumer; |
| | | import java.util.function.Consumer; |
| | |
| | | List<User> users = userService.getNotAuditAllUserList(); |
| | | //遍历 |
| | | users.forEach(InvestigateUtil.consumerWithIndex((user,index) ->{ |
| | | if (null!=user.getCardid() && user.getCardid()!="") { |
| | | if (null!=user.getCardid() && !user.getCardid().equals("")) { |
| | | if (index == 1000) { |
| | | try { |
| | | Thread.sleep(1000); |
| | |
| | | Object data = jsonObject.get("data"); |
| | | JSONObject jsonData = new JSONObject(data.toString()); |
| | | JSONArray res = jsonData.getJSONArray("res"); |
| | | //设置审核时间 |
| | | user.setAuditTime(new Date()); |
| | | if (res.length() == 0) { |
| | | //没有数据正常 |
| | | user.setExaminationType("0"); |