|
@@ -3,10 +3,13 @@ package com.kexun.controller;
|
|
|
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
+import com.github.pagehelper.PageHelper;
|
|
|
+import com.github.pagehelper.PageInfo;
|
|
|
import com.kexun.common.utils.Result;
|
|
|
import com.kexun.entity.BusInfoModifyHis;
|
|
|
import com.kexun.entity.CooperatorInfo;
|
|
|
import com.kexun.entity.FieldDefineEntity;
|
|
|
+import com.kexun.entity.FieldTemplateEntity;
|
|
|
import com.kexun.hander.PageBean;
|
|
|
import com.kexun.model.ro.FiledRO;
|
|
|
import com.kexun.model.ro.FiledUpdateRO;
|
|
@@ -19,6 +22,8 @@ import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import java.util.Iterator;
|
|
|
import java.util.List;
|
|
|
+import java.util.Objects;
|
|
|
+import java.util.stream.Collectors;
|
|
|
|
|
|
/**
|
|
|
* <p>
|
|
@@ -39,15 +44,72 @@ public class FieldDefineController {
|
|
|
*
|
|
|
* @return
|
|
|
*/
|
|
|
- @GetMapping("fieldListNew")
|
|
|
- public Result fieldListNew() {
|
|
|
- JSONObject resJson=new JSONObject();
|
|
|
- List<FieldDefineEntity> list= fieldDefineService.list();
|
|
|
- resJson.put("fieldListNew",list);
|
|
|
+// @GetMapping("fieldListNew")
|
|
|
+// public Result fieldListNew() {
|
|
|
+// JSONObject resJson=new JSONObject();
|
|
|
+// List<FieldDefineEntity> list= fieldDefineService.list();
|
|
|
+// resJson.put("fieldListNew",list);
|
|
|
+//
|
|
|
+// return Result.success("ok",resJson);
|
|
|
+// }
|
|
|
|
|
|
- return Result.success("ok",resJson);
|
|
|
+ @RequestMapping("/fieldListNew")
|
|
|
+ @ResponseBody
|
|
|
+ public Result findAll(@RequestParam int pageNum){
|
|
|
+ int pageSize = 10;
|
|
|
+ PageHelper.startPage(pageNum, pageSize);//设置分页信息
|
|
|
+ List<FieldDefineEntity> list = fieldDefineService.selectPage();
|
|
|
+
|
|
|
+ List<FieldDefineEntity> list2 = fieldDefineService.selectPage2();
|
|
|
+
|
|
|
+ PageInfo pageInfo=new PageInfo(list);
|
|
|
+ PageInfo pageInfo2=new PageInfo(list2);
|
|
|
+
|
|
|
+ System.out.println(pageInfo);
|
|
|
+ JSONObject resJson = new JSONObject();
|
|
|
+
|
|
|
+ resJson.put("fieldListNew", pageInfo);
|
|
|
+
|
|
|
+
|
|
|
+ resJson.put("fieldListDerive", pageInfo2);
|
|
|
+
|
|
|
+ return Result.success("ok", resJson);
|
|
|
}
|
|
|
|
|
|
+ @RequestMapping("/fieldListBase")
|
|
|
+ @ResponseBody
|
|
|
+ public Result fieldListBase(@RequestParam int pageNum){
|
|
|
+ int pageSize = 10;
|
|
|
+ PageHelper.startPage(pageNum, pageSize);//设置分页信息
|
|
|
+ List<FieldDefineEntity> list = fieldDefineService.selectPage();
|
|
|
+
|
|
|
+ PageInfo pageInfo=new PageInfo(list);
|
|
|
+
|
|
|
+ System.out.println(pageInfo);
|
|
|
+ JSONObject resJson = new JSONObject();
|
|
|
+ resJson.put("fieldListBase", pageInfo);
|
|
|
+
|
|
|
+
|
|
|
+ return Result.success("ok", resJson);
|
|
|
+ }
|
|
|
+
|
|
|
+ @RequestMapping("/fieldListDerive")
|
|
|
+ @ResponseBody
|
|
|
+ public Result fieldListDerive(@RequestParam int pageNum){
|
|
|
+ int pageSize = 10;
|
|
|
+ PageHelper.startPage(pageNum, pageSize);//设置分页信息
|
|
|
+
|
|
|
+ List<FieldDefineEntity> list2 = fieldDefineService.selectPage2();
|
|
|
+
|
|
|
+ PageInfo pageInfo2=new PageInfo(list2);
|
|
|
+
|
|
|
+ System.out.println(pageInfo2);
|
|
|
+ JSONObject resJson = new JSONObject();
|
|
|
+
|
|
|
+ resJson.put("fieldListDerive", pageInfo2);
|
|
|
+
|
|
|
+ return Result.success("ok", resJson);
|
|
|
+ }
|
|
|
/**
|
|
|
* 字段列表查询
|
|
|
*
|