|
@@ -2,6 +2,7 @@ package com.boman.web.core.controller;
|
|
|
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
import com.boman.common.core.utils.obj.ObjectUtils;
|
|
|
+import com.boman.domain.Czrk;
|
|
|
import com.boman.domain.VaccineInfoOperation;
|
|
|
import com.boman.domain.dto.AjaxResult;
|
|
|
import com.boman.web.core.mapper.StandardlyMapper;
|
|
@@ -11,10 +12,8 @@ import com.boman.web.core.service.vaccineInfo.impl.VaccineInfoServiceImpl;
|
|
|
import com.boman.web.core.utils.IdUtils;
|
|
|
import com.google.common.base.Strings;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
-import org.springframework.web.bind.annotation.GetMapping;
|
|
|
-import org.springframework.web.bind.annotation.PathVariable;
|
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
|
+import org.checkerframework.checker.units.qual.C;
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
import java.io.BufferedWriter;
|
|
@@ -34,7 +33,7 @@ public class TestController {
|
|
|
private VaccineInfoMapper mapper;
|
|
|
|
|
|
@GetMapping("/handleData")
|
|
|
- public AjaxResult handleData(){
|
|
|
+ public AjaxResult handleData() {
|
|
|
List<VaccineInfoOperation> list = mapper.handleData();
|
|
|
for (VaccineInfoOperation vaccineInfoOperation : list) {
|
|
|
if (Objects.isNull(vaccineInfoOperation.getAge()) && ObjectUtils.isEmpty(vaccineInfoOperation.getBirthday())) {
|
|
@@ -73,4 +72,34 @@ public class TestController {
|
|
|
return new AjaxResult();
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * 处理常驻人口数据
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ @PostMapping("/setCzrksetCzrk")
|
|
|
+ public AjaxResult setCzrk() {
|
|
|
+ //587731
|
|
|
+ for (int i = 0; i < 59; i++) {
|
|
|
+ int startPage = i*10000;
|
|
|
+ int endPage = 10000;
|
|
|
+ List<VaccineInfoOperation> vaccineInfoOperations = mapper.selectVaccineInfoListByPage(startPage, endPage);
|
|
|
+ if (vaccineInfoOperations.size() > 0){
|
|
|
+ for (VaccineInfoOperation vaccineInfoOperation : vaccineInfoOperations) {
|
|
|
+ Czrk czrk = new Czrk();
|
|
|
+ czrk.setUserName(vaccineInfoOperation.getUserName());
|
|
|
+ czrk.setGender(vaccineInfoOperation.getGender());
|
|
|
+ czrk.setAge(vaccineInfoOperation.getAge());
|
|
|
+ czrk.setBirthday(vaccineInfoOperation.getBirthday());
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ return AjaxResult.success();
|
|
|
+ }
|
|
|
+
|
|
|
+ public static void main(String[] args) {
|
|
|
+
|
|
|
+ }
|
|
|
}
|