Commit d9798019 by songyinghui

feat: 文件模板

parent 3b2c5f4b
...@@ -4,6 +4,7 @@ import cn.hutool.core.collection.CollectionUtil; ...@@ -4,6 +4,7 @@ import cn.hutool.core.collection.CollectionUtil;
import cn.hutool.core.date.DateTime; import cn.hutool.core.date.DateTime;
import cn.hutool.core.date.DateUtil; import cn.hutool.core.date.DateUtil;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.gic.api.base.commons.Page; import com.gic.api.base.commons.Page;
import com.gic.haoban.manage.api.enums.content.MaterialReportType; import com.gic.haoban.manage.api.enums.content.MaterialReportType;
import com.gic.haoban.manage.web.qo.content.statistics.MaterialReportQO; import com.gic.haoban.manage.web.qo.content.statistics.MaterialReportQO;
...@@ -342,10 +343,18 @@ public class MaterialDataAdaptor { ...@@ -342,10 +343,18 @@ public class MaterialDataAdaptor {
return new Page<>(); return new Page<>();
} }
Page<MaterialStoreUsedDataVO> pageResult = new Page<>(); Page<MaterialStoreUsedDataVO> pageResult = new Page<>();
List<MaterialStoreUsedDataVO> materialStoreUsedDataVOS = JSON.parseArray(JSON.toJSONString(result.get("data")), MaterialStoreUsedDataVO.class); List<MaterialStoreUsedDataVO> materialStoreUsedDataVOS =null;
if (CollectionUtils.isEmpty(materialStoreUsedDataVOS)) { List<JSONObject> jsonObjects = JSON.parseArray(JSON.toJSONString(result.get("data")), JSONObject.class);
if (CollectionUtils.isEmpty(jsonObjects)) {
return new Page<>(); return new Page<>();
} }
jsonObjects.stream()
.map(item -> {
MaterialStoreUsedDataVO temp = JSONObject.parseObject(item.toJSONString(), MaterialStoreUsedDataVO.class);
//temp.setDayAvgUseMatlNum();
return temp;
})
.collect(Collectors.toList());
for (MaterialStoreUsedDataVO materialStoreUsedDataVO : materialStoreUsedDataVOS) { for (MaterialStoreUsedDataVO materialStoreUsedDataVO : materialStoreUsedDataVOS) {
materialStoreUsedDataVO.setStartTime(startTime); materialStoreUsedDataVO.setStartTime(startTime);
materialStoreUsedDataVO.setEndTime(endTime); materialStoreUsedDataVO.setEndTime(endTime);
......
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