opt:报表查询优化,入库接口加创建时间字段
This commit is contained in:
@@ -77,6 +77,7 @@ public class MesController {
|
||||
for(QPMES060RequestBody QPMES060RequestBody:notice.toJavaObject(QPMES060Request.class).getBODY()) {
|
||||
material.copyFrom(QPMES060RequestBody);
|
||||
material.setGroup_bind_material_status(GroupBindMaterialStatusEnum.BOUND.getValue());
|
||||
material.setCreate_time(DateUtil.now());
|
||||
materialMapper.insert(material);
|
||||
}
|
||||
qpmes060ResponseBody.setMESSAGE("原材料入库成功");
|
||||
|
||||
@@ -68,6 +68,8 @@ public class Material implements Serializable {
|
||||
private String weightCoefficientValue;
|
||||
@ApiModelProperty(value = "线径")
|
||||
private String lineDiameter;
|
||||
@ApiModelProperty(value = "操作时间")
|
||||
private String create_time;
|
||||
|
||||
|
||||
public void copyFrom(QPMES060RequestBody source){
|
||||
|
||||
@@ -3,22 +3,23 @@
|
||||
<mapper namespace="org.nl.wms.sch.report.service.dao.mapper.ReportMapper">
|
||||
|
||||
<select id="queryReport" resultType="org.nl.wms.sch.report.service.dto.ReportDto">
|
||||
SELECT
|
||||
DISTINCT p.point_code as pointCode,
|
||||
p.point_name as pointName,
|
||||
p.region_code as regionCode,
|
||||
p.region_name as regionName,
|
||||
p.vehicle_code2 as subTray,
|
||||
p.vehicle_code as motherTray,
|
||||
m.productDescription,
|
||||
m.supplierName,
|
||||
m.ingotBatch
|
||||
SELECT DISTINCT
|
||||
p.point_code AS pointCode,
|
||||
p.point_name AS pointName,
|
||||
p.region_code AS regionCode,
|
||||
p.region_name AS regionName,
|
||||
p.vehicle_code2 AS subTray,
|
||||
p.vehicle_code AS motherTray,
|
||||
m.productDescription,
|
||||
m.supplierName,
|
||||
m.ingotBatch
|
||||
FROM
|
||||
sch_base_point p
|
||||
LEFT JOIN sch_base_material m ON p.vehicle_code2 = m.PalletSN
|
||||
sch_base_point p,
|
||||
sch_base_material m
|
||||
WHERE
|
||||
vehicle_code2 IS NOT NULL
|
||||
AND vehicle_code2 != ''
|
||||
p.vehicle_code2 = m.PalletSN
|
||||
AND vehicle_code2 IS NOT NULL
|
||||
AND vehicle_code2 != ''
|
||||
<if test="query.supplierName != null">
|
||||
and m.supplierName like CONCAT('%', #{query.supplierName}, '%')
|
||||
</if>
|
||||
|
||||
Reference in New Issue
Block a user