Browse Source

fix: 修复查询局址别名列表、查询局址编号列表、查询一房产一局址表接口错误

weijianghai 11 months ago
parent
commit
2f1e79131b
39 changed files with 2127 additions and 572 deletions
  1. 57 0
      src/main/java/com/example/common/PageVo.java
  2. 89 0
      src/main/java/com/example/common/Rsp.java
  3. 456 471
      src/main/java/com/example/controller/WzBuildManageDetailsController.java
  4. 30 30
      src/main/java/com/example/controller/WzHouseMaintenaCostController.java
  5. 29 29
      src/main/java/com/example/controller/WzLandManageDetailsController.java
  6. 33 0
      src/main/java/com/example/controller/house/HouseSiteStatController.java
  7. 18 2
      src/main/java/com/example/controller/house/HouseWzBuildManageDetailsController.java
  8. 22 4
      src/main/java/com/example/controller/house/HouseWzHouseMaintenaCostController.java
  9. 34 0
      src/main/java/com/example/controller/house/HouseWzLandManageDetailsController.java
  10. 21 0
      src/main/java/com/example/controller/house/HouseWzOtnAreaController.java
  11. 33 0
      src/main/java/com/example/dao/WzOtnAreaDao.java
  12. 142 0
      src/main/java/com/example/dao/house/HouseSiteStatDao.java
  13. 267 2
      src/main/java/com/example/entity/house/HouseBuildingPo.java
  14. 21 0
      src/main/java/com/example/entity/house/HouseSiteBuildingAreaIdleDiffPo.java
  15. 106 0
      src/main/java/com/example/entity/house/HouseSitePo.java
  16. 17 0
      src/main/java/com/example/entity/house/HouseSiteRepairInvestorStatPo.java
  17. 17 0
      src/main/java/com/example/entity/house/HouseSiteRepairMonthPo.java
  18. 1 1
      src/main/java/com/example/pojo/bo/ListBuildingIdleBo.java
  19. 27 0
      src/main/java/com/example/pojo/bo/ListHouseSiteBo.java
  20. 30 0
      src/main/java/com/example/pojo/dto/GetSiteStatDto.java
  21. 3 3
      src/main/java/com/example/pojo/dto/ListBuildingHighRepairDto.java
  22. 3 3
      src/main/java/com/example/pojo/dto/ListBuildingHighSporadicRepairDto.java
  23. 3 3
      src/main/java/com/example/pojo/dto/ListBuildingIdleDto.java
  24. 3 3
      src/main/java/com/example/pojo/dto/ListBuildingSameRepairFrequencyDto.java
  25. 34 0
      src/main/java/com/example/pojo/dto/ListSiteNameDto.java
  26. 34 0
      src/main/java/com/example/pojo/dto/ListSiteNumDto.java
  27. 53 0
      src/main/java/com/example/pojo/vo/GetSiteStatBuildingVo.java
  28. 109 0
      src/main/java/com/example/pojo/vo/GetSiteStatVo.java
  29. 1 1
      src/main/java/com/example/pojo/vo/ListBuildingIdleVo.java
  30. 1 1
      src/main/java/com/example/pojo/vo/ListBuildingSameRepairFrequencyVo.java
  31. 18 0
      src/main/java/com/example/pojo/vo/ListSiteNameVo.java
  32. 18 0
      src/main/java/com/example/pojo/vo/ListSiteNumVo.java
  33. 122 0
      src/main/java/com/example/service/house/HouseSiteStatService.java
  34. 58 6
      src/main/java/com/example/service/house/HouseWzBuildManageDetailsService.java
  35. 64 12
      src/main/java/com/example/service/house/HouseWzHouseMaintenaCostService.java
  36. 70 0
      src/main/java/com/example/service/house/HouseWzLandManageDetailsService.java
  37. 50 1
      src/main/java/com/example/service/house/HouseWzOtnAreaService.java
  38. 7 0
      src/main/java/com/example/utils/Page.java
  39. 26 0
      src/test/java/com/example/MybatisPlusGeneratorTest.java

+ 57 - 0
src/main/java/com/example/common/PageVo.java

@@ -0,0 +1,57 @@
+package com.example.common;
+
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.github.pagehelper.PageInfo;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+
+import java.util.List;
+
+/**
+ * 分页返回对象
+ */
+@Data
+public class PageVo<T> {
+    @Schema(description = "总记录数")
+    private Long totalCount;
+    @Schema(description = "每页记录数")
+    private Long pageSize;
+    @Schema(description = "总页数")
+    private Long totalPage;
+    @Schema(description = "当前页数")
+    private Long currPage;
+    @Schema(description = "列表数据")
+    private List<T> list;
+
+    public PageVo(List<T> list, Page page) {
+        this.list = list;
+        this.totalCount = page.getTotal();
+        this.pageSize = page.getSize();
+        this.currPage = page.getCurrent();
+        this.totalPage = page.getPages();
+    }
+
+    /**
+     * 分页
+     *
+     * @param list       列表数据
+     * @param totalCount 总记录数
+     * @param pageSize   每页记录数
+     * @param currPage   当前页数
+     */
+    public PageVo(List<T> list, int totalCount, int pageSize, int currPage) {
+        this.list = list;
+        this.totalCount = (long) totalCount;
+        this.pageSize = (long) pageSize;
+        this.currPage = (long) currPage;
+        this.totalPage = (long) Math.ceil((double) totalCount / pageSize);
+    }
+
+    public PageVo(PageInfo pageInfo) {
+        this.list = pageInfo.getList();
+        this.totalCount = pageInfo.getTotal();
+        this.pageSize = (long) pageInfo.getPageSize();
+        this.currPage = (long) pageInfo.getPageNum();
+        this.totalPage = (long) pageInfo.getPages();
+    }
+}

+ 89 - 0
src/main/java/com/example/common/Rsp.java

@@ -0,0 +1,89 @@
+package com.example.common;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import org.slf4j.MDC;
+
+/**
+ * 返回值的统一包装
+ */
+@Data
+public class Rsp<T> {
+    @Schema(description = "是否成功")
+    private Boolean success;
+    @Schema(description = "业务码")
+    private Integer code;
+    @Schema(description = "提示信息", example = "成功")
+    private String message;
+    @Schema(description = "数据")
+    private T page = null;
+
+    /**
+     * 私有化构造方法,不允许在外部实例化
+     */
+    private Rsp() {
+    }
+
+    /**
+     * 成功的静态方法
+     *
+     * @return R实例
+     */
+    public static <T> Rsp<T> ok() {
+        Rsp<T> r = new Rsp<>();
+        r.setSuccess(true);
+        r.setCode(0);
+        r.setMessage("成功");
+        return r;
+    }
+
+    public static <T> Rsp<T> ok(T data) {
+        Rsp<T> r = new Rsp<>();
+        r.setSuccess(true);
+        r.setCode(0);
+        r.setMessage("成功");
+        r.setPage(data);
+        return r;
+    }
+
+    /**
+     * 失败的静态方法
+     *
+     * @return R实例
+     */
+    public static <T> Rsp<T> error() {
+        Rsp<T> r = new Rsp<>();
+        r.setSuccess(false);
+        r.setCode(500);
+        r.setMessage("失败" + MDC.get("traceId"));
+        return r;
+    }
+
+    public static <T> Rsp<T> error(String message) {
+        Rsp<T> r = new Rsp<>();
+        r.setSuccess(false);
+        r.setCode(500);
+        r.setMessage(message);
+        return r;
+    }
+
+    public Rsp<T> success(Boolean success) {
+        this.setSuccess(success);
+        return this;
+    }
+
+    public Rsp<T> code(Integer code) {
+        this.setCode(code);
+        return this;
+    }
+
+    public Rsp<T> page(T object) {
+        this.setPage(object);
+        return this;
+    }
+
+    public Rsp<T> message(String message) {
+        this.setMessage(message);
+        return this;
+    }
+}

+ 456 - 471
src/main/java/com/example/controller/WzBuildManageDetailsController.java

@@ -20,19 +20,6 @@ import com.example.utils.PageUtils;
 import com.example.utils.Query;
 import com.example.utils.R;
 import com.example.utils.excel.ExcelExport;
-import com.itextpdf.kernel.font.PdfFont;
-import com.itextpdf.kernel.font.PdfFontFactory;
-import com.itextpdf.kernel.geom.PageSize;
-import com.itextpdf.kernel.pdf.PdfDocument;
-import com.itextpdf.kernel.pdf.PdfWriter;
-import com.itextpdf.layout.Document;
-import com.itextpdf.layout.element.Cell;
-import com.itextpdf.layout.element.Paragraph;
-import com.itextpdf.layout.element.Table;
-import com.itextpdf.layout.property.HorizontalAlignment;
-import com.itextpdf.layout.property.TextAlignment;
-import com.itextpdf.layout.property.UnitValue;
-import com.itextpdf.layout.property.VerticalAlignment;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.util.StringUtils;
 import org.springframework.web.bind.annotation.GetMapping;
@@ -40,9 +27,7 @@ import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 
-import javax.servlet.ServletOutputStream;
 import javax.servlet.http.HttpServletResponse;
-import java.io.ByteArrayOutputStream;
 import java.text.DateFormat;
 import java.text.DecimalFormat;
 import java.text.SimpleDateFormat;
@@ -1318,20 +1303,20 @@ public class WzBuildManageDetailsController {
     }
 
 
-    /**
-     * 获取局址别名
-     */
-    @RequestMapping("/getBuildingNameAlias")
-    @IgnoreAuth
-    public R getBuildingNameAlias(@RequestBody PageMap pageMap) {
-        //查询列表数据
-        Query query = new Query(pageMap);
-        List<String> list = wzBuildManageDetailsService.getBuildingNameAlias(query);
-        Query query1 = new Query(pageMap);
-        int total = wzBuildManageDetailsService.getBuildingNameAliasTotal(query1);
-        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
-        return R.ok().put("page", pageUtil);
-    }
+//    /**
+//     * 获取局址别名
+//     */
+//    @RequestMapping("/getBuildingNameAlias")
+//    @IgnoreAuth
+//    public R getBuildingNameAlias(@RequestBody PageMap pageMap) {
+//        //查询列表数据
+//        Query query = new Query(pageMap);
+//        List<String> list = wzBuildManageDetailsService.getBuildingNameAlias(query);
+//        Query query1 = new Query(pageMap);
+//        int total = wzBuildManageDetailsService.getBuildingNameAliasTotal(query1);
+//        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
+//        return R.ok().put("page", pageUtil);
+//    }
 
     /**
      * 土地详情
@@ -1495,449 +1480,449 @@ public class WzBuildManageDetailsController {
     }
 
 
-    /**
-     * 获取局址别名
-     */
-    @RequestMapping("/getBuildingNameCode")
-    @IgnoreAuth
-    public R getBuildingNameCode(@RequestBody PageMap pageMap) {
-        //查询列表数据
-        Query query = new Query(pageMap);
-        List<String> list = wzBuildManageDetailsService.getBuildingNameCode(query);
-        Query query1 = new Query(pageMap);
-        int total = wzBuildManageDetailsService.queryBuildDetailByCodeTotal(query1);
-        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
-        return R.ok().put("page", pageUtil);
-    }
-
-    @RequestMapping("/loadWord")
-    @IgnoreAuth
-    public void loadWord(String buildingAddressNumber, String buildingAias,String statisticalMonth, String city, String county, HttpServletResponse response) throws Exception {
-
-        Map<String, Object> query = new HashMap<>();
-        Map<String, Object> query1 = new HashMap<>();
-        query.put("buildingAddressNumber",buildingAddressNumber);
-        query.put("statisticalMonth",statisticalMonth);
-        query.put("buildingAias",buildingAias);
-        query.put("city",city);
-        query.put("county",county);
-
-        query1.put("buildingAddressNumber",buildingAddressNumber);
-        query1.put("statisticalMonth",statisticalMonth);
-        query1.put("buildingAias",buildingAias);
-        query1.put("city",city);
-        query1.put("county",county);
-
-        if(query.get("buildingAddressNumber")!=null&&query.get("buildingAddressNumber").toString().equals("")
-                &&query.get("buildingAias")!=null&&query.get("buildingAias").toString().equals("")){
-            query.put("offset",0);
-            query.put("limit",12);
-        }
-        if(query1.get("statisticalMonth")!=null&&!query1.get("statisticalMonth").toString().equals("")){
-            query1.put("statisticalMonth1",query1.get("statisticalMonth"));
-            query1.remove("statisticalMonth");
-        }
-
-        List<WzBuildManageDetailsEntity> list = wzBuildManageDetailsService.queryList(query);
-        //查询局址编码buildingAddressNumber
-        List<WzHouseMaintenaCostEntity> costEntityList=wzHouseMaintenaCostService.queryList1(query1);
-        //查询房屋维修费
-        Map<String,Double> costMap=new HashMap<>();
-        double ss=0l;
-        double cx=0l;
-        for (WzHouseMaintenaCostEntity wzHouseMaintenaCostEntity : costEntityList) {
-            if(costMap.get(wzHouseMaintenaCostEntity.getStatisticalMonth())==null){
-                costMap.put(wzHouseMaintenaCostEntity.getStatisticalMonth(),wzHouseMaintenaCostEntity.getErpCreditedAmount());
-            }else{
-                Double num=costMap.get(wzHouseMaintenaCostEntity.getStatisticalMonth())+wzHouseMaintenaCostEntity.getErpCreditedAmount();
-                costMap.put(wzHouseMaintenaCostEntity.getStatisticalMonth(),num);
-            }
-            //
-            if(wzHouseMaintenaCostEntity.getInvestmentEntity()!=null){
-                if(wzHouseMaintenaCostEntity.getInvestmentEntity().equals("上市")){
-                    ss+=wzHouseMaintenaCostEntity.getErpCreditedAmount();
-                }else{
-                    cx+=wzHouseMaintenaCostEntity.getErpCreditedAmount();
-                }
-            }
-        }
-        Integer month= 202311;
-        //key的转换
-        for(int i=202301;i<month+1;i++){
-            if(costMap.get(i+"")==null){
-                costMap.put(i+"", 0.0);
-            }
-        }
-
-        Map<String,Double> _costMap=new HashMap<>();
-        for(Map.Entry<String,Double> entry:costMap.entrySet()){
-            String key="";
-            if(entry.getKey().contains("202301")){
-                key="one";
-            }
-            if(entry.getKey().contains("202302")){
-                key="two";
-            }
-            if(entry.getKey().contains("202303")){
-                key="thr";
-            }
-            if(entry.getKey().contains("202304")){
-                key="fou";
-            }
-            if(entry.getKey().contains("202305")){
-                key="fiv";
-            }
-            if(entry.getKey().contains("202306")){
-                key="six";
-            }
-            if(entry.getKey().contains("202307")){
-                key="sev";
-            }
-            if(entry.getKey().contains("202308")){
-                key="eig";
-            }
-            if(entry.getKey().contains("202309")){
-                key="nic";
-            }
-            if(entry.getKey().contains("202310")){
-                key="ten";
-            }
-            if(entry.getKey().contains("202311")){
-                key="twi";
-            }
-            if(entry.getKey().contains("202312")){
-                key="twt";
-            }
-            _costMap.put(key,formatDouble(entry.getValue()));
-        }
-
-
-        _costMap.put("cx",formatDouble(cx));
-        _costMap.put("ss",formatDouble(ss));
-        if(list.size()>0){
-            _costMap.put("preIdea",formatDouble(Double.valueOf(list.get(0).getBuildingAreaIdelArea()==null?"0":list.get(0).getBuildingAreaIdelArea())));
-            _costMap.put("lastIdea",formatDouble(Double.valueOf(list.get(list.size()-1).getBuildingAreaIdelArea()==null?"0":list.get(list.size()-1).getBuildingAreaIdelArea())));
-            if(_costMap.get("preIdea")==0){
-                _costMap.put("average",formatDouble(0));
-            }else{
-                double average=(_costMap.get("lastIdea")-_costMap.get("preIdea"))/_costMap.get("preIdea");
-                _costMap.put("average",formatDouble(average));
-            }
-        }
-        //------------------------->>>>>>>>>>>>>>>>>>>>>-------------------------
-
-
-        // 新建一个输出流
-        ByteArrayOutputStream bao = new ByteArrayOutputStream();
-        // pdfWriter 使用传递输出流为参数的构造函数
-        PdfWriter pdfWriter = new PdfWriter(bao);
-
-        PdfDocument pdfDoc = new PdfDocument(pdfWriter);
-
-
-        PageSize ps = PageSize.A4;
-        Document doc = new Document(pdfDoc, ps.rotate());
-        doc.setMargins(20, 0, 20,0);
-        //中文字体
-        PdfFont zhFont = PdfFontFactory.createFont("STSongStd-Light", "UniGB-UCS2-H", false);
-        Table table = new Table(new float[]{1,1,1,1,1,1,1,1,1,1,1,1,1,1});
-        // 构建表格以100%的宽度
-        table.setWidth(UnitValue.createPercentValue(95))
-                .setTextAlignment(TextAlignment.CENTER)
-                .setHorizontalAlignment(HorizontalAlignment.CENTER)
-                .setPadding(0f);
-        //第一行
-        table.addCell(new Cell(3, 1)
-                .add(new Paragraph("基\n础\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("局址编码").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getBuildingAddressNumber()==null?"":list.get(0).getBuildingAddressNumber())
-                .setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("局址别名").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getBuildingAias()==null?"":list.get(0).getBuildingAias())
-                .setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("所属市区").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getCity()==null?"":list.get(0).getCity())
-                .setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("所属区县").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph(list.get(0).getCounty()==null?"":list.get(0).getCounty())
-                .setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        //第二行
-        table.addCell(new Cell(1, 1).add(new Paragraph("局址地址").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 5).add(new Paragraph(list.get(0).getStandardAddress()==null?"":list.get(0).getStandardAddress())
-                .setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("所处地段").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("一般街道 (2类)").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("建筑数量").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph(list.size()+"").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        //第三行
-        table.addCell(new Cell(1, 1).add(new Paragraph("建筑面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getBuildingArea()==null?"":list.get(0).getBuildingArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("土地面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getUseArea()==null?"":list.get(0).getUseArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("办公人数").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 6).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        //第四行
-        table.addCell(new Cell(13, 1)
-                .add(new Paragraph("建\n筑\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
-        table.addCell(new Cell(1, 1).add(new Paragraph("资产编号").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("建筑别名").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("房龄开始日期").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("投资主体").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("楼层总数").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("建筑用途").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("自建面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("自用面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("出租面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("闲置面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("资产原值").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("累计折旧").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        for(int i=0;i<list.size();i++){
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getId()+"").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingAias()==null?"":list.get(i).getBuildingAias()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingStartYear()==null?"":list.get(i).getBuildingStartYear()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getInvestmentEntity()==null?"":list.get(i).getInvestmentEntity()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getTotalNumberOfFloors()==null?"":list.get(i).getTotalNumberOfFloors()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingUse()==null?"":list.get(i).getBuildingUse()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingArea()==null?"":list.get(i).getBuildingArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingAreaUseArea()==null?"":list.get(i).getBuildingAreaUseArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingAreaRentArea()==null?"":list.get(i).getBuildingAreaRentArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingAreaIdelArea()==null?"":list.get(i).getBuildingAreaIdelArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f).setHeight(18));
-        }
-        for(int i=0;i<12-list.size();i++){
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f).setHeight(18));
-        }
-
-        //第四行
-        table.addCell(new Cell(8, 1)
-                .add(new Paragraph("出\n租\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
-        table.addCell(new Cell(1, 1).add(new Paragraph("上市累计").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租收入").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租累计欠费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("水电取暖等杂费欠费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("存续累计").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租收入").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租累计欠费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("水电取暖等杂费欠费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(2, 1).add(new Paragraph("分月数据").setFontSize(10).setFont(zhFont)).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
-        table.addCell(new Cell(1, 13).add(new Paragraph("12个月数据").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("1月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("2月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("3月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("4月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("5月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("6月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("7月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("8月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("9月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("10月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("11月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("12月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("对外出租收入(上市)").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("对外出租欠费(上市)").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("对外租出收入(存续)").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("对外租出欠费(存续)").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-
-        //第五行
-        table.addCell(new Cell(6, 1)
-                .add(new Paragraph("费\n用\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
-        table.addCell(new Cell(1, 1).add(new Paragraph("上市累计").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("房屋维修费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("ss")==null?"":_costMap.get("ss").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("物业管理费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("存续累计").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("房屋维修费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("cx")==null?"":_costMap.get("cx").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("物业管理费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(2, 1).add(new Paragraph("分月数据").setFontSize(10).setFont(zhFont)).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
-        table.addCell(new Cell(1, 13).add(new Paragraph("12个月数据").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("1月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("2月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("3月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("4月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("5月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("6月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("7月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("8月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("9月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("10月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("11月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("12月").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("房屋维修费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("one")==null?"":_costMap.get("one").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("two")==null?"":_costMap.get("two").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("thr")==null?"":_costMap.get("thr").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("fou")==null?"":_costMap.get("fou").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("fiv")==null?"":_costMap.get("fiv").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("six")==null?"":_costMap.get("six").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("sev")==null?"":_costMap.get("sev").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("eig")==null?"":_costMap.get("eig").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("nic")==null?"":_costMap.get("nic").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("ten")==null?"":_costMap.get("ten").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("twi")==null?"":_costMap.get("twi").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("twt")==null?"":_costMap.get("twt").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 1).add(new Paragraph("物业管理费").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-
-        //第六行
-        table.addCell(new Cell(3, 1)
-                .add(new Paragraph("评\n价\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
-        table.addCell(new Cell(1, 2).add(new Paragraph("指标").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("年初").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("当期").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("变化率").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("指标").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("年初").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("当期").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("变化率").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 2).add(new Paragraph("自有房产人均办公面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("房屋面积闲置率").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("preIdea")==null?"":_costMap.get("preIdea").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("lastIdea")==null?"":_costMap.get("lastIdea").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("average")==null?"":_costMap.get("average").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租平均单价").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 2).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
-
-        doc.add(table);
-
-        //边距
-        doc.close();
-
-        // 返回给客户端
-        byte[] bytes = bao.toByteArray();
-        response.reset();
-        response.setHeader("Content-Disposition","attachment;filename=totalExcel.pdf");
-        response.setContentType("application/pdf;charset=UTF-8");
-        response.setContentLength(bytes.length);
-        ServletOutputStream ouputStream = response.getOutputStream();
-        ouputStream.write(bytes, 0, bytes.length);
-        ouputStream.flush();
-        ouputStream.close();
+//    /**
+//     * 获取局址别名
+//     */
+//    @RequestMapping("/getBuildingNameCode")
+//    @IgnoreAuth
+//    public R getBuildingNameCode(@RequestBody PageMap pageMap) {
+//        //查询列表数据
+//        Query query = new Query(pageMap);
+//        List<String> list = wzBuildManageDetailsService.getBuildingNameCode(query);
+//        Query query1 = new Query(pageMap);
+//        int total = wzBuildManageDetailsService.queryBuildDetailByCodeTotal(query1);
+//        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
+//        return R.ok().put("page", pageUtil);
+//    }
 
-    }
+//    @RequestMapping("/loadWord")
+//    @IgnoreAuth
+//    public void loadWord(String buildingAddressNumber, String buildingAias,String statisticalMonth, String city, String county, HttpServletResponse response) throws Exception {
+//
+//        Map<String, Object> query = new HashMap<>();
+//        Map<String, Object> query1 = new HashMap<>();
+//        query.put("buildingAddressNumber",buildingAddressNumber);
+//        query.put("statisticalMonth",statisticalMonth);
+//        query.put("buildingAias",buildingAias);
+//        query.put("city",city);
+//        query.put("county",county);
+//
+//        query1.put("buildingAddressNumber",buildingAddressNumber);
+//        query1.put("statisticalMonth",statisticalMonth);
+//        query1.put("buildingAias",buildingAias);
+//        query1.put("city",city);
+//        query1.put("county",county);
+//
+//        if(query.get("buildingAddressNumber")!=null&&query.get("buildingAddressNumber").toString().equals("")
+//                &&query.get("buildingAias")!=null&&query.get("buildingAias").toString().equals("")){
+//            query.put("offset",0);
+//            query.put("limit",12);
+//        }
+//        if(query1.get("statisticalMonth")!=null&&!query1.get("statisticalMonth").toString().equals("")){
+//            query1.put("statisticalMonth1",query1.get("statisticalMonth"));
+//            query1.remove("statisticalMonth");
+//        }
+//
+//        List<WzBuildManageDetailsEntity> list = wzBuildManageDetailsService.queryList(query);
+//        //查询局址编码buildingAddressNumber
+//        List<WzHouseMaintenaCostEntity> costEntityList=wzHouseMaintenaCostService.queryList1(query1);
+//        //查询房屋维修费
+//        Map<String,Double> costMap=new HashMap<>();
+//        double ss=0l;
+//        double cx=0l;
+//        for (WzHouseMaintenaCostEntity wzHouseMaintenaCostEntity : costEntityList) {
+//            if(costMap.get(wzHouseMaintenaCostEntity.getStatisticalMonth())==null){
+//                costMap.put(wzHouseMaintenaCostEntity.getStatisticalMonth(),wzHouseMaintenaCostEntity.getErpCreditedAmount());
+//            }else{
+//                Double num=costMap.get(wzHouseMaintenaCostEntity.getStatisticalMonth())+wzHouseMaintenaCostEntity.getErpCreditedAmount();
+//                costMap.put(wzHouseMaintenaCostEntity.getStatisticalMonth(),num);
+//            }
+//            //
+//            if(wzHouseMaintenaCostEntity.getInvestmentEntity()!=null){
+//                if(wzHouseMaintenaCostEntity.getInvestmentEntity().equals("上市")){
+//                    ss+=wzHouseMaintenaCostEntity.getErpCreditedAmount();
+//                }else{
+//                    cx+=wzHouseMaintenaCostEntity.getErpCreditedAmount();
+//                }
+//            }
+//        }
+//        Integer month= 202311;
+//        //key的转换
+//        for(int i=202301;i<month+1;i++){
+//            if(costMap.get(i+"")==null){
+//                costMap.put(i+"", 0.0);
+//            }
+//        }
+//
+//        Map<String,Double> _costMap=new HashMap<>();
+//        for(Map.Entry<String,Double> entry:costMap.entrySet()){
+//            String key="";
+//            if(entry.getKey().contains("202301")){
+//                key="one";
+//            }
+//            if(entry.getKey().contains("202302")){
+//                key="two";
+//            }
+//            if(entry.getKey().contains("202303")){
+//                key="thr";
+//            }
+//            if(entry.getKey().contains("202304")){
+//                key="fou";
+//            }
+//            if(entry.getKey().contains("202305")){
+//                key="fiv";
+//            }
+//            if(entry.getKey().contains("202306")){
+//                key="six";
+//            }
+//            if(entry.getKey().contains("202307")){
+//                key="sev";
+//            }
+//            if(entry.getKey().contains("202308")){
+//                key="eig";
+//            }
+//            if(entry.getKey().contains("202309")){
+//                key="nic";
+//            }
+//            if(entry.getKey().contains("202310")){
+//                key="ten";
+//            }
+//            if(entry.getKey().contains("202311")){
+//                key="twi";
+//            }
+//            if(entry.getKey().contains("202312")){
+//                key="twt";
+//            }
+//            _costMap.put(key,formatDouble(entry.getValue()));
+//        }
+//
+//
+//        _costMap.put("cx",formatDouble(cx));
+//        _costMap.put("ss",formatDouble(ss));
+//        if(list.size()>0){
+//            _costMap.put("preIdea",formatDouble(Double.valueOf(list.get(0).getBuildingAreaIdelArea()==null?"0":list.get(0).getBuildingAreaIdelArea())));
+//            _costMap.put("lastIdea",formatDouble(Double.valueOf(list.get(list.size()-1).getBuildingAreaIdelArea()==null?"0":list.get(list.size()-1).getBuildingAreaIdelArea())));
+//            if(_costMap.get("preIdea")==0){
+//                _costMap.put("average",formatDouble(0));
+//            }else{
+//                double average=(_costMap.get("lastIdea")-_costMap.get("preIdea"))/_costMap.get("preIdea");
+//                _costMap.put("average",formatDouble(average));
+//            }
+//        }
+//        //------------------------->>>>>>>>>>>>>>>>>>>>>-------------------------
+//
+//
+//        // 新建一个输出流
+//        ByteArrayOutputStream bao = new ByteArrayOutputStream();
+//        // pdfWriter 使用传递输出流为参数的构造函数
+//        PdfWriter pdfWriter = new PdfWriter(bao);
+//
+//        PdfDocument pdfDoc = new PdfDocument(pdfWriter);
+//
+//
+//        PageSize ps = PageSize.A4;
+//        Document doc = new Document(pdfDoc, ps.rotate());
+//        doc.setMargins(20, 0, 20,0);
+//        //中文字体
+//        PdfFont zhFont = PdfFontFactory.createFont("STSongStd-Light", "UniGB-UCS2-H", false);
+//        Table table = new Table(new float[]{1,1,1,1,1,1,1,1,1,1,1,1,1,1});
+//        // 构建表格以100%的宽度
+//        table.setWidth(UnitValue.createPercentValue(95))
+//                .setTextAlignment(TextAlignment.CENTER)
+//                .setHorizontalAlignment(HorizontalAlignment.CENTER)
+//                .setPadding(0f);
+//        //第一行
+//        table.addCell(new Cell(3, 1)
+//                .add(new Paragraph("基\n础\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("局址编码").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getBuildingAddressNumber()==null?"":list.get(0).getBuildingAddressNumber())
+//                .setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("局址别名").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getBuildingAias()==null?"":list.get(0).getBuildingAias())
+//                .setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("所属市区").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getCity()==null?"":list.get(0).getCity())
+//                .setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("所属区县").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph(list.get(0).getCounty()==null?"":list.get(0).getCounty())
+//                .setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        //第二行
+//        table.addCell(new Cell(1, 1).add(new Paragraph("局址地址").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 5).add(new Paragraph(list.get(0).getStandardAddress()==null?"":list.get(0).getStandardAddress())
+//                .setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("所处地段").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("一般街道 (2类)").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("建筑数量").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph(list.size()+"").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        //第三行
+//        table.addCell(new Cell(1, 1).add(new Paragraph("建筑面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getBuildingArea()==null?"":list.get(0).getBuildingArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("土地面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph(list.get(0).getUseArea()==null?"":list.get(0).getUseArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("办公人数").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 6).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        //第四行
+//        table.addCell(new Cell(13, 1)
+//                .add(new Paragraph("建\n筑\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("资产编号").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("建筑别名").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("房龄开始日期").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("投资主体").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("楼层总数").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("建筑用途").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("自建面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("自用面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("出租面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("闲置面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("资产原值").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("累计折旧").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        for(int i=0;i<list.size();i++){
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getId()+"").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingAias()==null?"":list.get(i).getBuildingAias()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingStartYear()==null?"":list.get(i).getBuildingStartYear()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getInvestmentEntity()==null?"":list.get(i).getInvestmentEntity()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getTotalNumberOfFloors()==null?"":list.get(i).getTotalNumberOfFloors()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingUse()==null?"":list.get(i).getBuildingUse()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingArea()==null?"":list.get(i).getBuildingArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingAreaUseArea()==null?"":list.get(i).getBuildingAreaUseArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingAreaRentArea()==null?"":list.get(i).getBuildingAreaRentArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph(list.get(i).getBuildingAreaIdelArea()==null?"":list.get(i).getBuildingAreaIdelArea()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f).setHeight(18));
+//        }
+//        for(int i=0;i<12-list.size();i++){
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//            table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f).setHeight(18));
+//        }
+//
+//        //第四行
+//        table.addCell(new Cell(8, 1)
+//                .add(new Paragraph("出\n租\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("上市累计").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租收入").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租累计欠费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("水电取暖等杂费欠费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("存续累计").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租收入").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租累计欠费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("水电取暖等杂费欠费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(2, 1).add(new Paragraph("分月数据").setFontSize(10).setFont(zhFont)).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
+//        table.addCell(new Cell(1, 13).add(new Paragraph("12个月数据").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("1月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("2月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("3月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("4月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("5月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("6月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("7月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("8月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("9月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("10月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("11月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("12月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("对外出租收入(上市)").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("对外出租欠费(上市)").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("对外租出收入(存续)").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("对外租出欠费(存续)").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//
+//        //第五行
+//        table.addCell(new Cell(6, 1)
+//                .add(new Paragraph("费\n用\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("上市累计").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("房屋维修费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("ss")==null?"":_costMap.get("ss").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("物业管理费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("存续累计").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("房屋维修费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("cx")==null?"":_costMap.get("cx").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("物业管理费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(2, 1).add(new Paragraph("分月数据").setFontSize(10).setFont(zhFont)).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
+//        table.addCell(new Cell(1, 13).add(new Paragraph("12个月数据").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("1月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("2月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("3月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("4月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("5月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("6月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("7月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("8月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("9月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("10月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("11月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("12月").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("房屋维修费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("one")==null?"":_costMap.get("one").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("two")==null?"":_costMap.get("two").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("thr")==null?"":_costMap.get("thr").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("fou")==null?"":_costMap.get("fou").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("fiv")==null?"":_costMap.get("fiv").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("six")==null?"":_costMap.get("six").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("sev")==null?"":_costMap.get("sev").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("eig")==null?"":_costMap.get("eig").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("nic")==null?"":_costMap.get("nic").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("ten")==null?"":_costMap.get("ten").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("twi")==null?"":_costMap.get("twi").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("twt")==null?"":_costMap.get("twt").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 1).add(new Paragraph("物业管理费").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//
+//        //第六行
+//        table.addCell(new Cell(3, 1)
+//                .add(new Paragraph("评\n价\n信\n息").setFontSize(11).setFont(zhFont).setBold()).setPadding(4f).setVerticalAlignment(VerticalAlignment.MIDDLE));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("指标").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("年初").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("当期").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("变化率").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("指标").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("年初").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("当期").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("变化率").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 2).add(new Paragraph("自有房产人均办公面积").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("房屋面积闲置率").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("preIdea")==null?"":_costMap.get("preIdea").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("lastIdea")==null?"":_costMap.get("lastIdea").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph(_costMap.get("average")==null?"":_costMap.get("average").toString()).setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        table.addCell(new Cell(1, 2).add(new Paragraph("对外出租平均单价").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("-").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 2).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 1).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//        table.addCell(new Cell(1, 3).add(new Paragraph("").setFontSize(10).setFont(zhFont)).setPadding(4f));
+//
+//        doc.add(table);
+//
+//        //边距
+//        doc.close();
+//
+//        // 返回给客户端
+//        byte[] bytes = bao.toByteArray();
+//        response.reset();
+//        response.setHeader("Content-Disposition","attachment;filename=totalExcel.pdf");
+//        response.setContentType("application/pdf;charset=UTF-8");
+//        response.setContentLength(bytes.length);
+//        ServletOutputStream ouputStream = response.getOutputStream();
+//        ouputStream.write(bytes, 0, bytes.length);
+//        ouputStream.flush();
+//        ouputStream.close();
+//
+//    }
 
 
     public double formatDouble(double num) {

+ 30 - 30
src/main/java/com/example/controller/WzHouseMaintenaCostController.java

@@ -691,36 +691,36 @@ public class WzHouseMaintenaCostController {
         return R.ok().put("page", pageUtil);
     }
 
-    /**
-     * 获取局址别名
-     */
-    @RequestMapping("/getBuildingNameCode")
-    @IgnoreAuth
-    public R getBuildingNameCode(@RequestBody PageMap pageMap) {
-        //查询列表数据
-        Query query = new Query(pageMap);
-        List<String> list = wzHouseMaintenaCostService.getBuildingNameCode(query);
-        Query query1 = new Query(pageMap);
-        int total = wzHouseMaintenaCostService.queryBuildDetailByCodeTotal(query1);
-        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
-        return R.ok().put("page", pageUtil);
-    }
-
-
-    /**
-     * 获取局址别名
-     */
-    @RequestMapping("/getBuildingNameAlias")
-    @IgnoreAuth
-    public R getBuildingNameAlias(@RequestBody PageMap pageMap) {
-        //查询列表数据
-        Query query = new Query(pageMap);
-        List<String> list = wzHouseMaintenaCostService.getBuildingNameAlias(query);
-        Query query1 = new Query(pageMap);
-        int total = wzHouseMaintenaCostService.getBuildingNameAliasTotal(query1);
-        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
-        return R.ok().put("page", pageUtil);
-    }
+//    /**
+//     * 获取局址别名
+//     */
+//    @RequestMapping("/getBuildingNameCode")
+//    @IgnoreAuth
+//    public R getBuildingNameCode(@RequestBody PageMap pageMap) {
+//        //查询列表数据
+//        Query query = new Query(pageMap);
+//        List<String> list = wzHouseMaintenaCostService.getBuildingNameCode(query);
+//        Query query1 = new Query(pageMap);
+//        int total = wzHouseMaintenaCostService.queryBuildDetailByCodeTotal(query1);
+//        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
+//        return R.ok().put("page", pageUtil);
+//    }
+//
+//
+//    /**
+//     * 获取局址别名
+//     */
+//    @RequestMapping("/getBuildingNameAlias")
+//    @IgnoreAuth
+//    public R getBuildingNameAlias(@RequestBody PageMap pageMap) {
+//        //查询列表数据
+//        Query query = new Query(pageMap);
+//        List<String> list = wzHouseMaintenaCostService.getBuildingNameAlias(query);
+//        Query query1 = new Query(pageMap);
+//        int total = wzHouseMaintenaCostService.getBuildingNameAliasTotal(query1);
+//        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
+//        return R.ok().put("page", pageUtil);
+//    }
 
     public void responseTab6(DateFormat df, ExcelExport ee1, Map<String, Object> map1){
         List<WzHouseMaintenaCostEntity> alllist = wzHouseMaintenaCostService.queryList1(map1);

+ 29 - 29
src/main/java/com/example/controller/WzLandManageDetailsController.java

@@ -736,33 +736,33 @@ public class WzLandManageDetailsController {
         return avera;
     }
 
-    /**
-     * 获取局址别名
-     */
-    @RequestMapping("/getBuildingNameCode")
-    @IgnoreAuth
-    public R getBuildingNameCode(@RequestBody PageMap pageMap) {
-        //查询列表数据
-        Query query = new Query(pageMap);
-        List<String> list = wzLandManageDetailsService.getBuildingNameCode(query);
-        Query query1 = new Query(pageMap);
-        int total = wzLandManageDetailsService.queryBuildingNameCodeTotal(query1);
-        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
-        return R.ok().put("page", pageUtil);
-    }
-
-    /**
-     * 获取局址别名
-     */
-    @RequestMapping("/getBuildingNameAlias")
-    @IgnoreAuth
-    public R getBuildingNameAlias(@RequestBody PageMap pageMap) {
-        //查询列表数据
-        Query query = new Query(pageMap);
-        List<String> list = wzLandManageDetailsService.getBuildingNameAlias(query);
-        Query query1 = new Query(pageMap);
-        int total = wzLandManageDetailsService.getBuildingNameAliasTotal(query1);
-        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
-        return R.ok().put("page", pageUtil);
-    }
+//    /**
+//     * 获取局址别名
+//     */
+//    @RequestMapping("/getBuildingNameCode")
+//    @IgnoreAuth
+//    public R getBuildingNameCode(@RequestBody PageMap pageMap) {
+//        //查询列表数据
+//        Query query = new Query(pageMap);
+//        List<String> list = wzLandManageDetailsService.getBuildingNameCode(query);
+//        Query query1 = new Query(pageMap);
+//        int total = wzLandManageDetailsService.queryBuildingNameCodeTotal(query1);
+//        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
+//        return R.ok().put("page", pageUtil);
+//    }
+//
+//    /**
+//     * 获取局址别名
+//     */
+//    @RequestMapping("/getBuildingNameAlias")
+//    @IgnoreAuth
+//    public R getBuildingNameAlias(@RequestBody PageMap pageMap) {
+//        //查询列表数据
+//        Query query = new Query(pageMap);
+//        List<String> list = wzLandManageDetailsService.getBuildingNameAlias(query);
+//        Query query1 = new Query(pageMap);
+//        int total = wzLandManageDetailsService.getBuildingNameAliasTotal(query1);
+//        PageUtils pageUtil = new PageUtils(list, total, query.getLimit(), query.getPage());
+//        return R.ok().put("page", pageUtil);
+//    }
 }

+ 33 - 0
src/main/java/com/example/controller/house/HouseSiteStatController.java

@@ -0,0 +1,33 @@
+package com.example.controller.house;
+
+import com.example.common.Rsp;
+import com.example.pojo.dto.GetSiteStatDto;
+import com.example.pojo.vo.GetSiteStatVo;
+import com.example.service.house.HouseSiteStatService;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import javax.validation.Valid;
+
+@Tag(name = "不动产一房产一局址表")
+@Slf4j
+@RequestMapping("/house-car/house/dist/api/siteStat")
+@RestController
+public class HouseSiteStatController {
+    private final HouseSiteStatService houseSiteStatService;
+
+    public HouseSiteStatController(HouseSiteStatService houseSiteStatService) {
+        this.houseSiteStatService = houseSiteStatService;
+    }
+
+    @Operation(summary = "查询一房产一局址表")
+    @PostMapping("/getSiteStat")
+    public Rsp<GetSiteStatVo> getSiteStat(@Valid @RequestBody GetSiteStatDto dto) {
+        return houseSiteStatService.getSiteStat(dto);
+    }
+}

+ 18 - 2
src/main/java/com/example/controller/house/HouseWzBuildManageDetailsController.java

@@ -1,8 +1,12 @@
 package com.example.controller.house;
 
+import com.example.common.PageVo;
+import com.example.common.Rsp;
 import com.example.pojo.dto.ListBuildingIdleDto;
+import com.example.pojo.dto.ListSiteNameDto;
+import com.example.pojo.dto.ListSiteNumDto;
+import com.example.pojo.vo.ListBuildingIdleVo;
 import com.example.service.house.HouseWzBuildManageDetailsService;
-import com.example.utils.R;
 import io.swagger.v3.oas.annotations.Operation;
 import io.swagger.v3.oas.annotations.tags.Tag;
 import lombok.extern.slf4j.Slf4j;
@@ -27,7 +31,7 @@ public class HouseWzBuildManageDetailsController {
 
     @Operation(summary = "空置1000平米以上建筑")
     @PostMapping("/ideList")
-    public R ideList(@Valid @RequestBody ListBuildingIdleDto dto) {
+    public Rsp<PageVo<ListBuildingIdleVo>> ideList(@Valid @RequestBody ListBuildingIdleDto dto) {
         return houseWzBuildManageDetailsService.ideList(dto);
     }
 
@@ -36,4 +40,16 @@ public class HouseWzBuildManageDetailsController {
     public void ideListExport(@Valid ListBuildingIdleDto dto) {
         houseWzBuildManageDetailsService.ideListExport(dto);
     }
+
+    @Operation(summary = "查询局址别名列表")
+    @PostMapping("/getBuildingNameAlias")
+    public Rsp<PageVo<String>> listSiteName(@RequestBody ListSiteNameDto dto) {
+        return houseWzBuildManageDetailsService.listSiteName(dto);
+    }
+
+    @Operation(summary = "查询局址编号列表")
+    @PostMapping("/getBuildingNameCode")
+    public Rsp<PageVo<String>> listSiteNum(@RequestBody ListSiteNumDto dto) {
+        return houseWzBuildManageDetailsService.listSiteNum(dto);
+    }
 }

+ 22 - 4
src/main/java/com/example/controller/house/HouseWzHouseMaintenaCostController.java

@@ -1,10 +1,16 @@
 package com.example.controller.house;
 
+import com.example.common.PageVo;
+import com.example.common.Rsp;
 import com.example.pojo.dto.ListBuildingHighRepairDto;
 import com.example.pojo.dto.ListBuildingHighSporadicRepairDto;
 import com.example.pojo.dto.ListBuildingSameRepairFrequencyDto;
+import com.example.pojo.dto.ListSiteNameDto;
+import com.example.pojo.dto.ListSiteNumDto;
+import com.example.pojo.vo.ListBuildingHighRepairVo;
+import com.example.pojo.vo.ListBuildingHighSporadicRepairVo;
+import com.example.pojo.vo.ListBuildingSameRepairFrequencyVo;
 import com.example.service.house.HouseWzHouseMaintenaCostService;
-import com.example.utils.R;
 import io.swagger.v3.oas.annotations.Operation;
 import io.swagger.v3.oas.annotations.tags.Tag;
 import lombok.extern.slf4j.Slf4j;
@@ -29,7 +35,7 @@ public class HouseWzHouseMaintenaCostController {
 
     @Operation(summary = "高总价统计")
     @PostMapping("/queryHighPrice")
-    public R queryHighPrice(@Valid @RequestBody ListBuildingHighRepairDto dto) {
+    public Rsp<PageVo<ListBuildingHighRepairVo>> queryHighPrice(@Valid @RequestBody ListBuildingHighRepairDto dto) {
         return houseWzHouseMaintenaCostService.queryHighPrice(dto);
     }
 
@@ -41,7 +47,7 @@ public class HouseWzHouseMaintenaCostController {
 
     @Operation(summary = "相同维修频次统计")
     @PostMapping("/queryHighFrequency")
-    public R queryHighFrequency(@Valid @RequestBody ListBuildingSameRepairFrequencyDto dto) {
+    public Rsp<PageVo<ListBuildingSameRepairFrequencyVo>> queryHighFrequency(@Valid @RequestBody ListBuildingSameRepairFrequencyDto dto) {
         return houseWzHouseMaintenaCostService.queryHighFrequency(dto);
     }
 
@@ -53,7 +59,7 @@ public class HouseWzHouseMaintenaCostController {
 
     @Operation(summary = "高额日常零星维修")
     @PostMapping("/queryDailyModify")
-    public R queryDailyModify(@Valid @RequestBody ListBuildingHighSporadicRepairDto dto) {
+    public Rsp<PageVo<ListBuildingHighSporadicRepairVo>> queryDailyModify(@Valid @RequestBody ListBuildingHighSporadicRepairDto dto) {
         return houseWzHouseMaintenaCostService.queryDailyModify(dto);
     }
 
@@ -62,4 +68,16 @@ public class HouseWzHouseMaintenaCostController {
     public void queryDailyModifyExport(@Valid ListBuildingHighSporadicRepairDto dto) {
         houseWzHouseMaintenaCostService.queryDailyModifyExport(dto);
     }
+
+    @Operation(summary = "查询局址别名列表")
+    @PostMapping("/getBuildingNameAlias")
+    public Rsp<PageVo<String>> listSiteName(@RequestBody ListSiteNameDto dto) {
+        return houseWzHouseMaintenaCostService.listSiteName(dto);
+    }
+
+    @Operation(summary = "查询局址编号列表")
+    @PostMapping("/getBuildingNameCode")
+    public Rsp<PageVo<String>> listSiteNum(@RequestBody ListSiteNumDto dto) {
+        return houseWzHouseMaintenaCostService.listSiteNum(dto);
+    }
 }

+ 34 - 0
src/main/java/com/example/controller/house/HouseWzLandManageDetailsController.java

@@ -0,0 +1,34 @@
+package com.example.controller.house;
+
+import com.example.common.PageVo;
+import com.example.common.Rsp;
+import com.example.pojo.dto.ListSiteNameDto;
+import com.example.pojo.dto.ListSiteNumDto;
+import com.example.service.house.HouseWzLandManageDetailsService;
+import io.swagger.v3.oas.annotations.Operation;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+@RestController
+@RequestMapping("/house-car/house/dist/api/WzLandManageDetails")
+public class HouseWzLandManageDetailsController {
+    private final HouseWzLandManageDetailsService houseWzLandManageDetailsService;
+
+    public HouseWzLandManageDetailsController(HouseWzLandManageDetailsService houseWzLandManageDetailsService) {
+        this.houseWzLandManageDetailsService = houseWzLandManageDetailsService;
+    }
+
+    @Operation(summary = "查询局址别名列表")
+    @PostMapping("/getBuildingNameAlias")
+    public Rsp<PageVo<String>> listSiteName(@RequestBody ListSiteNameDto dto) {
+        return houseWzLandManageDetailsService.listSiteName(dto);
+    }
+
+    @Operation(summary = "查询局址编号列表")
+    @PostMapping("/getBuildingNameCode")
+    public Rsp<PageVo<String>> listSiteNum(@RequestBody ListSiteNumDto dto) {
+        return houseWzLandManageDetailsService.listSiteNum(dto);
+    }
+}

+ 21 - 0
src/main/java/com/example/controller/house/HouseWzOtnAreaController.java

@@ -1,5 +1,11 @@
 package com.example.controller.house;
 
+import com.example.common.PageVo;
+import com.example.common.Rsp;
+import com.example.pojo.dto.ListSiteNameDto;
+import com.example.pojo.dto.ListSiteNumDto;
+import com.example.pojo.vo.ListSiteNameVo;
+import com.example.pojo.vo.ListSiteNumVo;
 import com.example.service.house.HouseWzOtnAreaService;
 import com.example.utils.R;
 import io.swagger.v3.oas.annotations.Operation;
@@ -7,9 +13,12 @@ import io.swagger.v3.oas.annotations.tags.Tag;
 import lombok.extern.slf4j.Slf4j;
 import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 
+import javax.validation.Valid;
+
 @Tag(name = "不动产组织机构")
 @Slf4j
 @RequestMapping("/house-car/house/dist/api/wzOtnArea")
@@ -26,4 +35,16 @@ public class HouseWzOtnAreaController {
     public R getCityOption(@PathVariable("id") String id) {
         return houseWzOtnAreaService.getCityOption(id);
     }
+
+    @Operation(summary = "查询局址别名列表")
+    @PostMapping("/listSiteName")
+    public Rsp<PageVo<ListSiteNameVo>> listSiteName(@Valid @RequestBody ListSiteNameDto dto) {
+        return houseWzOtnAreaService.listSiteName(dto);
+    }
+
+    @Operation(summary = "查询局址编号列表")
+    @PostMapping("/listSiteNum")
+    public Rsp<PageVo<ListSiteNumVo>> listSiteNum(@Valid @RequestBody ListSiteNumDto dto) {
+        return houseWzOtnAreaService.listSiteNum(dto);
+    }
 }

+ 33 - 0
src/main/java/com/example/dao/WzOtnAreaDao.java

@@ -1,7 +1,10 @@
 package com.example.dao;
 
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.example.config.mybatis.ex.method.ExBaseMapper;
 import com.example.entity.OtnAreaEntity;
+import com.example.entity.house.HouseSitePo;
+import com.example.pojo.bo.ListHouseSiteBo;
 import org.apache.ibatis.annotations.Mapper;
 import org.apache.ibatis.annotations.Param;
 import org.apache.ibatis.annotations.Select;
@@ -79,4 +82,34 @@ limit 1
 //     List<WzHouseContractVo> queryVoList(Map<String, Object> map);
 //
 //     List<FloorNoUserVo> queryLeaveUseList(Map<String, Object> map);
+
+    /**
+     * 查询局址列表
+     */
+    @Select("""
+<script>
+select
+    site_id,
+    site_num,
+    site_name
+from
+    house.site_month
+where
+    year_month = #{bo.yearMonth}
+<if test="bo.areaNo != null and bo.areaNo != ''">
+  and area_no = #{bo.areaNo}
+</if>
+<if test="bo.cityNo != null and bo.cityNo != ''">
+  and city_no = #{bo.cityNo}
+</if>
+<if test="bo.siteNum != null and bo.siteNum != ''">
+  and site_num like #{bo.siteNum} || '%'
+</if>
+<if test="bo.siteName != null and bo.siteName != ''">
+  and site_name like '%' || #{bo.siteName} || '%'
+</if>
+order by site_id
+</script>
+""")
+    List<HouseSitePo> listHouseSite(Page<HouseSitePo> page, @Param("bo") ListHouseSiteBo bo);
 }

+ 142 - 0
src/main/java/com/example/dao/house/HouseSiteStatDao.java

@@ -0,0 +1,142 @@
+package com.example.dao.house;
+
+import com.example.entity.house.HouseBuildingPo;
+import com.example.entity.house.HouseSiteBuildingAreaIdleDiffPo;
+import com.example.entity.house.HouseSitePo;
+import com.example.entity.house.HouseSiteRepairInvestorStatPo;
+import com.example.entity.house.HouseSiteRepairMonthPo;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+import org.apache.ibatis.annotations.Select;
+
+import java.math.BigDecimal;
+import java.util.List;
+
+@Mapper
+public interface HouseSiteStatDao {
+    /**
+     * 根据账期和局址id查询局址信息
+     * @param yearMonth 账期
+     * @param siteId 局址id
+     */
+    @Select("""
+select * from house.site_month where year_month = #{yearMonth} and site_id = #{siteId}
+""")
+    HouseSitePo getHouseSiteBySiteIdAndYearMonth(@Param("yearMonth") Integer yearMonth, @Param("siteId") String siteId);
+
+    /**
+     * 根据账期和局址id查询所有建筑
+     * @param yearMonth 账期
+     * @param siteId 局址id
+     */
+    @Select("""
+select * from house.building_month where year_month = #{yearMonth} and site_id = #{siteId}
+""")
+    List<HouseBuildingPo> allBuildingBySiteIdAndYearMonth(@Param("yearMonth") Integer yearMonth,
+                                                          @Param("siteId") String siteId);
+
+    /**
+     * 根据账期和局址id查询土地总面积
+     * @param yearMonth 账期
+     * @param siteId 局址id
+     */
+    @Select("""
+select
+    sum(total_land_area) as land_area_sum
+from
+    house.land_month
+where
+    year_month = #{yearMonth}
+    and site_id = #{siteId}
+""")
+    BigDecimal getLandAreaBySiteIdAndYearMonth(@Param("yearMonth") Integer yearMonth, @Param("siteId") String siteId);
+
+    /**
+     * 根据局址id查询当年累计维修费按投资主体分组
+     * @param startYearMonth 开始年月
+     * @param endYearMonth 结束年月
+     * @param siteId 局址id
+     */
+    @Select("""
+select
+    sum(case when investor = 1 then final_cost else 0 end) as building_repair_ss,
+    sum(case when investor = 3 then final_cost else 0 end) as building_repair_cx
+from
+    house.building_repair_month
+where
+    year_month >= #{startYearMonth}
+    and year_month <= #{endYearMonth}
+    and site_id = #{siteId}
+""")
+    HouseSiteRepairInvestorStatPo getSiteRepairInvestorStat(@Param("startYearMonth") Integer startYearMonth,
+                                                            @Param("endYearMonth") Integer endYearMonth,
+                                                            @Param("siteId") String siteId);
+
+    /**
+     * 根据局址id查询分月维修费
+     * @param startYearMonth 开始年月
+     * @param endYearMonth 结束年月
+     * @param siteId 局址id
+     */
+    @Select("""
+select
+    month_no,
+    sum(final_cost) as final_cost_sum
+from
+    house.building_repair_month
+where
+    year_month >= #{startYearMonth}
+    and year_month <= #{endYearMonth}
+    and site_id = #{siteId}
+group by month_no
+order by month_no
+""")
+    List<HouseSiteRepairMonthPo> getHouseSiteRepairMonth(@Param("startYearMonth") Integer startYearMonth,
+                                                         @Param("endYearMonth") Integer endYearMonth,
+                                                         @Param("siteId") String siteId);
+
+    @Select("""
+with
+t101 as (
+select
+    case
+        when (sum(building_area_idle) + sum(building_area_rent)) = 0 then 0
+        else round(sum(building_area_idle) / (sum(building_area_idle) + sum(building_area_rent)) * 100,
+        2)
+    end as building_area_idle_rate_past
+from
+    house.building_month
+where
+    year_month = #{startYearMonth}
+    and site_id = #{siteId}
+),
+t102 as (
+select
+    case
+        when (sum(building_area_idle) + sum(building_area_rent)) = 0 then 0
+        else round(sum(building_area_idle) / (sum(building_area_idle) + sum(building_area_rent)) * 100,
+        2)
+    end as building_area_idle_rate_now
+from
+    house.building_month
+where
+    year_month = #{endYearMonth}
+    and site_id = #{siteId}
+),
+t103 as (
+select
+    *,
+    building_area_idle_rate_now - building_area_idle_rate_past as building_area_idle_rate_diff
+from
+    t101
+cross join t102
+)
+select
+    *
+from
+    t103
+""")
+    HouseSiteBuildingAreaIdleDiffPo getSiteBuildingAreaIdleDiff(@Param("startYearMonth") Integer startYearMonth,
+                                                                @Param("endYearMonth") Integer endYearMonth,
+                                                                @Param("siteId") String siteId);
+}

+ 267 - 2
src/main/java/com/example/entity/house/HouseBuildingPo.java

@@ -1,78 +1,343 @@
 package com.example.entity.house;
 
 import lombok.Data;
-import lombok.NoArgsConstructor;
 
 import java.math.BigDecimal;
 
-@NoArgsConstructor
 @Data
 public class HouseBuildingPo {
+    /**
+     * 数据年月
+     */
     private Integer yearMonth;
+
+    /**
+     * 建筑ID
+     */
     private String buildingId;
+
+    /**
+     * 资产所属单位(一级)
+     */
     private String firstUnit;
+
+    /**
+     * 资产所属单位(二级)
+     */
     private String secondUnit;
+
+    /**
+     * 资产所属单位(三级)
+     */
     private String thirdUnit;
+
+    /**
+     * 局址编号
+     */
     private String siteNum;
+
+    /**
+     * 局址别名
+     */
     private String siteName;
+
+    /**
+     * 标准地址
+     */
     private String address;
+
+    /**
+     * 城市等级
+     */
     private String cityLevel;
+
+    /**
+     * 城市区域
+     */
     private String cityRegion;
+
+    /**
+     * 地段
+     */
     private String areaSector;
+
+    /**
+     * 是否有土地资产
+     */
     private String hasLand;
+
+    /**
+     * 局址ID
+     */
     private String siteId;
+
+    /**
+     * 建筑别名
+     */
     private String buildingName;
+
+    /**
+     * 得房率
+     */
     private BigDecimal housingAcquisitionRate;
+
+    /**
+     * 房屋来源
+     */
     private String housingSource;
+
+    /**
+     * 取得日期
+     */
     private String acquisitionDate;
+
+    /**
+     * 房龄开始年份
+     */
     private Integer houseYearBegan;
+
+    /**
+     * 投资主体
+     */
     private String investor;
+
+    /**
+     * 管理层级
+     */
     private String managementLevel;
+
+    /**
+     * 房屋结构
+     */
     private String buildingStructure;
+
+    /**
+     * 楼层总数
+     */
     private String totalFloors;
+
+    /**
+     * 资产编号
+     */
     private String assetsNum;
+
+    /**
+     * 资产标签号
+     */
     private String assetsTagNum;
+
+    /**
+     * 使用状态
+     */
     private String usageStatus;
+
+    /**
+     * 建筑用途
+     */
     private String buildingUse;
+
+    /**
+     * 权属状态
+     */
     private String ownershipStatus;
+
+    /**
+     * 建筑占地面积(㎡)
+     */
     private BigDecimal floorArea;
+
+    /**
+     * 建筑面积(㎡)
+     */
     private BigDecimal buildingArea;
+
+    /**
+     * 建筑面积-自用(㎡)
+     */
     private BigDecimal buildingAreaSelfUse;
+
+    /**
+     * 建筑面积-出租(㎡)
+     */
     private BigDecimal buildingAreaRent;
+
+    /**
+     * 建筑面积-闲置(㎡)
+     */
     private BigDecimal buildingAreaIdle;
+
+    /**
+     * 建筑面积-不可使用(㎡)
+     */
     private BigDecimal buildingAreaUnusable;
+
+    /**
+     * 使用面积(㎡)
+     */
     private BigDecimal usableArea;
+
+    /**
+     * 使用面积-自用(㎡)
+     */
     private BigDecimal usableAreaSelfUse;
+
+    /**
+     * 使用面积-出租(㎡)
+     */
     private BigDecimal usableAreaRent;
+
+    /**
+     * 使用面积-闲置(㎡)
+     */
     private BigDecimal usableAreaIdle;
+
+    /**
+     * 使用面积-不可使用(㎡)
+     */
     private BigDecimal usableAreaUnusable;
+
+    /**
+     * 地市
+     */
     private String city;
+
+    /**
+     * 区县
+     */
     private String district;
+
+    /**
+     * 经度wgs84
+     */
     private BigDecimal lngWgs84;
+
+    /**
+     * 纬度wgs84
+     */
     private BigDecimal latWgs84;
+
+    /**
+     * 经度bd09
+     */
     private BigDecimal lngBd09;
+
+    /**
+     * 纬度bd09
+     */
     private BigDecimal latBd09;
+
+    /**
+     * 建筑图片
+     */
     private String buildingImg;
+
+    /**
+     * 二级组织机构编码
+     */
     private String areaNo;
+
+    /**
+     * 二级组织机构名称
+     */
     private String areaName;
+
+    /**
+     * 三级组织机构编码
+     */
     private String cityNo;
+
+    /**
+     * 三级组织机构名称
+     */
     private String cityName;
+
+    /**
+     * 年
+     */
     private Integer yearNo;
+
+    /**
+     * 月
+     */
     private Integer monthNo;
+
+    /**
+     * 房龄
+     */
     private Integer houseAge;
+
+    /**
+     * 上级土地名称
+     */
     private String landName;
+
+    /**
+     * 是否临街
+     */
     private String frontage;
+
+    /**
+     * 是否有院落
+     */
     private String courtyard;
+
+    /**
+     * 整栋是否独有
+     */
     private String wholeBuilding;
+
+    /**
+     * 是否有房产证
+     */
     private String propertyOwnershipCertificate;
+
+    /**
+     * 无房产证原因
+     */
     private String noPropertyOwnershipCertificateReason;
+
+    /**
+     * 未关联资产
+     */
     private String unrelatedAssets;
+
+    /**
+     * 楼长姓名
+     */
     private String communityAssistantName;
+
+    /**
+     * 楼长单位
+     */
     private String communityAssistantUnit;
+
+    /**
+     * 经度集团
+     */
     private BigDecimal lngJt;
+
+    /**
+     * 纬度集团
+     */
     private BigDecimal latJt;
+
+    /**
+     * 实际产权人
+     */
     private String propertyOwner;
+
+    /**
+     * 是否完成清查
+     */
     private String checked;
+
+    /**
+     * 地市id
+     */
     private String cityId;
+
+    /**
+     * 区县id
+     */
     private String districtId;
 }

+ 21 - 0
src/main/java/com/example/entity/house/HouseSiteBuildingAreaIdleDiffPo.java

@@ -0,0 +1,21 @@
+package com.example.entity.house;
+
+import lombok.Data;
+
+import java.math.BigDecimal;
+
+@Data
+public class HouseSiteBuildingAreaIdleDiffPo {
+    /**
+     * 房屋面积闲置率-年初
+     */
+    private BigDecimal buildingAreaIdleRatePast;
+    /**
+     * 房屋面积闲置率-当期
+     */
+    private BigDecimal buildingAreaIdleRateNow;
+    /**
+     * 房屋面积闲置率-变化率
+     */
+    private BigDecimal buildingAreaIdleRateDiff;
+}

+ 106 - 0
src/main/java/com/example/entity/house/HouseSitePo.java

@@ -0,0 +1,106 @@
+package com.example.entity.house;
+
+import lombok.Data;
+
+@Data
+public class HouseSitePo {
+    /**
+     * 数据年月
+     */
+    private Integer yearMonth;
+
+    /**
+     * 局址ID
+     */
+    private String siteId;
+
+    /**
+     * 资产所属单位(一级)
+     */
+    private String firstUnit;
+
+    /**
+     * 资产所属单位(二级)
+     */
+    private String secondUnit;
+
+    /**
+     * 资产所属单位(三级)
+     */
+    private String thirdUnit;
+
+    /**
+     * 局址编号
+     */
+    private String siteNum;
+
+    /**
+     * 局址别名
+     */
+    private String siteName;
+
+    /**
+     * 标准地址
+     */
+    private String address;
+
+    /**
+     * 城市等级
+     */
+    private String cityLevel;
+
+    /**
+     * 城市区域
+     */
+    private String cityRegion;
+
+    /**
+     * 地段
+     */
+    private String areaSector;
+
+    /**
+     * 是否有土地资产
+     */
+    private String hasLand;
+
+    /**
+     * 二级组织机构编码
+     */
+    private String areaNo;
+
+    /**
+     * 二级组织机构名称
+     */
+    private String areaName;
+
+    /**
+     * 三级组织机构编码
+     */
+    private String cityNo;
+
+    /**
+     * 三级组织机构名称
+     */
+    private String cityName;
+
+    /**
+     * 地市id
+     */
+    private String cityId;
+
+    /**
+     * 地市
+     */
+    private String city;
+
+    /**
+     * 区县id
+     */
+    private String districtId;
+
+    /**
+     * 区县
+     */
+    private String district;
+}

+ 17 - 0
src/main/java/com/example/entity/house/HouseSiteRepairInvestorStatPo.java

@@ -0,0 +1,17 @@
+package com.example.entity.house;
+
+import lombok.Data;
+
+import java.math.BigDecimal;
+
+@Data
+public class HouseSiteRepairInvestorStatPo {
+    /**
+     * 上市累计-房屋维修费
+     */
+    private BigDecimal buildingRepairSs;
+    /**
+     * 存续累计-房屋维修费
+     */
+    private BigDecimal buildingRepairCx;
+}

+ 17 - 0
src/main/java/com/example/entity/house/HouseSiteRepairMonthPo.java

@@ -0,0 +1,17 @@
+package com.example.entity.house;
+
+import lombok.Data;
+
+import java.math.BigDecimal;
+
+@Data
+public class HouseSiteRepairMonthPo {
+    /**
+     * 维修月份
+     */
+    private Integer monthNo;
+    /**
+     * 维修费
+     */
+    private BigDecimal finalCostSum;
+}

+ 1 - 1
src/main/java/com/example/pojo/bo/ListBuildingIdleBo.java

@@ -5,7 +5,7 @@ import lombok.Data;
 
 @Data
 public class ListBuildingIdleBo {
-    @Schema(description = "账期")
+    @Schema(description = "账期", example = "202312")
     private Integer yearMonth;
     @Schema(description = "二级组织机构编码")
     private String areaNo;

+ 27 - 0
src/main/java/com/example/pojo/bo/ListHouseSiteBo.java

@@ -0,0 +1,27 @@
+package com.example.pojo.bo;
+
+import lombok.Data;
+
+@Data
+public class ListHouseSiteBo {
+    /**
+     * 账期
+     */
+    private Integer yearMonth;
+    /**
+     * 二级组织机构编码
+     */
+    private String areaNo;
+    /**
+     * 三级组织机构编码
+     */
+    private String cityNo;
+    /**
+     * 局址编号
+     */
+    private String siteNum;
+    /**
+     * 局址别名
+     */
+    private String siteName;
+}

+ 30 - 0
src/main/java/com/example/pojo/dto/GetSiteStatDto.java

@@ -0,0 +1,30 @@
+package com.example.pojo.dto;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import javax.validation.Valid;
+import javax.validation.constraints.NotNull;
+
+@NoArgsConstructor
+@Data
+public class GetSiteStatDto {
+    @Valid
+    @NotNull
+    private GetSiteStatMapDTO map;
+
+    @NoArgsConstructor
+    @Data
+    public static class GetSiteStatMapDTO {
+        @Schema(description = "账期", example = "202312")
+        @NotNull
+        private Integer statisticalMonth;
+        @Schema(description = "二级组织机构id")
+        private String city;
+        @Schema(description = "三级级组织机构id")
+        private String county;
+        @Schema(description = "局址id")
+        private String siteId;
+    }
+}

+ 3 - 3
src/main/java/com/example/pojo/dto/ListBuildingHighRepairDto.java

@@ -15,12 +15,12 @@ public class ListBuildingHighRepairDto {
     @Valid
     private Page page;
     @Valid
-    private MapDTO map;
+    private ListBuildingHighRepairMapDTO map;
 
     @NoArgsConstructor
     @Data
-    public static class MapDTO {
-        @Schema(description = "账期")
+    public static class ListBuildingHighRepairMapDTO {
+        @Schema(description = "账期", example = "202312")
         private Integer statisticalMonth;
         @Schema(description = "二级组织机构id")
         private String city;

+ 3 - 3
src/main/java/com/example/pojo/dto/ListBuildingHighSporadicRepairDto.java

@@ -15,12 +15,12 @@ public class ListBuildingHighSporadicRepairDto {
     @Valid
     private Page page;
     @Valid
-    private MapDTO map;
+    private ListBuildingHighSporadicRepairMapDTO map;
 
     @NoArgsConstructor
     @Data
-    public static class MapDTO {
-        @Schema(description = "账期")
+    public static class ListBuildingHighSporadicRepairMapDTO {
+        @Schema(description = "账期", example = "202312")
         private Integer statisticalMonth;
         @Schema(description = "二级组织机构id")
         private String city;

+ 3 - 3
src/main/java/com/example/pojo/dto/ListBuildingIdleDto.java

@@ -15,12 +15,12 @@ public class ListBuildingIdleDto {
     @Valid
     private Page page;
     @Valid
-    private MapDTO map;
+    private ListBuildingIdleMapDTO map;
 
     @NoArgsConstructor
     @Data
-    public static class MapDTO {
-        @Schema(description = "账期")
+    public static class ListBuildingIdleMapDTO {
+        @Schema(description = "账期", example = "202312")
         private Integer statisticalMonth;
         @Schema(description = "二级组织机构id")
         private String city;

+ 3 - 3
src/main/java/com/example/pojo/dto/ListBuildingSameRepairFrequencyDto.java

@@ -15,12 +15,12 @@ public class ListBuildingSameRepairFrequencyDto {
     @Valid
     private Page page;
     @Valid
-    private MapDTO map;
+    private ListBuildingSameRepairFrequencyMapDTO map;
 
     @NoArgsConstructor
     @Data
-    public static class MapDTO {
-        @Schema(description = "账期")
+    public static class ListBuildingSameRepairFrequencyMapDTO {
+        @Schema(description = "账期", example = "202312")
         private Integer statisticalMonth;
         @Schema(description = "二级组织机构id")
         private String city;

+ 34 - 0
src/main/java/com/example/pojo/dto/ListSiteNameDto.java

@@ -0,0 +1,34 @@
+package com.example.pojo.dto;
+
+import com.example.utils.Page;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import javax.validation.Valid;
+import javax.validation.constraints.NotNull;
+
+@NoArgsConstructor
+@Data
+public class ListSiteNameDto {
+    @Valid
+    @NotNull
+    private Page page;
+    @Valid
+    @NotNull
+    private ListSiteNameMapDTO map;
+
+    @NoArgsConstructor
+    @Data
+    public static class ListSiteNameMapDTO {
+        @Schema(description = "账期", example = "202312")
+        @NotNull
+        private Integer statisticalMonth;
+        @Schema(description = "二级组织机构id")
+        private String city;
+        @Schema(description = "三级级组织机构id")
+        private String county;
+        @Schema(description = "关键词")
+        private String alias;
+    }
+}

+ 34 - 0
src/main/java/com/example/pojo/dto/ListSiteNumDto.java

@@ -0,0 +1,34 @@
+package com.example.pojo.dto;
+
+import com.example.utils.Page;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import javax.validation.Valid;
+import javax.validation.constraints.NotNull;
+
+@NoArgsConstructor
+@Data
+public class ListSiteNumDto {
+    @Valid
+    @NotNull
+    private Page page;
+    @Valid
+    @NotNull
+    private ListSiteNumMapDTO map;
+
+    @NoArgsConstructor
+    @Data
+    public static class ListSiteNumMapDTO {
+        @Schema(description = "账期", example = "202312")
+        @NotNull
+        private Integer statisticalMonth;
+        @Schema(description = "二级组织机构id")
+        private String city;
+        @Schema(description = "三级级组织机构id")
+        private String county;
+        @Schema(description = "关键词")
+        private String code;
+    }
+}

+ 53 - 0
src/main/java/com/example/pojo/vo/GetSiteStatBuildingVo.java

@@ -0,0 +1,53 @@
+package com.example.pojo.vo;
+
+import com.example.entity.house.HouseBuildingPo;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+
+@NoArgsConstructor
+@Data
+public class GetSiteStatBuildingVo {
+    @Schema(description = "建筑id")
+    private String buildingId;
+    @Schema(description = "建筑别名")
+    private String buildingName;
+    @Schema(description = "房龄开始日期")
+    private Integer houseYearBegan;
+    @Schema(description = "投资主体")
+    private String investor;
+    @Schema(description = "楼层总数")
+    private String totalFloors;
+    @Schema(description = "资产编号")
+    private String assetsNum;
+    @Schema(description = "建筑用途")
+    private String buildingUse;
+    @Schema(description = "自建面积")
+    private BigDecimal buildingArea;
+    @Schema(description = "自用面积")
+    private BigDecimal buildingAreaSelfUse;
+    @Schema(description = "出租面积")
+    private BigDecimal buildingAreaRent;
+    @Schema(description = "闲置面积")
+    private BigDecimal buildingAreaIdle;
+    @Schema(description = "资产原值")
+    private BigDecimal initialAssetValue;
+    @Schema(description = "累计折旧")
+    private BigDecimal accumulatedDepreciation;
+
+    public GetSiteStatBuildingVo(HouseBuildingPo po) {
+        this.buildingId = po.getBuildingId();
+        this.buildingName = po.getBuildingName();
+        this.houseYearBegan = po.getHouseYearBegan();
+        this.investor = po.getInvestor();
+        this.totalFloors = po.getTotalFloors();
+        this.assetsNum = po.getAssetsNum();
+        this.buildingUse = po.getBuildingUse();
+        this.buildingArea = po.getBuildingArea();
+        this.buildingAreaSelfUse = po.getBuildingAreaSelfUse();
+        this.buildingAreaRent = po.getBuildingAreaRent();
+        this.buildingAreaIdle = po.getBuildingAreaIdle();
+    }
+}

+ 109 - 0
src/main/java/com/example/pojo/vo/GetSiteStatVo.java

@@ -0,0 +1,109 @@
+package com.example.pojo.vo;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+import java.util.LinkedHashMap;
+import java.util.List;
+
+@NoArgsConstructor
+@Data
+public class GetSiteStatVo {
+    /**
+     * 基础信息
+     */
+    @Schema(description = "局址编号")
+    private String siteNum;
+    @Schema(description = "局址别名")
+    private String siteName;
+    @Schema(description = "所属市区")
+    private String areaName;
+    @Schema(description = "所属区县")
+    private String cityName;
+    @Schema(description = "局址地址")
+    private String address;
+    @Schema(description = "所处地段")
+    private String areaSector;
+    @Schema(description = "建筑数量")
+    private Integer buildingCount;
+    @Schema(description = "建筑面积")
+    private BigDecimal buildingAreaSum;
+    @Schema(description = "土地面积")
+    private BigDecimal landAreaSum;
+    @Schema(description = "办公人数")
+    private Integer staffCount;
+    @Schema(description = "建筑面积-自用")
+    private BigDecimal buildingAreaSelfUseSum;
+    @Schema(description = "建筑面积-出租")
+    private BigDecimal buildingAreaRentSum;
+    @Schema(description = "建筑面积-闲置")
+    private BigDecimal buildingAreaIdleSum;
+    @Schema(description = "建筑面积-不可使用")
+    private BigDecimal buildingAreaUnusableSum;
+    /**
+     * 建筑信息
+     */
+    @Schema(description = "建筑列表")
+    List<GetSiteStatBuildingVo> buildingList;
+    /**
+     * 出租信息
+     */
+    @Schema(description = "上市累计-对外出租收入")
+    private BigDecimal rentOutIncomeSs;
+    @Schema(description = "上市累计-对外出租累计欠费")
+    private BigDecimal rentOutArrearsSs;
+    @Schema(description = "上市累计-水电取暖等杂费欠费")
+    private BigDecimal incidentalsArrearsSs;
+    @Schema(description = "存续累计-对外出租收入")
+    private BigDecimal rentOutIncomeCx;
+    @Schema(description = "存续累计-对外出租累计欠费")
+    private BigDecimal rentOutArrearsCx;
+    @Schema(description = "存续累计-水电取暖等杂费欠费")
+    private BigDecimal incidentalsArrearsCx;
+    @Schema(description = "对外出租收入(上市)分月数据")
+    private LinkedHashMap<String, BigDecimal> rentOutIncomeSsMonth;
+    @Schema(description = "对外出租欠费(上市)分月数据")
+    private LinkedHashMap<String, BigDecimal> rentOutArrearsSsMonth;
+    @Schema(description = "对外出租收入(存续)分月数据")
+    private LinkedHashMap<String, BigDecimal> rentOutIncomeCxMonth;
+    @Schema(description = "对外出租欠费(存续)分月数据")
+    private LinkedHashMap<String, BigDecimal> rentOutArrearsCxMonth;
+    /**
+     * 费用信息
+     */
+    @Schema(description = "上市累计-房屋维修费")
+    private BigDecimal buildingRepairSs;
+    @Schema(description = "上市累计-物业管理费")
+    private BigDecimal propertyFeeSs;
+    @Schema(description = "存续累计-房屋维修费")
+    private BigDecimal buildingRepairCx;
+    @Schema(description = "存续累计-物业管理费")
+    private BigDecimal propertyFeeCx;
+    @Schema(description = "房屋维修费分月数据")
+    private LinkedHashMap<String, BigDecimal> buildingRepairMonth;
+    @Schema(description = "物业管理费分月数据")
+    private LinkedHashMap<String, BigDecimal> propertyFeeMonth;
+    /**
+     * 评价信息
+     */
+    @Schema(description = "自有房产人均办公面积-年初")
+    private BigDecimal officeAreaAvgPast;
+    @Schema(description = "自有房产人均办公面积-当期")
+    private BigDecimal officeAreaAvgNow;
+    @Schema(description = "自有房产人均办公面积-变化率")
+    private BigDecimal officeAreaAvgDiff;
+    @Schema(description = "对外出租平均单价-年初")
+    private BigDecimal rentOutUnitPriceAvgPast;
+    @Schema(description = "对外出租平均单价-当期")
+    private BigDecimal rentOutUnitPriceAvgNow;
+    @Schema(description = "对外出租平均单价-变化率")
+    private BigDecimal rentOutUnitPriceAvgDiff;
+    @Schema(description = "房屋面积闲置率-年初")
+    private BigDecimal buildingAreaIdleRatePast;
+    @Schema(description = "房屋面积闲置率-当期")
+    private BigDecimal buildingAreaIdleRateNow;
+    @Schema(description = "房屋面积闲置率-变化率")
+    private BigDecimal buildingAreaIdleRateDiff;
+}

+ 1 - 1
src/main/java/com/example/pojo/vo/ListBuildingIdleVo.java

@@ -9,7 +9,7 @@ import java.text.DecimalFormat;
 
 @Data
 public class ListBuildingIdleVo {
-    @Schema(description = "账期")
+    @Schema(description = "账期", example = "202312")
     private Integer statisticalMonth;
     @Schema(description = "资产所属单位一级")
     private String province;

+ 1 - 1
src/main/java/com/example/pojo/vo/ListBuildingSameRepairFrequencyVo.java

@@ -6,7 +6,7 @@ import lombok.Data;
 
 @Data
 public class ListBuildingSameRepairFrequencyVo {
-    @Schema(description = "账期")
+    @Schema(description = "账期", example = "202312")
     private Integer time;
     @Schema(description = "维修类型")
     private String repairType;

+ 18 - 0
src/main/java/com/example/pojo/vo/ListSiteNameVo.java

@@ -0,0 +1,18 @@
+package com.example.pojo.vo;
+
+import com.example.entity.house.HouseSitePo;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+
+@Data
+public class ListSiteNameVo {
+    @Schema(description = "局址id")
+    private String siteId;
+    @Schema(description = "局址别名")
+    private String siteName;
+
+    public ListSiteNameVo(HouseSitePo po) {
+        this.siteId = po.getSiteId();
+        this.siteName = po.getSiteName();
+    }
+}

+ 18 - 0
src/main/java/com/example/pojo/vo/ListSiteNumVo.java

@@ -0,0 +1,18 @@
+package com.example.pojo.vo;
+
+import com.example.entity.house.HouseSitePo;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+
+@Data
+public class ListSiteNumVo {
+    @Schema(description = "局址id")
+    private String siteId;
+    @Schema(description = "局址编号")
+    private String siteNum;
+
+    public ListSiteNumVo(HouseSitePo po) {
+        this.siteId = po.getSiteId();
+        this.siteNum = po.getSiteNum();
+    }
+}

+ 122 - 0
src/main/java/com/example/service/house/HouseSiteStatService.java

@@ -0,0 +1,122 @@
+package com.example.service.house;
+
+import com.example.common.Rsp;
+import com.example.dao.house.HouseSiteStatDao;
+import com.example.entity.house.HouseBuildingPo;
+import com.example.entity.house.HouseSiteBuildingAreaIdleDiffPo;
+import com.example.entity.house.HouseSitePo;
+import com.example.entity.house.HouseSiteRepairInvestorStatPo;
+import com.example.entity.house.HouseSiteRepairMonthPo;
+import com.example.pojo.dto.GetSiteStatDto;
+import com.example.pojo.vo.GetSiteStatBuildingVo;
+import com.example.pojo.vo.GetSiteStatVo;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Service;
+import org.springframework.util.StringUtils;
+
+import java.math.BigDecimal;
+import java.time.LocalDate;
+import java.time.format.DateTimeFormatter;
+import java.util.ArrayList;
+import java.util.LinkedHashMap;
+import java.util.List;
+
+@Slf4j
+@Service
+public class HouseSiteStatService {
+    private final HouseSiteStatDao houseSiteStatDao;
+
+    public HouseSiteStatService(HouseSiteStatDao houseSiteStatDao) {
+        this.houseSiteStatDao = houseSiteStatDao;
+    }
+
+    public Rsp<GetSiteStatVo> getSiteStat(GetSiteStatDto dto) {
+        GetSiteStatVo vo = getSiteStatVo(dto);
+        return Rsp.ok(vo);
+    }
+
+    private GetSiteStatVo getSiteStatVo(GetSiteStatDto dto) {
+        GetSiteStatVo vo = new GetSiteStatVo();
+        Integer endYearMonth = dto.getMap().getStatisticalMonth();
+        LocalDate localDateEnd = LocalDate.parse(endYearMonth + "01", DateTimeFormatter.ofPattern("yyyyMMdd"));
+        LocalDate localDateStart = localDateEnd.withDayOfYear(1);
+        Integer startYearMonth = Integer.valueOf(localDateStart.format(DateTimeFormatter.ofPattern("yyyyMM")));
+        int endMonth = localDateEnd.getMonthValue();
+        String siteId = dto.getMap().getSiteId();
+        // 默认燕赵信息大厦
+        if (!StringUtils.hasText(siteId)) {
+            siteId = "2017042617021008131986";
+        }
+        // 查询局址信息
+        HouseSitePo houseSitePo = houseSiteStatDao.getHouseSiteBySiteIdAndYearMonth(endYearMonth, siteId);
+        vo.setSiteNum(houseSitePo.getSiteNum());
+        vo.setSiteName(houseSitePo.getSiteName());
+        vo.setAreaName(houseSitePo.getAreaName());
+        vo.setCityName(houseSitePo.getCityName());
+        vo.setAddress(houseSitePo.getAddress());
+        vo.setAreaSector(houseSitePo.getAreaSector());
+        // 查询局址下的所有建筑
+        List<HouseBuildingPo> houseBuildingPoList = houseSiteStatDao.allBuildingBySiteIdAndYearMonth(endYearMonth,
+                siteId);
+        BigDecimal buildingAreaSum = BigDecimal.ZERO;
+        BigDecimal buildingAreaSelfUseSum = BigDecimal.ZERO;
+        BigDecimal buildingAreaRentSum = BigDecimal.ZERO;
+        BigDecimal buildingAreaIdleSum = BigDecimal.ZERO;
+        BigDecimal buildingAreaUnusableSum = BigDecimal.ZERO;
+        List<GetSiteStatBuildingVo> buildingList = new ArrayList<>();
+        vo.setBuildingList(buildingList);
+        for (HouseBuildingPo houseBuildingPo : houseBuildingPoList) {
+            buildingList.add(new GetSiteStatBuildingVo(houseBuildingPo));
+            // 计算局址建筑面积
+            if (houseBuildingPo.getBuildingArea() != null) {
+                buildingAreaSum = buildingAreaSum.add(houseBuildingPo.getBuildingArea());
+            }
+            if (houseBuildingPo.getBuildingAreaSelfUse() != null) {
+                buildingAreaSelfUseSum = buildingAreaSelfUseSum.add(houseBuildingPo.getBuildingAreaSelfUse());
+            }
+            if (houseBuildingPo.getBuildingAreaRent() != null) {
+                buildingAreaRentSum = buildingAreaRentSum.add(houseBuildingPo.getBuildingAreaRent());
+            }
+            if (houseBuildingPo.getBuildingAreaIdle() != null) {
+                buildingAreaIdleSum = buildingAreaIdleSum.add(houseBuildingPo.getBuildingAreaIdle());
+            }
+            if (houseBuildingPo.getBuildingAreaUnusable() != null) {
+                buildingAreaUnusableSum = buildingAreaUnusableSum.add(houseBuildingPo.getBuildingAreaUnusable());
+            }
+        }
+        vo.setBuildingCount(buildingList.size());
+        vo.setBuildingAreaSum(buildingAreaSum);
+        vo.setBuildingAreaSelfUseSum(buildingAreaSelfUseSum);
+        vo.setBuildingAreaRentSum(buildingAreaRentSum);
+        vo.setBuildingAreaIdleSum(buildingAreaIdleSum);
+        vo.setBuildingAreaUnusableSum(buildingAreaUnusableSum);
+        // 查询局址土地总面积
+        BigDecimal landAreaSum = houseSiteStatDao.getLandAreaBySiteIdAndYearMonth(endYearMonth, siteId);
+        vo.setLandAreaSum(landAreaSum == null ? BigDecimal.ZERO : landAreaSum);
+        // 查询房屋维修费累计
+        HouseSiteRepairInvestorStatPo houseSiteRepairInvestorStatPo
+                = houseSiteStatDao.getSiteRepairInvestorStat(startYearMonth, endYearMonth, siteId);
+        vo.setBuildingRepairSs(houseSiteRepairInvestorStatPo.getBuildingRepairSs());
+        vo.setBuildingRepairCx(houseSiteRepairInvestorStatPo.getBuildingRepairCx());
+        // 查询局址分月维修费
+        List<HouseSiteRepairMonthPo> houseSiteRepairMonthPoList
+                = houseSiteStatDao.getHouseSiteRepairMonth(startYearMonth, endYearMonth, siteId);
+        LinkedHashMap<String, BigDecimal> buildingRepairMonth = new LinkedHashMap<>();
+        vo.setBuildingRepairMonth(buildingRepairMonth);
+        for (int i = 1; i <= endMonth; i++) {
+            buildingRepairMonth.put(String.valueOf(i), BigDecimal.ZERO);
+            for (HouseSiteRepairMonthPo houseSiteRepairMonthPo : houseSiteRepairMonthPoList) {
+                if (houseSiteRepairMonthPo.getMonthNo().equals(i) && houseSiteRepairMonthPo.getFinalCostSum() != null) {
+                    buildingRepairMonth.put(String.valueOf(i), houseSiteRepairMonthPo.getFinalCostSum());
+                }
+            }
+        }
+        // 查询局址房屋面积闲置率变化
+        HouseSiteBuildingAreaIdleDiffPo houseSiteBuildingAreaIdleDiffPo
+                = houseSiteStatDao.getSiteBuildingAreaIdleDiff(startYearMonth, endYearMonth, siteId);
+        vo.setBuildingAreaIdleRatePast(houseSiteBuildingAreaIdleDiffPo.getBuildingAreaIdleRatePast());
+        vo.setBuildingAreaIdleRateNow(houseSiteBuildingAreaIdleDiffPo.getBuildingAreaIdleRateNow());
+        vo.setBuildingAreaIdleRateDiff(houseSiteBuildingAreaIdleDiffPo.getBuildingAreaIdleRateDiff());
+        return vo;
+    }
+}

+ 58 - 6
src/main/java/com/example/service/house/HouseWzBuildManageDetailsService.java

@@ -3,15 +3,20 @@ package com.example.service.house;
 import cn.hutool.core.net.URLEncodeUtil;
 import com.baomidou.mybatisplus.core.metadata.OrderItem;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.example.common.PageVo;
+import com.example.common.Rsp;
+import com.example.dao.WzOtnAreaDao;
 import com.example.dao.house.HouseBuildingDao;
 import com.example.entity.house.HouseBuildingPo;
+import com.example.entity.house.HouseSitePo;
 import com.example.enums.ListBuildingIdleOrderEnum;
 import com.example.enums.OrderEnum;
 import com.example.pojo.bo.ListBuildingIdleBo;
+import com.example.pojo.bo.ListHouseSiteBo;
 import com.example.pojo.dto.ListBuildingIdleDto;
+import com.example.pojo.dto.ListSiteNameDto;
+import com.example.pojo.dto.ListSiteNumDto;
 import com.example.pojo.vo.ListBuildingIdleVo;
-import com.example.utils.PageUtils;
-import com.example.utils.R;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.poi.ss.usermodel.Cell;
 import org.apache.poi.ss.usermodel.CellStyle;
@@ -27,6 +32,7 @@ import org.springframework.web.context.request.RequestContextHolder;
 import org.springframework.web.context.request.ServletRequestAttributes;
 
 import javax.servlet.http.HttpServletResponse;
+import java.time.LocalDate;
 import java.time.LocalDateTime;
 import java.time.format.DateTimeFormatter;
 import java.util.ArrayList;
@@ -38,20 +44,22 @@ import java.util.stream.Stream;
 @Service
 public class HouseWzBuildManageDetailsService {
     private final HouseBuildingDao houseBuildingDao;
+    private final WzOtnAreaDao wzOtnAreaDao;
 
-    public HouseWzBuildManageDetailsService(HouseBuildingDao houseBuildingDao) {
+    public HouseWzBuildManageDetailsService(HouseBuildingDao houseBuildingDao, WzOtnAreaDao wzOtnAreaDao) {
         this.houseBuildingDao = houseBuildingDao;
+        this.wzOtnAreaDao = wzOtnAreaDao;
     }
 
-    public R ideList(ListBuildingIdleDto dto) {
+    public Rsp<PageVo<ListBuildingIdleVo>> ideList(ListBuildingIdleDto dto) {
         Page<HouseBuildingPo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
         List<HouseBuildingPo> list = getBuildingIdle(dto, page);
         List<ListBuildingIdleVo> vos = new ArrayList<>();
         for (HouseBuildingPo po : list) {
             vos.add(new ListBuildingIdleVo(po));
         }
-        PageUtils pageUtil = new PageUtils(vos, page);
-        return R.ok().put("page", pageUtil);
+        PageVo<ListBuildingIdleVo> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
     }
 
     public void ideListExport(ListBuildingIdleDto dto) {
@@ -371,4 +379,48 @@ public class HouseWzBuildManageDetailsService {
             }
         }
     }
+
+    public Rsp<PageVo<String>> listSiteName(ListSiteNameDto dto) {
+        Integer yearMonth = dto.getMap().getStatisticalMonth();
+        if (yearMonth == null) {
+            yearMonth = Integer.valueOf(LocalDate.now().minusDays(40)
+                    .format(DateTimeFormatter.ofPattern("yyyyMM")));
+        }
+        if ("全省".equals(dto.getMap().getCity())) {
+            dto.getMap().setCity(null);
+            dto.getMap().setCounty(null);
+        }
+        ListHouseSiteBo bo = new ListHouseSiteBo();
+        bo.setYearMonth(yearMonth);
+        bo.setAreaNo(dto.getMap().getCity());
+        bo.setCityNo(dto.getMap().getCounty());
+        bo.setSiteName(dto.getMap().getAlias());
+        Page<HouseSitePo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
+        List<HouseSitePo> list = wzOtnAreaDao.listHouseSite(page, bo);
+        List<String> vos = list.stream().map(HouseSitePo::getSiteName).toList();
+        PageVo<String> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
+    }
+
+    public Rsp<PageVo<String>> listSiteNum(ListSiteNumDto dto) {
+        Integer yearMonth = dto.getMap().getStatisticalMonth();
+        if (yearMonth == null) {
+            yearMonth = Integer.valueOf(LocalDate.now().minusDays(40)
+                    .format(DateTimeFormatter.ofPattern("yyyyMM")));
+        }
+        if ("全省".equals(dto.getMap().getCity())) {
+            dto.getMap().setCity(null);
+            dto.getMap().setCounty(null);
+        }
+        ListHouseSiteBo bo = new ListHouseSiteBo();
+        bo.setYearMonth(yearMonth);
+        bo.setAreaNo(dto.getMap().getCity());
+        bo.setCityNo(dto.getMap().getCounty());
+        bo.setSiteNum(dto.getMap().getCode());
+        Page<HouseSitePo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
+        List<HouseSitePo> list = wzOtnAreaDao.listHouseSite(page, bo);
+        List<String> vos = list.stream().map(HouseSitePo::getSiteNum).toList();
+        PageVo<String> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
+    }
 }

+ 64 - 12
src/main/java/com/example/service/house/HouseWzHouseMaintenaCostService.java

@@ -3,10 +3,14 @@ package com.example.service.house;
 import cn.hutool.core.net.URLEncodeUtil;
 import com.baomidou.mybatisplus.core.metadata.OrderItem;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.example.common.PageVo;
+import com.example.common.Rsp;
+import com.example.dao.WzOtnAreaDao;
 import com.example.dao.house.HouseRepairExceptionDao;
 import com.example.entity.house.HouseBuildingHighRepairPo;
 import com.example.entity.house.HouseBuildingHighSporadicRepairPo;
 import com.example.entity.house.HouseBuildingSameRepairFrequencyPo;
+import com.example.entity.house.HouseSitePo;
 import com.example.enums.ListBuildingHighRepairOrderEnum;
 import com.example.enums.ListBuildingHighSporadicRepairOrderEnum;
 import com.example.enums.ListBuildingSameRepairFrequencyOrderEnum;
@@ -14,14 +18,15 @@ import com.example.enums.OrderEnum;
 import com.example.pojo.bo.ListBuildingHighRepairBo;
 import com.example.pojo.bo.ListBuildingHighSporadicRepairBo;
 import com.example.pojo.bo.ListBuildingSameRepairFrequencyBo;
+import com.example.pojo.bo.ListHouseSiteBo;
 import com.example.pojo.dto.ListBuildingHighRepairDto;
 import com.example.pojo.dto.ListBuildingHighSporadicRepairDto;
 import com.example.pojo.dto.ListBuildingSameRepairFrequencyDto;
+import com.example.pojo.dto.ListSiteNameDto;
+import com.example.pojo.dto.ListSiteNumDto;
 import com.example.pojo.vo.ListBuildingHighRepairVo;
 import com.example.pojo.vo.ListBuildingHighSporadicRepairVo;
 import com.example.pojo.vo.ListBuildingSameRepairFrequencyVo;
-import com.example.utils.PageUtils;
-import com.example.utils.R;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.poi.ss.usermodel.Cell;
 import org.apache.poi.ss.usermodel.CellStyle;
@@ -37,6 +42,7 @@ import org.springframework.web.context.request.RequestContextHolder;
 import org.springframework.web.context.request.ServletRequestAttributes;
 
 import javax.servlet.http.HttpServletResponse;
+import java.time.LocalDate;
 import java.time.LocalDateTime;
 import java.time.format.DateTimeFormatter;
 import java.util.ArrayList;
@@ -48,20 +54,22 @@ import java.util.stream.Stream;
 @Service
 public class HouseWzHouseMaintenaCostService {
     private final HouseRepairExceptionDao houseRepairExceptionDao;
+    private final WzOtnAreaDao wzOtnAreaDao;
 
-    public HouseWzHouseMaintenaCostService(HouseRepairExceptionDao houseRepairExceptionDao) {
+    public HouseWzHouseMaintenaCostService(HouseRepairExceptionDao houseRepairExceptionDao, WzOtnAreaDao wzOtnAreaDao) {
         this.houseRepairExceptionDao = houseRepairExceptionDao;
+        this.wzOtnAreaDao = wzOtnAreaDao;
     }
 
-    public R queryHighPrice(ListBuildingHighRepairDto dto) {
+    public Rsp<PageVo<ListBuildingHighRepairVo>> queryHighPrice(ListBuildingHighRepairDto dto) {
         Page<HouseBuildingHighRepairPo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
         List<HouseBuildingHighRepairPo> list = getHouseBuildingHighRepairPos(dto, page);
         List<ListBuildingHighRepairVo> vos = new ArrayList<>();
         for (HouseBuildingHighRepairPo po : list) {
             vos.add(new ListBuildingHighRepairVo(po));
         }
-        PageUtils pageUtil = new PageUtils(vos, page);
-        return R.ok().put("page", pageUtil);
+        PageVo<ListBuildingHighRepairVo> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
     }
 
     public void queryHighPriceExport(ListBuildingHighRepairDto dto) {
@@ -243,15 +251,15 @@ public class HouseWzHouseMaintenaCostService {
         }
     }
 
-    public R queryHighFrequency(ListBuildingSameRepairFrequencyDto dto) {
+    public Rsp<PageVo<ListBuildingSameRepairFrequencyVo>> queryHighFrequency(ListBuildingSameRepairFrequencyDto dto) {
         Page<HouseBuildingSameRepairFrequencyPo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
         List<HouseBuildingSameRepairFrequencyPo> list = getHouseBuildingSameRepairFrequencyPos(dto, page);
         List<ListBuildingSameRepairFrequencyVo> vos = new ArrayList<>();
         for (HouseBuildingSameRepairFrequencyPo po : list) {
             vos.add(new ListBuildingSameRepairFrequencyVo(po));
         }
-        PageUtils pageUtil = new PageUtils(vos, page);
-        return R.ok().put("page", pageUtil);
+        PageVo<ListBuildingSameRepairFrequencyVo> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
     }
 
     /**
@@ -399,15 +407,15 @@ public class HouseWzHouseMaintenaCostService {
         }
     }
 
-    public R queryDailyModify(ListBuildingHighSporadicRepairDto dto) {
+    public Rsp<PageVo<ListBuildingHighSporadicRepairVo>> queryDailyModify(ListBuildingHighSporadicRepairDto dto) {
         Page<HouseBuildingHighSporadicRepairPo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
         List<HouseBuildingHighSporadicRepairPo> list = getHouseBuildingHighSporadicRepairPos(dto, page);
         List<ListBuildingHighSporadicRepairVo> vos = new ArrayList<>();
         for (HouseBuildingHighSporadicRepairPo po : list) {
             vos.add(new ListBuildingHighSporadicRepairVo(po));
         }
-        PageUtils pageUtil = new PageUtils(vos, page);
-        return R.ok().put("page", pageUtil);
+        PageVo<ListBuildingHighSporadicRepairVo> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
     }
 
     /**
@@ -547,4 +555,48 @@ public class HouseWzHouseMaintenaCostService {
             }
         }
     }
+
+    public Rsp<PageVo<String>> listSiteName(ListSiteNameDto dto) {
+        Integer yearMonth = dto.getMap().getStatisticalMonth();
+        if (yearMonth == null) {
+            yearMonth = Integer.valueOf(LocalDate.now().minusDays(40)
+                    .format(DateTimeFormatter.ofPattern("yyyyMM")));
+        }
+        if ("全省".equals(dto.getMap().getCity())) {
+            dto.getMap().setCity(null);
+            dto.getMap().setCounty(null);
+        }
+        ListHouseSiteBo bo = new ListHouseSiteBo();
+        bo.setYearMonth(yearMonth);
+        bo.setAreaNo(dto.getMap().getCity());
+        bo.setCityNo(dto.getMap().getCounty());
+        bo.setSiteName(dto.getMap().getAlias());
+        Page<HouseSitePo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
+        List<HouseSitePo> list = wzOtnAreaDao.listHouseSite(page, bo);
+        List<String> vos = list.stream().map(HouseSitePo::getSiteName).toList();
+        PageVo<String> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
+    }
+
+    public Rsp<PageVo<String>> listSiteNum(ListSiteNumDto dto) {
+        Integer yearMonth = dto.getMap().getStatisticalMonth();
+        if (yearMonth == null) {
+            yearMonth = Integer.valueOf(LocalDate.now().minusDays(40)
+                    .format(DateTimeFormatter.ofPattern("yyyyMM")));
+        }
+        if ("全省".equals(dto.getMap().getCity())) {
+            dto.getMap().setCity(null);
+            dto.getMap().setCounty(null);
+        }
+        ListHouseSiteBo bo = new ListHouseSiteBo();
+        bo.setYearMonth(yearMonth);
+        bo.setAreaNo(dto.getMap().getCity());
+        bo.setCityNo(dto.getMap().getCounty());
+        bo.setSiteNum(dto.getMap().getCode());
+        Page<HouseSitePo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
+        List<HouseSitePo> list = wzOtnAreaDao.listHouseSite(page, bo);
+        List<String> vos = list.stream().map(HouseSitePo::getSiteNum).toList();
+        PageVo<String> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
+    }
 }

+ 70 - 0
src/main/java/com/example/service/house/HouseWzLandManageDetailsService.java

@@ -0,0 +1,70 @@
+package com.example.service.house;
+
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.example.common.PageVo;
+import com.example.common.Rsp;
+import com.example.dao.WzOtnAreaDao;
+import com.example.entity.house.HouseSitePo;
+import com.example.pojo.bo.ListHouseSiteBo;
+import com.example.pojo.dto.ListSiteNameDto;
+import com.example.pojo.dto.ListSiteNumDto;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Service;
+
+import java.time.LocalDate;
+import java.time.format.DateTimeFormatter;
+import java.util.List;
+
+@Slf4j
+@Service
+public class HouseWzLandManageDetailsService {
+    private final WzOtnAreaDao wzOtnAreaDao;
+
+    public HouseWzLandManageDetailsService(WzOtnAreaDao wzOtnAreaDao) {
+        this.wzOtnAreaDao = wzOtnAreaDao;
+    }
+
+    public Rsp<PageVo<String>> listSiteName(ListSiteNameDto dto) {
+        Integer yearMonth = dto.getMap().getStatisticalMonth();
+        if (yearMonth == null) {
+            yearMonth = Integer.valueOf(LocalDate.now().minusDays(40)
+                    .format(DateTimeFormatter.ofPattern("yyyyMM")));
+        }
+        if ("全省".equals(dto.getMap().getCity())) {
+            dto.getMap().setCity(null);
+            dto.getMap().setCounty(null);
+        }
+        ListHouseSiteBo bo = new ListHouseSiteBo();
+        bo.setYearMonth(yearMonth);
+        bo.setAreaNo(dto.getMap().getCity());
+        bo.setCityNo(dto.getMap().getCounty());
+        bo.setSiteName(dto.getMap().getAlias());
+        Page<HouseSitePo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
+        List<HouseSitePo> list = wzOtnAreaDao.listHouseSite(page, bo);
+        List<String> vos = list.stream().map(HouseSitePo::getSiteName).toList();
+        PageVo<String> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
+    }
+
+    public Rsp<PageVo<String>> listSiteNum(ListSiteNumDto dto) {
+        Integer yearMonth = dto.getMap().getStatisticalMonth();
+        if (yearMonth == null) {
+            yearMonth = Integer.valueOf(LocalDate.now().minusDays(40)
+                    .format(DateTimeFormatter.ofPattern("yyyyMM")));
+        }
+        if ("全省".equals(dto.getMap().getCity())) {
+            dto.getMap().setCity(null);
+            dto.getMap().setCounty(null);
+        }
+        ListHouseSiteBo bo = new ListHouseSiteBo();
+        bo.setYearMonth(yearMonth);
+        bo.setAreaNo(dto.getMap().getCity());
+        bo.setCityNo(dto.getMap().getCounty());
+        bo.setSiteNum(dto.getMap().getCode());
+        Page<HouseSitePo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
+        List<HouseSitePo> list = wzOtnAreaDao.listHouseSite(page, bo);
+        List<String> vos = list.stream().map(HouseSitePo::getSiteNum).toList();
+        PageVo<String> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
+    }
+}

+ 50 - 1
src/main/java/com/example/service/house/HouseWzOtnAreaService.java

@@ -1,11 +1,23 @@
 package com.example.service.house;
 
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.example.common.PageVo;
+import com.example.common.Rsp;
 import com.example.dao.WzOtnAreaDao;
 import com.example.entity.OtnAreaEntity;
+import com.example.entity.house.HouseSitePo;
+import com.example.pojo.bo.ListHouseSiteBo;
+import com.example.pojo.dto.ListSiteNameDto;
+import com.example.pojo.dto.ListSiteNumDto;
+import com.example.pojo.vo.ListSiteNameVo;
+import com.example.pojo.vo.ListSiteNumVo;
 import com.example.utils.R;
 import lombok.extern.slf4j.Slf4j;
 import org.springframework.stereotype.Service;
+import org.springframework.util.StringUtils;
 
+import java.net.URLDecoder;
+import java.nio.charset.StandardCharsets;
 import java.util.List;
 
 @Slf4j
@@ -18,10 +30,47 @@ public class HouseWzOtnAreaService {
     }
 
     public R getCityOption(String id) {
-        if ("0".equals(id)) {
+        if (StringUtils.hasText(id)) {
+            id = URLDecoder.decode(id, StandardCharsets.UTF_8);
+        }
+        if ("0".equals(id) || "全省".equals(id)) {
             id = "018";
         }
         List<OtnAreaEntity> list = wzOtnAreaDao.listByParentId(id);
         return R.ok().put("list", list);
     }
+
+    public Rsp<PageVo<ListSiteNameVo>> listSiteName(ListSiteNameDto dto) {
+        if ("全省".equals(dto.getMap().getCity())) {
+            dto.getMap().setCity(null);
+            dto.getMap().setCounty(null);
+        }
+        ListHouseSiteBo bo = new ListHouseSiteBo();
+        bo.setYearMonth(dto.getMap().getStatisticalMonth());
+        bo.setAreaNo(dto.getMap().getCity());
+        bo.setCityNo(dto.getMap().getCounty());
+        bo.setSiteName(dto.getMap().getAlias());
+        Page<HouseSitePo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
+        List<HouseSitePo> list = wzOtnAreaDao.listHouseSite(page, bo);
+        List<ListSiteNameVo> vos = list.stream().map(ListSiteNameVo::new).toList();
+        PageVo<ListSiteNameVo> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
+    }
+
+    public Rsp<PageVo<ListSiteNumVo>> listSiteNum(ListSiteNumDto dto) {
+        if ("全省".equals(dto.getMap().getCity())) {
+            dto.getMap().setCity(null);
+            dto.getMap().setCounty(null);
+        }
+        ListHouseSiteBo bo = new ListHouseSiteBo();
+        bo.setYearMonth(dto.getMap().getStatisticalMonth());
+        bo.setAreaNo(dto.getMap().getCity());
+        bo.setCityNo(dto.getMap().getCounty());
+        bo.setSiteNum(dto.getMap().getCode());
+        Page<HouseSitePo> page = new Page<>(dto.getPage().getPageNum(), dto.getPage().getPageSize());
+        List<HouseSitePo> list = wzOtnAreaDao.listHouseSite(page, bo);
+        List<ListSiteNumVo> vos = list.stream().map(ListSiteNumVo::new).toList();
+        PageVo<ListSiteNumVo> pageVo = new PageVo<>(vos, page);
+        return Rsp.ok(pageVo);
+    }
 }

+ 7 - 0
src/main/java/com/example/utils/Page.java

@@ -1,9 +1,16 @@
 package com.example.utils;
 
+import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.Data;
 
+import javax.validation.constraints.NotNull;
+
 @Data
 public class Page {
+    @Schema(description = "页码", example = "1")
+    @NotNull
     private Integer pageNum;
+    @Schema(description = "每页个数", example = "10")
+    @NotNull
     private Integer pageSize;
 }

+ 26 - 0
src/test/java/com/example/MybatisPlusGeneratorTest.java

@@ -0,0 +1,26 @@
+package com.example;
+
+import com.baomidou.mybatisplus.generator.FastAutoGenerator;
+import com.baomidou.mybatisplus.generator.config.DataSourceConfig;
+import com.baomidou.mybatisplus.generator.engine.FreemarkerTemplateEngine;
+
+public class MybatisPlusGeneratorTest {
+    public static void main(String[] args) {
+        FastAutoGenerator.create(
+                new DataSourceConfig.Builder("jdbc:postgresql://172.16.107.5:5432/financialdb",
+                        "finance",
+                        "Finance@unicom23").schema("common"))
+                .globalConfig(builder -> {
+                    builder.outputDir("z:/").disableOpenDir();
+                })
+                .strategyConfig(builder -> {
+                    builder.addInclude("request_log")
+                            .entityBuilder()
+                            .disableSerialVersionUID()
+                            .enableFileOverride()
+                            .enableLombok();
+                })
+                .templateEngine(new FreemarkerTemplateEngine())
+                .execute();
+    }
+}