生产报工表结构修改

This commit is contained in:
DESKTOP-J7ED0MB\yinjinlu 2022-10-02 15:47:47 +08:00
parent 4153b51f99
commit 6da962e288
3 changed files with 169 additions and 29 deletions

View File

@ -280,6 +280,7 @@ create table pro_task (
drop table if exists pro_feedback;
create table pro_feedback (
record_id bigint(20) not null auto_increment comment '记录ID',
feedback_type varchar(64) not null comment '报工类型',
workstation_id bigint(20) not null comment '工作站ID',
workstation_code varchar(64) comment '工作站编号',
workstation_name varchar(255) comment '工作站名称',
@ -288,6 +289,10 @@ create table pro_feedback (
workorder_name varchar(255) comment '生产工单名称',
task_id bigint(20) comment '生产任务ID',
task_code varchar(64) comment '生产任务编号',
item_id bigint(20) not null comment '产品物料ID',
item_code varchar(64) not null comment '产品物料编码',
item_name varchar(255) not null comment '产品物料名称',
specification varchar(500) comment '规格型号',
quantity double(14,2) comment '排产数量',
quantity_feedback double(14,2) comment '本次报工数量',
quantity_qualified double(14,2) comment '合格品数量',
@ -296,6 +301,8 @@ create table pro_feedback (
nick_name varchar(64) comment '昵称',
feedback_channel varchar(64) comment '报工途径',
feedback_time datetime comment '报工时间',
record_user varchar(64) comment '记录人',
status varchar(64) default 'PREPARE' comment '状态',
remark varchar(500) default '' comment '备注',
attr1 varchar(64) default null comment '预留字段1',
attr2 varchar(255) default null comment '预留字段2',

View File

@ -21,6 +21,9 @@ public class ProFeedback extends BaseEntity
/** 记录ID */
private Long recordId;
/** 报工类型*/
private String feedbackType;
/** 工作站ID */
@Excel(name = "工作站ID")
private Long workstationId;
@ -53,6 +56,27 @@ public class ProFeedback extends BaseEntity
@Excel(name = "生产任务编号")
private String taskCode;
/** 产品物料ID */
@Excel(name = "产品物料ID")
private Long itemId;
/** 产品物料编码 */
@Excel(name = "产品物料编码")
private String itemCode;
/** 产品物料名称 */
@Excel(name = "产品物料名称")
private String itemName;
/** 规格型号 */
@Excel(name = "规格型号")
private String specification;
/** 单位 */
@Excel(name = "单位")
private String unitOfMeasure;
/** 排产数量 */
@Excel(name = "排产数量")
private BigDecimal quantity;
@ -86,6 +110,14 @@ public class ProFeedback extends BaseEntity
@Excel(name = "报工时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date feedbackTime;
/** 录入人员 */
@Excel(name = "录入人员")
private String recordUser;
/** 状态 */
@Excel(name = "状态")
private String status;
/** 预留字段1 */
private String attr1;
@ -288,35 +320,102 @@ public class ProFeedback extends BaseEntity
return attr4;
}
public String getFeedbackType() {
return feedbackType;
}
public void setFeedbackType(String feedbackType) {
this.feedbackType = feedbackType;
}
public Long getItemId() {
return itemId;
}
public void setItemId(Long itemId) {
this.itemId = itemId;
}
public String getItemCode() {
return itemCode;
}
public void setItemCode(String itemCode) {
this.itemCode = itemCode;
}
public String getItemName() {
return itemName;
}
public void setItemName(String itemName) {
this.itemName = itemName;
}
public String getSpecification() {
return specification;
}
public void setSpecification(String specification) {
this.specification = specification;
}
public String getUnitOfMeasure() {
return unitOfMeasure;
}
public void setUnitOfMeasure(String unitOfMeasure) {
this.unitOfMeasure = unitOfMeasure;
}
public String getRecordUser() {
return recordUser;
}
public void setRecordUser(String recordUser) {
this.recordUser = recordUser;
}
public String getStatus() {
return status;
}
public void setStatus(String status) {
this.status = status;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("recordId", getRecordId())
.append("workstationId", getWorkstationId())
.append("workstationCode", getWorkstationCode())
.append("workstationName", getWorkstationName())
.append("workorderId", getWorkorderId())
.append("workorderCode", getWorkorderCode())
.append("workorderName", getWorkorderName())
.append("taskId", getTaskId())
.append("taskCode", getTaskCode())
.append("quantity", getQuantity())
.append("quantityFeedback", getQuantityFeedback())
.append("quantityQualified", getQuantityQualified())
.append("quantityUnquanlified", getQuantityUnquanlified())
.append("userName", getUserName())
.append("nickName", getNickName())
.append("feedbackChannel", getFeedbackChannel())
.append("feedbackTime", getFeedbackTime())
.append("remark", getRemark())
.append("attr1", getAttr1())
.append("attr2", getAttr2())
.append("attr3", getAttr3())
.append("attr4", getAttr4())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.toString();
return "ProFeedback{" +
"recordId=" + recordId +
", feedbackType='" + feedbackType + '\'' +
", workstationId=" + workstationId +
", workstationCode='" + workstationCode + '\'' +
", workstationName='" + workstationName + '\'' +
", workorderId=" + workorderId +
", workorderCode='" + workorderCode + '\'' +
", workorderName='" + workorderName + '\'' +
", taskId=" + taskId +
", taskCode='" + taskCode + '\'' +
", itemId=" + itemId +
", itemCode='" + itemCode + '\'' +
", itemName='" + itemName + '\'' +
", specification='" + specification + '\'' +
", unitOfMeasure='" + unitOfMeasure + '\'' +
", quantity=" + quantity +
", quantityFeedback=" + quantityFeedback +
", quantityQualified=" + quantityQualified +
", quantityUnquanlified=" + quantityUnquanlified +
", userName='" + userName + '\'' +
", nickName='" + nickName + '\'' +
", feedbackChannel='" + feedbackChannel + '\'' +
", feedbackTime=" + feedbackTime +
", recordUser='" + recordUser + '\'' +
", status='" + status + '\'' +
", attr1='" + attr1 + '\'' +
", attr2='" + attr2 + '\'' +
", attr3=" + attr3 +
", attr4=" + attr4 +
'}';
}
}

View File

@ -14,6 +14,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="workorderName" column="workorder_name" />
<result property="taskId" column="task_id" />
<result property="taskCode" column="task_code" />
<result property="itemId" column="item_id" />
<result property="itemCode" column="item_code" />
<result property="itemName" column="item_name" />
<result property="specification" column="specification" />
<result property="quantity" column="quantity" />
<result property="quantityFeedback" column="quantity_feedback" />
<result property="quantityQualified" column="quantity_qualified" />
@ -22,6 +26,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="nickName" column="nick_name" />
<result property="feedbackChannel" column="feedback_channel" />
<result property="feedbackTime" column="feedback_time" />
<result property="recordUser" column="record_user" />
<result property="status" column="status" />
<result property="remark" column="remark" />
<result property="attr1" column="attr1" />
<result property="attr2" column="attr2" />
@ -34,7 +40,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap>
<sql id="selectProFeedbackVo">
select record_id, workstation_id, workstation_code, workstation_name, workorder_id, workorder_code, workorder_name, task_id, task_code, quantity, quantity_feedback, quantity_qualified, quantity_unquanlified, user_name, nick_name, feedback_channel, feedback_time, remark, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time from pro_feedback
select record_id, workstation_id, workstation_code, workstation_name, workorder_id, workorder_code, workorder_name, task_id, task_code,item_id,item_code,item_name,specification,unit_of_measure, quantity, quantity_feedback, quantity_qualified, quantity_unquanlified, user_name, nick_name, feedback_channel, feedback_time,record_user,status, remark, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time from pro_feedback
</sql>
<select id="selectProFeedbackList" parameterType="ProFeedback" resultMap="ProFeedbackResult">
@ -48,6 +54,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="workorderName != null and workorderName != ''"> and workorder_name like concat('%', #{workorderName}, '%')</if>
<if test="taskId != null "> and task_id = #{taskId}</if>
<if test="taskCode != null and taskCode != ''"> and task_code = #{taskCode}</if>
<if test="itemId != null "> and item_id = #{itemId}</if>
<if test="itemCode != null and itemCode != ''"> and item_code = #{itemCode}</if>
<if test="itemName != null and itemName != ''"> and item_name like concat('%', #{itemName}, '%')</if>
<if test="specification != null and specification != ''"> and specification = #{specification}</if>
<if test="unitOfMeasure != null and unitOfMeasure != ''"> and unit_of_measure = #{unitOfMeasure}</if>
<if test="quantity != null "> and quantity = #{quantity}</if>
<if test="quantityFeedback != null "> and quantity_feedback = #{quantityFeedback}</if>
<if test="quantityQualified != null "> and quantity_qualified = #{quantityQualified}</if>
@ -56,6 +67,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="nickName != null and nickName != ''"> and nick_name like concat('%', #{nickName}, '%')</if>
<if test="feedbackChannel != null and feedbackChannel != ''"> and feedback_channel = #{feedbackChannel}</if>
<if test="feedbackTime != null "> and feedback_time = #{feedbackTime}</if>
<if test="recordUser != null "> and record_user = #{recordUser}</if>
<if test="status != null "> and status = #{status}</if>
</where>
</select>
@ -75,6 +88,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="workorderName != null">workorder_name,</if>
<if test="taskId != null">task_id,</if>
<if test="taskCode != null">task_code,</if>
<if test="itemId != null">item_id,</if>
<if test="itemCode != null and itemCode != ''">item_code,</if>
<if test="itemName != null and itemName != ''">item_name,</if>
<if test="specification != null">specification,</if>
<if test="unitOfMeasure != null and unitOfMeasure != ''">unit_of_measure,</if>
<if test="quantity != null">quantity,</if>
<if test="quantityFeedback != null">quantity_feedback,</if>
<if test="quantityQualified != null">quantity_qualified,</if>
@ -83,6 +101,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="nickName != null">nick_name,</if>
<if test="feedbackChannel != null">feedback_channel,</if>
<if test="feedbackTime != null">feedback_time,</if>
<if test="recordUser != null">record_user,</if>
<if test="status != null">status,</if>
<if test="remark != null">remark,</if>
<if test="attr1 != null">attr1,</if>
<if test="attr2 != null">attr2,</if>
@ -102,6 +122,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="workorderName != null">#{workorderName},</if>
<if test="taskId != null">#{taskId},</if>
<if test="taskCode != null">#{taskCode},</if>
<if test="itemId != null">#{itemId},</if>
<if test="itemCode != null and itemCode != ''">#{itemCode},</if>
<if test="itemName != null and itemName != ''">#{itemName},</if>
<if test="specification != null">#{specification},</if>
<if test="unitOfMeasure != null and unitOfMeasure != ''">#{unitOfMeasure},</if>
<if test="quantity != null">#{quantity},</if>
<if test="quantityFeedback != null">#{quantityFeedback},</if>
<if test="quantityQualified != null">#{quantityQualified},</if>
@ -110,6 +135,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="nickName != null">#{nickName},</if>
<if test="feedbackChannel != null">#{feedbackChannel},</if>
<if test="feedbackTime != null">#{feedbackTime},</if>
<if test="recordUser != null">#{recordUser},</if>
<if test="status != null">#{status},</if>
<if test="remark != null">#{remark},</if>
<if test="attr1 != null">#{attr1},</if>
<if test="attr2 != null">#{attr2},</if>
@ -133,6 +160,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="workorderName != null">workorder_name = #{workorderName},</if>
<if test="taskId != null">task_id = #{taskId},</if>
<if test="taskCode != null">task_code = #{taskCode},</if>
<if test="itemId != null">item_id = #{itemId},</if>
<if test="itemCode != null and itemCode != ''">item_code = #{itemCode},</if>
<if test="itemName != null and itemName != ''">item_name = #{itemName},</if>
<if test="specification != null">specification = #{specification},</if>
<if test="unitOfMeasure != null and unitOfMeasure != ''">unit_of_measure = #{unitOfMeasure},</if>
<if test="quantity != null">quantity = #{quantity},</if>
<if test="quantityFeedback != null">quantity_feedback = #{quantityFeedback},</if>
<if test="quantityQualified != null">quantity_qualified = #{quantityQualified},</if>
@ -141,6 +173,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="nickName != null">nick_name = #{nickName},</if>
<if test="feedbackChannel != null">feedback_channel = #{feedbackChannel},</if>
<if test="feedbackTime != null">feedback_time = #{feedbackTime},</if>
<if test="recordUser != null">record_user = #{recordUser},</if>
<if test="status != null">status = #{status},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="attr1 != null">attr1 = #{attr1},</if>
<if test="attr2 != null">attr2 = #{attr2},</if>