@Autowired
private UserCountService userCountService;
@Test
void test1() throws IOException {
String path = "D:/src/管理端用户数.txt";
Files.lines(Paths.get(path), StandardCharsets.UTF_8)
.forEach(line -> {
String[] split = line.split("\t");
System.out.println(split[0] + Double.parseDouble(split[2]));
userCountService.updateManagementUserCount("202311", split[0], Double.parseDouble(split[2]));
});
}
@Test
void test2() throws IOException {
String path = "D:/src/客户端用户数.txt";
Files.lines(Paths.get(path), StandardCharsets.UTF_8)
.forEach(line -> {
String[] split = line.split("\t");
System.out.println(split[0] + Double.parseDouble(split[1]));
userCountService.updateCustomerUserCount("202311", split[0], Double.parseDouble(split[1]));
});
}