Commit 1ba1fa62 by lijingjing

添加流程节点逻辑处理;

parent 9ed98c53
......@@ -467,7 +467,7 @@ public class EntrustSampleController extends ServiceController {
@ApiOperation("磷生铁统计查询")
@PostMapping("/p_make_fe_stats_query")
public RestResult<List<PMakeFeStatsVO>> getPMakeFeStatsQuery(QueryDTO queryDTO) {
public RestResult<Map> getPMakeFeStatsQuery(QueryDTO queryDTO) {
return success(entrustSampleService.getPMakeFeStatsQuery(queryDTO));
}
}
......@@ -14,6 +14,7 @@ import com.patzn.cloud.service.hmhj.vo.EntrustSampleVO;
import com.patzn.cloud.service.hmhj.vo.PMakeFeStatsVO;
import java.util.List;
import java.util.Map;
/**
* 服务类
......@@ -63,5 +64,5 @@ public interface IEntrustSampleService extends IBaseService<EntrustSample> {
List<ElectrolyteRatioStatsVO> getElectrolyteRatioStatsQuery(QueryDTO queryDTO);
List<PMakeFeStatsVO> getPMakeFeStatsQuery(QueryDTO queryDTO);
Map<String,Object> getPMakeFeStatsQuery(QueryDTO queryDTO);
}
......@@ -24,6 +24,8 @@ import com.patzn.cloud.service.lims.hmhj.service.*;
import com.patzn.cloud.commons.service.impl.BaseServiceImpl;
import com.patzn.poibox.xwpf.PoiUtil2007;
import com.patzn.poibox.xwpf.XWPFTemplate;
import org.apache.commons.collections.ListUtils;
import org.apache.commons.collections.MapUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.poi.ss.util.CellRangeAddress;
......@@ -44,6 +46,7 @@ import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.*;
import java.util.function.Function;
import java.util.stream.Collectors;
/**
......@@ -260,9 +263,27 @@ public class EntrustSampleServiceImpl extends BaseServiceImpl<EntrustSampleMappe
}
@Override
public List<PMakeFeStatsVO> getPMakeFeStatsQuery(QueryDTO queryDTO) {
public Map<String, Object> getPMakeFeStatsQuery(QueryDTO queryDTO) {
RestAssert.fail(null == queryDTO.getTimeS() || null == queryDTO.getTimeE(), "开始或结束时间为空");
return baseMapper.selectPMakeFeStats(queryDTO);
List<PMakeFeStatsVO> list = baseMapper.selectPMakeFeStats(queryDTO);
Map<String, Object> result = new HashMap<>();
if (CollectionUtils.isEmpty(list)) {
return result;
}
for (PMakeFeStatsVO vo : list) {
PMakeFeVO val = new PMakeFeVO(), per = new PMakeFeVO(), ltNum = new PMakeFeVO(), gtNum = new PMakeFeVO(), inNum = new PMakeFeVO();
val.setCVal(vo.getCVal()).setMnVal(vo.getMnVal()).setSiVal(vo.getSiVal()).setPVal(vo.getPVal()).setSVal(vo.getSVal());
per.setCVal(vo.getCPer()).setMnVal(vo.getMnPer()).setSiVal(vo.getSiPer()).setPVal(vo.getPPer()).setSVal(vo.getSPer());
ltNum.setCVal(vo.getCLtNum()).setMnVal(vo.getMnLtNum()).setSiVal(vo.getSiLtNum()).setPVal(vo.getPLtNum()).setSVal(vo.getSLtNum());
inNum.setCVal(vo.getCInNum()).setMnVal(vo.getMnInNum()).setSiVal(vo.getSiInNum()).setPVal(vo.getPInNum()).setSVal(vo.getSInNum());
gtNum.setCVal(vo.getCGtNum()).setMnVal(vo.getMnGtNum()).setSiVal(vo.getSiGtNum()).setPVal(vo.getPGtNum()).setSVal(vo.getSGtNum());
result.put(vo.getPeriod(), Lists.newArrayList(val, per, ltNum, inNum, gtNum));
}
return result;
}
@Override
......
ALTER TABLE "public"."material"
ALTER TABLE "public"."material"
ADD COLUMN "entrust_status_path" varchar(255) COLLATE "pg_catalog"."default";
COMMENT ON COLUMN "public"."material"."entrust_status_path" IS '委托状态范围';
ALTER TABLE "public"."entrust"
ADD COLUMN "status_path" varchar(255) COLLATE "pg_catalog"."default";
COMMENT ON COLUMN "public"."entrust"."status_path" IS '状态范围';
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment