Commit d12e9a62 authored by 温志超's avatar 温志超

更新查询

parent a43ebd42
...@@ -78,7 +78,8 @@ public class ProFeedbackController extends BaseController { ...@@ -78,7 +78,8 @@ public class ProFeedbackController extends BaseController {
proFeedback.getOrderCode()); proFeedback.getOrderCode());
query.like(StringUtils.isNotEmpty(proFeedback.getOrderSerial()), "wo.order_serial", query.like(StringUtils.isNotEmpty(proFeedback.getOrderSerial()), "wo.order_serial",
proFeedback.getOrderSerial()); proFeedback.getOrderSerial());
query.like(StringUtils.isNotEmpty(proFeedback.getCustomerDrawingNo()), "wo.Customer_Drawing_No",
proFeedback.getCustomerDrawingNo());
query.eq(proFeedback.getLastFeedback() != null , "f.Last_Feedback", proFeedback.getLastFeedback()); query.eq(proFeedback.getLastFeedback() != null , "f.Last_Feedback", proFeedback.getLastFeedback());
// query.eq(StringUtils.isNotEmpty(proFeedback.getUserId()), "pww.user_id", proFeedback.getUserId()); // query.eq(StringUtils.isNotEmpty(proFeedback.getUserId()), "pww.user_id", proFeedback.getUserId());
query.eq(StringUtils.isNotEmpty(proFeedback.getWorkunitId()), "tw.workunit_id", proFeedback.getWorkunitId()); query.eq(StringUtils.isNotEmpty(proFeedback.getWorkunitId()), "tw.workunit_id", proFeedback.getWorkunitId());
......
...@@ -360,6 +360,9 @@ public class ProFeedback extends BaseEntity { ...@@ -360,6 +360,9 @@ public class ProFeedback extends BaseEntity {
@ApiModelProperty("订单单号序号") @ApiModelProperty("订单单号序号")
@TableField(exist = false) @TableField(exist = false)
private String orderSerial; private String orderSerial;
@ApiModelProperty("产品图号")
@TableField(exist = false)
private String customerDrawingNo;
public void initValue(ProWorkorder workorder, ProTaskWorkunit proTaskWorkunit) { public void initValue(ProWorkorder workorder, ProTaskWorkunit proTaskWorkunit) {
this.setWorkorderCode(workorder.getWorkorderCode()); this.setWorkorderCode(workorder.getWorkorderCode());
this.setWorkorderName(workorder.getWorkorderName()); this.setWorkorderName(workorder.getWorkorderName());
......
...@@ -210,4 +210,6 @@ public class ProProductionSolution extends BaseEntity { ...@@ -210,4 +210,6 @@ public class ProProductionSolution extends BaseEntity {
private String filePath; private String filePath;
@ApiModelProperty("主档文件名称") @ApiModelProperty("主档文件名称")
private String originalFilename; private String originalFilename;
@ApiModelProperty("产品图号")
private String customerDrawingNo;
} }
...@@ -205,6 +205,9 @@ public class ProTaskWorkunit extends BaseEntity { ...@@ -205,6 +205,9 @@ public class ProTaskWorkunit extends BaseEntity {
private BigDecimal quantityWait; private BigDecimal quantityWait;
private int percent; private int percent;
@ApiModelProperty("客户图号")
@TableField(exist = false)
private String customerDrawingNo;
@ApiModelProperty("订单单号") @ApiModelProperty("订单单号")
......
package com.ximai.mes.pro.domain.vo; package com.ximai.mes.pro.domain.vo;
import com.baomidou.mybatisplus.annotation.TableField;
import com.ximai.common.annotation.Excel; import com.ximai.common.annotation.Excel;
import com.fasterxml.jackson.annotation.JsonFormat; import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
...@@ -290,4 +291,8 @@ public class ProFeedbackVo { ...@@ -290,4 +291,8 @@ public class ProFeedbackVo {
private String abnormalReason; private String abnormalReason;
/** 异常原因 备注*/ /** 异常原因 备注*/
private String abnormalRemark; private String abnormalRemark;
@ApiModelProperty("产品图号")
@TableField(exist = false)
private String customerDrawingNo;
} }
...@@ -233,7 +233,9 @@ public class ProWorkorderQuery extends BaseEntity { ...@@ -233,7 +233,9 @@ public class ProWorkorderQuery extends BaseEntity {
private String orderSerial; private String orderSerial;
@ApiModelProperty("项目号") @ApiModelProperty("项目号")
private String customerProjectNo; private String customerProjectNo;
@ApiModelProperty("产品图号")
@TableField(exist = false)
private String customerDrawingNo;
@TableField(exist = false) @TableField(exist = false)
private List<Long> workorderIds; private List<Long> workorderIds;
......
...@@ -98,6 +98,8 @@ public class ProTaskWorkunitQuery extends BaseEntity { ...@@ -98,6 +98,8 @@ public class ProTaskWorkunitQuery extends BaseEntity {
@ApiModelProperty("是否委外,1:是,0:否") @ApiModelProperty("是否委外,1:是,0:否")
private Integer outsourced; private Integer outsourced;
@ApiModelProperty("客户图号")
private String customerDrawingNo;
private String taskBatch; private String taskBatch;
} }
package com.ximai.mes.pro.dto; package com.ximai.mes.pro.dto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.ximai.mes.pro.domain.ProFeedback; import com.ximai.mes.pro.domain.ProFeedback;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.Data; import lombok.Data;
...@@ -12,4 +13,7 @@ public class ProFeedbackCheckListDto extends ProFeedback { ...@@ -12,4 +13,7 @@ public class ProFeedbackCheckListDto extends ProFeedback {
@ApiModelProperty("订单单号序号") @ApiModelProperty("订单单号序号")
private String orderSerial; private String orderSerial;
@ApiModelProperty("产品图号")
@TableField(exist = false)
private String customerDrawingNo;
} }
...@@ -63,7 +63,7 @@ public interface ProWorkorderMapper extends BaseMapper<ProWorkorder> { ...@@ -63,7 +63,7 @@ public interface ProWorkorderMapper extends BaseMapper<ProWorkorder> {
List<ProWorkorder> selectProWorkorderJoinTask(@Param("ew") QueryWrapper<ProWorkorder> query); List<ProWorkorder> selectProWorkorderJoinTask(@Param("ew") QueryWrapper<ProWorkorder> query);
@Select(value = "select t1.*,t2.item_type_name,t2.item_type_id from pro_workorder t1 left join md_item t2 on t1.product_id = t2.item_id\n" + @Select(value = "select t1.*,t2.item_type_name,t2.item_type_id,t2.customer_Drawing_No from pro_workorder t1 left join md_item t2 on t1.product_id = t2.item_id\n" +
"${ew.customSqlSegment}") "${ew.customSqlSegment}")
List<ProWorkorder> selectListByQw(@Param("ew") QueryWrapper<ProWorkorder> query); List<ProWorkorder> selectListByQw(@Param("ew") QueryWrapper<ProWorkorder> query);
......
...@@ -147,7 +147,7 @@ public interface ProTaskWorkunitMapper extends BaseMapper<ProTaskWorkunit> { ...@@ -147,7 +147,7 @@ public interface ProTaskWorkunitMapper extends BaseMapper<ProTaskWorkunit> {
@Select(value = "select t.task_id, t.task_code, t.task_name, t.task_batch\n" + @Select(value = "select t.task_id, t.task_code, t.task_name, t.task_batch\n" +
"\t, t.workstation_id, t.workstation_code, ws.workstation_name\n" + "\t, t.workstation_id, t.workstation_code, ws.workstation_name\n" +
"\t, t.process_id, t.process_code, t.process_name\n" + "\t, t.process_id, t.process_code, t.process_name\n" +
"\t, t.item_id, wo.product_code as item_code, wo.product_name as item_name,wo.customer_project_no,wo.order_code, t.specification, t.unit_of_measure\n" + "\t, t.item_id, wo.product_code as item_code, wo.product_name as item_name,wo.customer_project_no,wo.customer_drawing_no,wo.order_code, t.specification, t.unit_of_measure\n" +
"\t, ptw.task_workunit_id, ptw.quantity, ptw.create_by, t.quantity_wait, ptw.quantity_produced, ptw.quantity_changed\n" + "\t, ptw.task_workunit_id, ptw.quantity, ptw.create_by, t.quantity_wait, ptw.quantity_produced, ptw.quantity_changed\n" +
"\t, t.client_id, t.client_code, t.client_name, t.client_nick, t.is_last_process, ptw.schedule_start_date\n" + "\t, t.client_id, t.client_code, t.client_name, t.client_nick, t.is_last_process, ptw.schedule_start_date\n" +
"\t, t.duration, ptw.schedule_end_date, t.color_code, t.request_date\n" + "\t, t.duration, ptw.schedule_end_date, t.color_code, t.request_date\n" +
......
...@@ -458,7 +458,8 @@ public class ProTaskWorkunitServiceImpl implements IProTaskWorkunitService { ...@@ -458,7 +458,8 @@ public class ProTaskWorkunitServiceImpl implements IProTaskWorkunitService {
proTaskWorkunit.getOrderCode()); proTaskWorkunit.getOrderCode());
query.like(StringUtils.isNotEmpty(proTaskWorkunit.getOrderSerial()), "wo.order_serial", query.like(StringUtils.isNotEmpty(proTaskWorkunit.getOrderSerial()), "wo.order_serial",
proTaskWorkunit.getOrderSerial()); proTaskWorkunit.getOrderSerial());
query.like(StringUtils.isNotEmpty(proTaskWorkunit.getCustomerProjectNo()), "wo.customer_drawing_no",
proTaskWorkunit.getCustomerProjectNo());
query.gt("ptw.quantity",0); query.gt("ptw.quantity",0);
......
...@@ -80,7 +80,8 @@ ...@@ -80,7 +80,8 @@
select pw.*, select pw.*,
pc.combination_code, pc.combination_code,
pa.arrange_code, pa.arrange_code,
md.item_type_name md.item_type_name,
md.customer_Drawing_No
from pro_workorder pw from pro_workorder pw
left join pro_combination pc on pw.workorder_id = pc.workorder_id left join pro_combination pc on pw.workorder_id = pc.workorder_id
left join pro_arrange pa on pw.workorder_id = pa.workorder_id left join pro_arrange pa on pw.workorder_id = pa.workorder_id
...@@ -133,6 +134,7 @@ ...@@ -133,6 +134,7 @@
<if test="customerProjectNo != null and customerProjectNo !=''">and pw.customer_project_no = #{customerProjectNo}</if> <if test="customerProjectNo != null and customerProjectNo !=''">and pw.customer_project_no = #{customerProjectNo}</if>
<if test="orderCode != null and orderCode !=''">and pw.order_code like '%${orderCode}%' </if> <if test="orderCode != null and orderCode !=''">and pw.order_code like '%${orderCode}%' </if>
<if test="orderSerial != null and orderSerial !=''">and pw.order_serial = #{orderSerial}</if> <if test="orderSerial != null and orderSerial !=''">and pw.order_serial = #{orderSerial}</if>
<if test="customerDrawingNo != null and customerDrawingNo !=''">and md.customer_Drawing_No like '%${customerDrawingNo}%'</if>
<if test="statusArr != null">and pw.status in <if test="statusArr != null">and pw.status in
<foreach item="status" collection="statusArr" open="(" separator="," close=")"> <foreach item="status" collection="statusArr" open="(" separator="," close=")">
#{status} #{status}
......
...@@ -76,7 +76,8 @@ ...@@ -76,7 +76,8 @@
pps.surpass_state, pps.surpass_state,
pps.url, pps.url,
pps.file_path, pps.file_path,
pps.original_filename pps.original_filename,
mi.customer_Drawing_No
from pro_production_solution pps from pro_production_solution pps
left join md_item mi on pps.item_id = mi.item_id left join md_item mi on pps.item_id = mi.item_id
left join pro_route pr on pr.route_id = pps.route_id left join pro_route pr on pr.route_id = pps.route_id
...@@ -105,6 +106,7 @@ ...@@ -105,6 +106,7 @@
</if> </if>
<if test="routeId != null ">and pps.route_id = #{routeId}</if> <if test="routeId != null ">and pps.route_id = #{routeId}</if>
<if test="usageId != null ">and pps.usage_id = #{usageId}</if> <if test="usageId != null ">and pps.usage_id = #{usageId}</if>
<if test="customerDrawingNo != null ">and mi.customer_Drawing_No like '%${customerDrawingNo}%'</if>
</where> </where>
</select> </select>
......
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