b17b6cd0 张雷

Merge remote-tracking branch 'origin/master' into master

2 个父辈 fa509430 c9fc335e
......@@ -206,7 +206,7 @@ public class OperationReportServiceImpl implements IOperationReportService {
// 2: 隐患排查巡检:取风险点巡检记录里面巡检类型是生产巡检的数据
QueryWrapper<?> queryWrapper2 = new QueryWrapper<>();
queryWrapper2.eq("inspection_type", "1")
.eq("status", "2")
.eq("inspection_type", "4")
.ge("end_date", startDate + BusinessConstant.startTimeSuffix)
.le("end_date", endDate + BusinessConstant.endTimeSuffix);
List<Map<String, Object>> queryMapList2 = baseService.queryForList("select * from danger_inspection_record", queryWrapper2);
......
......@@ -192,17 +192,17 @@ public class EquipmentMaintainStandardController {
MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
Map<String, MultipartFile> fileMap = multipartRequest.getFileMap();
//构造机构字典
List<Map<String,Object>> departList = iEquipmentMaintainStandardService.getDepartList("group");
Map<String,String> departDictMap = new HashMap<String,String>();
departList.forEach(depart ->{
departDictMap.put(ConvertUtils.getString(depart.get("depart_name")), ConvertUtils.getString(depart.get("id")));
List<Map<String, Object>> departList = iEquipmentMaintainStandardService.getDepartList("group");
Map<String, String> departDictMap = new HashMap<String, String>();
departList.forEach(depart -> {
departDictMap.put(ConvertUtils.getString(depart.get("depart_name")), ConvertUtils.getString(depart.get("id")));
});
//构造设备类别字典
List<EquipmentCategory> equipmentCategoryList = equipmentCategoryService.list();
Map<String,String> equipmentCategoryDictMap = new HashMap<String,String>();
equipmentCategoryList.forEach(equipmentCategory ->{
equipmentCategoryDictMap.put(equipmentCategory.getTreePathName(), equipmentCategory.getId());
Map<String, String> equipmentCategoryDictMap = new HashMap<String, String>();
equipmentCategoryList.forEach(equipmentCategory -> {
equipmentCategoryDictMap.put(equipmentCategory.getTreePathName(), equipmentCategory.getId());
});
for (Map.Entry<String, MultipartFile> entity : fileMap.entrySet()) {
// 获取上传文件对象
......@@ -215,28 +215,11 @@ public class EquipmentMaintainStandardController {
List<EquipmentMaintainStandard> listsdEquipFailureRepairs = ExcelImportUtil.importExcel(multipartFile.getInputStream(), EquipmentMaintainStandard.class, params);
//根据设备类型查出对应id
listsdEquipFailureRepairs.forEach(e -> {
//获取一级类型
String top = e.getEquipmentTopType();
//获取二级类型
String second = e.getEquipmentSecondType();
//获取三级类型
String third = e.getEquipmentType();
StringBuffer sb = new StringBuffer();
if(StringUtils.isNotBlank(top)) {
sb.append("/"+top);
}
if(StringUtils.isNotBlank(second)) {
sb.append("/"+second);
}
if(StringUtils.isNotBlank(third)) {
sb.append("/"+third);
}
String key = sb.substring(1);
//机构字典翻译,并设置到保养库对象
e.setDepartId(departDictMap.get(e.getDepartId()));
//设备类型字典翻译,并设置到保养库对象
e.setEquipmentType(equipmentCategoryDictMap.get(key));
String third = e.getEquipmentType();
//机构字典翻译,并设置到保养库对象
e.setDepartId(departDictMap.get(e.getDepartId()));
//设备类型字典翻译,并设置到保养库对象
e.setEquipmentType(equipmentCategoryDictMap.get(third));
});
iEquipmentMaintainStandardService.addList(listsdEquipFailureRepairs);
return Result.ok("文件导入成功!数据行数:" + listsdEquipFailureRepairs.size());
......
......@@ -33,7 +33,7 @@ public class EquipmentMaintainStandard {
@Excel(name = "保养项", width = 15)
@ApiModelProperty(value = "保养项")
private String maintenanceType;
@Excel(name = "设备三级类型", width = 15)
@Excel(name = "设备类型", width = 15)
@ApiModelProperty(value = "设备类型")
private String equipmentType;
......@@ -41,8 +41,7 @@ public class EquipmentMaintainStandard {
@ApiModelProperty(value = "设备二级类型")
@TableField(exist = false)
private String equipmentSecondType;
@Excel(name = "设备类型", width = 15)
@ApiModelProperty(value = "设备一级类型")
@TableField(exist = false)
private String equipmentTopType;
......
......@@ -50,9 +50,9 @@ public class TaskPoolConfig {
public ThreadPoolTaskExecutor taskExecutor2() {
ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();
//配置核心线程数:就是线程池中的核心线程数量,这几个核心线程,只是在没有用的时候,也不会被回收
executor.setCorePoolSize(50);
executor.setCorePoolSize(100);
//配置最大线程数:就是线程池中可以容纳的最大线程的数量
executor.setMaxPoolSize(200);
executor.setMaxPoolSize(500);
//配置队列大小
executor.setQueueCapacity(500);
//线程池维护线程所允许的空闲时间:就是线程池中除了核心线程之外的其他的最长可以保留的时间,因为在线程池中,除了核心线程即使在无任务的情况下也不能被清除,其余的都是有存活时间的,意思就是非核心线程可以保留的最长的空闲时间
......
......@@ -160,6 +160,7 @@ public class MybatisInterceptor implements Interceptor {
|| "com.skua.modules.supplies.mapper.EquipmentSparepartSuppliesMapper.selectList".equals(sqlId) //物料
|| "com.skua.modules.erp.mapper.ERPPurchaseContractMapper.selectList".equals(sqlId) //采购合同列表
|| "com.skua.modules.erp.mapper.DistributContractMapper.selectList".equals(sqlId) //分销合同列表
|| "com.skua.modules.erp.mapper.ErpSettlementMapper.selectById".equals(sqlId) // 药剂结算单详情
|| "com.skua.modules.erp.mapper.ERPPurchaseContractMapper.getListByDistributId".equals(sqlId)
|| "com.skua.modules.system.datestandard.mapper.SysMonitorMetricInfoMapper.selectList".equals(sqlId) //点表
|| "com.skua.modules.equipment.mapper.EquipmentSparepartMapper.selectOne".equals(sqlId)
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!