This commit is contained in:
parent
f5bc0c0e08
commit
d17284eef8
|
|
@ -92,6 +92,18 @@ public class MachineController extends BaseController {
|
||||||
return machineService.selectByTypeList(type);
|
return machineService.selectByTypeList(type);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* todo 材料站获取机具设备管理列表专用(未加组织机构条件筛选)
|
||||||
|
* @param type
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@ApiOperation(value = "查询机具设备管理列表2")
|
||||||
|
//@RequiresPermissions("ma:machine:typeList")
|
||||||
|
@GetMapping("/getMaterialTypeList")
|
||||||
|
public AjaxResult getMaterialTypeList(Type type) {
|
||||||
|
return machineService.selectByTypeList(type);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 导出机具设备管理列表
|
* 导出机具设备管理列表
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -616,6 +616,10 @@ public class RepairController extends BaseController {
|
||||||
if (Objects.isNull(bean)) {
|
if (Objects.isNull(bean)) {
|
||||||
bean = new RepairAuditDetails();
|
bean = new RepairAuditDetails();
|
||||||
}
|
}
|
||||||
|
String fileName = "修试审核明细";
|
||||||
|
if (bean.getStartTime() != null && bean.getEndTime() != null) {
|
||||||
|
fileName = "修试审核明细"+ "(时间" + bean.getStartTime() + "至" + bean.getEndTime()+ ")";
|
||||||
|
}
|
||||||
if (Objects.isNull(bean.getTaskType())) {
|
if (Objects.isNull(bean.getTaskType())) {
|
||||||
bean.setTaskType(TM_TASK_REPAIR_AUDIT.getTaskTypeId());
|
bean.setTaskType(TM_TASK_REPAIR_AUDIT.getTaskTypeId());
|
||||||
}
|
}
|
||||||
|
|
@ -639,6 +643,8 @@ public class RepairController extends BaseController {
|
||||||
|
|
||||||
|
|
||||||
ExcelUtil<RepairAuditDetailsExport> util = new ExcelUtil<>(RepairAuditDetailsExport.class);
|
ExcelUtil<RepairAuditDetailsExport> util = new ExcelUtil<>(RepairAuditDetailsExport.class);
|
||||||
util.exportExcel(response, listExport, "入库单", "入库单");
|
// 获取当前年月日时分秒导出时间,用括号拼接在后面
|
||||||
|
String title = "修试审核明细" + "(" + "导出时间:" + DateUtils.getTime() + ")";
|
||||||
|
util.exportExcel(response, listExport, fileName, title);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -42,7 +42,7 @@ public class RepairAuditDetailsExport {
|
||||||
private Long parentId;
|
private Long parentId;
|
||||||
|
|
||||||
@ApiModelProperty(value = "序号")
|
@ApiModelProperty(value = "序号")
|
||||||
@Excel(name = "序号", isSequence = true, sort = 0)
|
@Excel(name = "序号", isSequence = true, sort = 0, width = 5)
|
||||||
private String serialNumber;
|
private String serialNumber;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -256,4 +256,7 @@ public class RepairTask {
|
||||||
|
|
||||||
@ApiModelProperty(value = "规格id")
|
@ApiModelProperty(value = "规格id")
|
||||||
private String typeModelId;
|
private String typeModelId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "设备编码code集合")
|
||||||
|
private String maCode;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -160,12 +160,25 @@ public class RepairServiceImpl implements RepairService {
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
private boolean containsKeyword(RepairTask item, String keyWord) {
|
private boolean containsKeyword(RepairTask item, String keyWord) {
|
||||||
|
// 1. 处理maCode的分段匹配
|
||||||
|
boolean maCodeMatch = false;
|
||||||
|
if (item.getMaCode() != null && !keyWord.isEmpty()) {
|
||||||
|
String[] maCodeParts = item.getMaCode().split(",");
|
||||||
|
for (String part : maCodeParts) {
|
||||||
|
String trimedPart = part.trim();
|
||||||
|
if (trimedPart.contains(keyWord)) {
|
||||||
|
maCodeMatch = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
return (item.getType() != null && item.getType().contains(keyWord)) ||
|
return (item.getType() != null && item.getType().contains(keyWord)) ||
|
||||||
(item.getRepairCode() != null && item.getRepairCode().contains(keyWord)) ||
|
(item.getRepairCode() != null && item.getRepairCode().contains(keyWord)) ||
|
||||||
(item.getBackUnit() != null && item.getBackUnit().contains(keyWord)) ||
|
(item.getBackUnit() != null && item.getBackUnit().contains(keyWord)) ||
|
||||||
(item.getBackPro() != null && item.getBackPro().contains(keyWord)) ||
|
(item.getBackPro() != null && item.getBackPro().contains(keyWord)) ||
|
||||||
(item.getBackCode() != null && item.getBackCode().contains(keyWord)) ||
|
(item.getBackCode() != null && item.getBackCode().contains(keyWord)) ||
|
||||||
(item.getCreateName() != null && item.getCreateName().contains(keyWord));
|
(item.getCreateName() != null && item.getCreateName().contains(keyWord)) ||
|
||||||
|
maCodeMatch;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
||||||
|
|
@ -854,7 +854,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
JOIN ma_type_keeper mtk ON mtk.type_id = lod.type_id AND mtk.user_id =#{userId}
|
JOIN ma_type_keeper mtk ON mtk.type_id = lod.type_id AND mtk.user_id =#{userId}
|
||||||
</if>
|
</if>
|
||||||
where
|
where
|
||||||
tt.task_type = '2'
|
tt.task_type = '2' and lai.direct_id is null
|
||||||
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
|
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
|
||||||
and COALESCE(lai.release_time, lai.create_time) BETWEEN CONCAT(#{startTime}, ' 00:00:00') AND CONCAT(#{endTime}, ' 23:59:59')
|
and COALESCE(lai.release_time, lai.create_time) BETWEEN CONCAT(#{startTime}, ' 00:00:00') AND CONCAT(#{endTime}, ' 23:59:59')
|
||||||
</if>
|
</if>
|
||||||
|
|
|
||||||
|
|
@ -299,11 +299,13 @@
|
||||||
WHEN tt.task_status in (1, 2)
|
WHEN tt.task_status in (1, 2)
|
||||||
THEN tt.update_time
|
THEN tt.update_time
|
||||||
ELSE NULL
|
ELSE NULL
|
||||||
END AS submitTime
|
END AS submitTime,
|
||||||
|
GROUP_CONCAT(mm.ma_code) AS maCode
|
||||||
FROM
|
FROM
|
||||||
repair_apply_details rd
|
repair_apply_details rd
|
||||||
LEFT JOIN ma_type mt on rd.type_id = mt.type_id
|
LEFT JOIN ma_type mt on rd.type_id = mt.type_id
|
||||||
LEFT JOIN ma_type mt2 on mt.parent_id = mt2.type_id
|
LEFT JOIN ma_type mt2 on mt.parent_id = mt2.type_id
|
||||||
|
LEFT JOIN ma_machine mm ON mm.ma_id = rd.ma_id
|
||||||
LEFT JOIN tm_task tt on rd.task_id = tt.task_id
|
LEFT JOIN tm_task tt on rd.task_id = tt.task_id
|
||||||
LEFT JOIN back_apply_info bai ON rd.back_id = bai.id
|
LEFT JOIN back_apply_info bai ON rd.back_id = bai.id
|
||||||
LEFT JOIN tm_task_agreement tta ON rd.task_id = tta.task_id
|
LEFT JOIN tm_task_agreement tta ON rd.task_id = tta.task_id
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue