| | |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableLogic; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.experimental.Accessors; |
| | | import org.jeecg.common.aspect.annotation.Dict; |
| | | import org.jeecgframework.poi.excel.annotation.Excel; |
| | | import org.jeecg.common.constant.CommonConstant; |
| | | import org.jeecg.common.util.DateUtils; |
| | | import org.jeecg.modules.sap.dto.ProductionOrderDTO; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @Description: SAP生产订单 |
| | | * @Author: jeecg-boot |
| | | * @Date: 2025-07-04 |
| | | * @Date: 2025-07-04 |
| | | * @Version: V1.0 |
| | | */ |
| | | @Data |
| | | @TableName("mes_production_order") |
| | | @Accessors(chain = true) |
| | | @EqualsAndHashCode(callSuper = false) |
| | | @ApiModel(value="mes_production_order对象", description="SAP生产订单") |
| | | @ApiModel(value = "mes_production_order对象", description = "SAP生产订单") |
| | | public class MesProductionOrder implements Serializable { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /**主键*/ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | /**主键*/ |
| | | @TableId(type = IdType.ASSIGN_ID) |
| | | @ApiModelProperty(value = "主键") |
| | | private String id; |
| | | /**创建人*/ |
| | | /**创建人*/ |
| | | @ApiModelProperty(value = "创建人") |
| | | private String createBy; |
| | | /**创建日期*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | /**创建日期*/ |
| | | @ApiModelProperty(value = "创建日期") |
| | | private Date createTime; |
| | | /**更新人*/ |
| | | /**更新人*/ |
| | | @ApiModelProperty(value = "更新人") |
| | | private String updateBy; |
| | | /**更新日期*/ |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | /**更新日期*/ |
| | | @ApiModelProperty(value = "更新日期") |
| | | private Date updateTime; |
| | | /**删除标记*/ |
| | | @Excel(name = "删除标记", width = 15) |
| | | /**删除标记*/ |
| | | @ApiModelProperty(value = "删除标记") |
| | | @TableLogic |
| | | private Integer delFlag; |
| | | /**生产订单号*/ |
| | | @Excel(name = "生产订单号", width = 15) |
| | | /**生产订单号*/ |
| | | @ApiModelProperty(value = "生产订单号") |
| | | private String orderCode; |
| | | /**订单类型*/ |
| | | @Excel(name = "订单类型", width = 15) |
| | | /**订单类型*/ |
| | | @ApiModelProperty(value = "订单类型") |
| | | @Dict(dicCode = "production_order_category") |
| | | private String orderCategory; |
| | | /**物料编号*/ |
| | | @Excel(name = "物料编号", width = 15) |
| | | /**物料编号*/ |
| | | @ApiModelProperty(value = "物料编号") |
| | | private String materialNumber; |
| | | /**物料名称*/ |
| | | @Excel(name = "物料名称", width = 15) |
| | | /**物料名称*/ |
| | | @ApiModelProperty(value = "物料名称") |
| | | private String materialName; |
| | | /**计划开始日期*/ |
| | | @Excel(name = "计划开始日期", width = 20, format = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | /**计划开始日期*/ |
| | | @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd") |
| | | @ApiModelProperty(value = "计划开始日期") |
| | | private Date planStart; |
| | | /**计划结束日期*/ |
| | | @Excel(name = "计划结束日期", width = 20, format = "yyyy-MM-dd HH:mm:ss") |
| | | @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | /**计划结束日期*/ |
| | | @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd") |
| | | @ApiModelProperty(value = "计划结束日期") |
| | | private Date planEnd; |
| | | /**订单数量*/ |
| | | @Excel(name = "订单数量", width = 15) |
| | | /**订单数量*/ |
| | | @ApiModelProperty(value = "订单数量") |
| | | private Double orderQuantity; |
| | | /**产品单位*/ |
| | | @Excel(name = "产品单位", width = 15, dicCode = "production_unit") |
| | | @Dict(dicCode = "production_unit") |
| | | @ApiModelProperty(value = "产品单位") |
| | | private BigDecimal orderQuantity; |
| | | /**基本计量单位*/ |
| | | @ApiModelProperty(value = "基本计量单位") |
| | | private String productionUnit; |
| | | /**订单状态*/ |
| | | @Excel(name = "订单状态", width = 15, dicCode = "order_status") |
| | | @Dict(dicCode = "order_status") |
| | | /**订单状态*/ |
| | | @ApiModelProperty(value = "订单状态") |
| | | private String orderStatus; |
| | | /**优先级*/ |
| | | @Excel(name = "优先级", width = 15, dicCode = "priority") |
| | | @Dict(dicCode = "priority") |
| | | /**订单状态描述*/ |
| | | @ApiModelProperty(value = "订单状态描述") |
| | | private String orderStatusName; |
| | | /**优先级*/ |
| | | @ApiModelProperty(value = "优先级") |
| | | private String priority; |
| | | /**计划工艺路线*/ |
| | | @Excel(name = "计划工艺路线", width = 15) |
| | | /**计划工艺路线*/ |
| | | @ApiModelProperty(value = "计划工艺路线") |
| | | private String processRoute; |
| | | /**计划物料清单*/ |
| | | @Excel(name = "计划物料清单", width = 15) |
| | | /**计划物料清单*/ |
| | | @ApiModelProperty(value = "计划物料清单") |
| | | private String materialListCode; |
| | | /**工厂编码*/ |
| | | @Excel(name = "工厂编码", width = 15) |
| | | /**工厂编码*/ |
| | | @ApiModelProperty(value = "工厂编码") |
| | | private String factoryCode; |
| | | /**工厂名称*/ |
| | | @Excel(name = "工厂名称", width = 15) |
| | | /**工厂名称*/ |
| | | @ApiModelProperty(value = "工厂名称") |
| | | private String factoryName; |
| | | /**客户型号*/ |
| | | @Excel(name = "客户型号", width = 15) |
| | | /**调度员编号*/ |
| | | @ApiModelProperty(value = "调度员编号") |
| | | private String dispatcherCode; |
| | | /**调度员名称*/ |
| | | @ApiModelProperty(value = "调度员名称") |
| | | private String dispatcherName; |
| | | /**订单创建日期 yyyy-MM-dd*/ |
| | | @ApiModelProperty(value = "订单创建日期") |
| | | private String orderCreateDate; |
| | | /**订单更新日期 yyyy-MM-dd*/ |
| | | @ApiModelProperty(value = "订单更新日期") |
| | | private String orderUpdateDate; |
| | | /**订单更新时间 HH:mm:ss*/ |
| | | @ApiModelProperty(value = "订单更新时间") |
| | | private String orderUpdateTime; |
| | | /**订单修改人*/ |
| | | @ApiModelProperty(value = "订单修改人") |
| | | private String orderUpdateUser; |
| | | /**客户型号*/ |
| | | @ApiModelProperty(value = "客户型号") |
| | | private String customerOrderModel; |
| | | /**客户名称*/ |
| | | @Excel(name = "客户名称", width = 15) |
| | | /**客户名称*/ |
| | | @ApiModelProperty(value = "客户名称") |
| | | private String customer; |
| | | /**备注*/ |
| | | @Excel(name = "备注", width = 15) |
| | | /**备注*/ |
| | | @ApiModelProperty(value = "备注") |
| | | private String remark; |
| | | |
| | | public MesProductionOrder() { |
| | | } |
| | | |
| | | public MesProductionOrder(ProductionOrderDTO dto) { |
| | | this.orderCode = dto.getAUFNR(); |
| | | this.orderCategory = dto.getDAUAT(); |
| | | this.materialNumber = dto.getMATNR(); |
| | | this.materialName = dto.getMAKTX(); |
| | | this.planStart = DateUtils.str2Date(dto.getGSTRP(), DateUtils.date_sdf.get()); |
| | | this.planEnd = DateUtils.str2Date(dto.getGLTRP(), DateUtils.date_sdf.get()); |
| | | this.orderQuantity = new BigDecimal(dto.getGAMNG()); |
| | | this.productionUnit = dto.getGMEIN(); |
| | | this.orderStatus = dto.getTXT04(); |
| | | this.orderStatusName = dto.getTXT30(); |
| | | this.priority = dto.getAPRIO(); |
| | | this.processRoute = dto.getAUFPL(); |
| | | this.materialListCode = dto.getSTLNR(); |
| | | this.factoryCode = dto.getDWERK(); |
| | | this.factoryName = dto.getNAME1(); |
| | | this.dispatcherCode = dto.getFEVOR(); |
| | | this.dispatcherName = dto.getTXT(); |
| | | this.orderCreateDate = dto.getUDATE(); |
| | | this.orderUpdateDate = dto.getLAEDA(); |
| | | this.orderUpdateTime = dto.getTIMES(); |
| | | this.orderUpdateUser = dto.getUSNAM(); |
| | | this.delFlag = CommonConstant.DEL_FLAG_0; |
| | | } |
| | | |
| | | public void updateEntity(ProductionOrderDTO dto) { |
| | | this.orderCategory = dto.getDAUAT(); |
| | | this.planStart = DateUtils.str2Date(dto.getGSTRP(), DateUtils.date_sdf.get()); |
| | | this.planEnd = DateUtils.str2Date(dto.getGLTRP(), DateUtils.date_sdf.get()); |
| | | this.orderQuantity = new BigDecimal(dto.getGAMNG()); |
| | | this.orderStatus = dto.getTXT04(); |
| | | this.orderStatusName = dto.getTXT30(); |
| | | this.priority = dto.getAPRIO(); |
| | | this.orderCreateDate = dto.getUDATE(); |
| | | this.orderUpdateDate = dto.getLAEDA(); |
| | | this.orderUpdateTime = dto.getTIMES(); |
| | | this.orderUpdateUser = dto.getUSNAM(); |
| | | } |
| | | } |