| | |
| | | package com.terra.system.service.sys; |
| | | |
| | | import com.terra.common.helper.FileHelper; |
| | | import com.terra.common.helper.StringHelper; |
| | | import com.terra.common.helper.WebHelper; |
| | | import com.terra.system.entity.all.RedisCacheKey; |
| | | import com.terra.common.entity.all.StaticData; |
| | | import com.terra.system.entity.ctrl.CoordinateEntity; |
| | |
| | | import org.apache.commons.logging.LogFactory; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.util.StringUtils; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | |
| | | |
| | | @Override |
| | | public List<CountEntity> countVariousDataByPrj(String code) { |
| | | code = StringUtils.isEmpty(code) || "ALL".equals(code) ? null : StringHelper.getRightLike(code); |
| | | code = StringHelper.isEmpty(code) || "ALL".equals(code) ? null : StringHelper.getRightLike(code); |
| | | return reportMapper.countVariousDataByPrj(code); |
| | | } |
| | | |
| | |
| | | Double allSize = 0d, allArea = 0d, allLen = 0d; |
| | | for (CountEntity ce : list) { |
| | | ce.setNo(rows++); |
| | | if (StringUtils.isEmpty(ce.getM2())) { |
| | | if (StringHelper.isEmpty(ce.getM2())) { |
| | | ce.setM2(FileHelper.getSizes(ce.getSizes())); |
| | | } |
| | | ce.setM3(FileHelper.getSquareMeter(ce.getArea())); |
| | |
| | | ce.setNo(rows); |
| | | ce.setM1("总计"); |
| | | ce.setCount(allCount); |
| | | if (StringUtils.isEmpty(list.get(0).getM2())) { |
| | | if (StringHelper.isEmpty(list.get(0).getM2())) { |
| | | ce.setM2(FileHelper.getSizes(allSize)); |
| | | } |
| | | ce.setM3(FileHelper.getSquareMeter(allArea)); |