2024-4-10 基础信息模块-设备-增加车间

master
A0010407 10 months ago
parent 1c7ea171cc
commit 90cf6bfcae

@ -20,342 +20,178 @@ import java.util.List;
public class BaseEquipment extends BaseEntity {
private static final long serialVersionUID = 1L;
/**
* ID
*/
private Long equipmentId;
/**
*
*/
@Excel(name = "设备编码")
private String equipmentCode;
/**
*
*/
@Excel(name = "设备名称")
private String equipmentName;
/**
*
*/
@Excel(name = "品牌")
private String equipmentBrand;
/**
*
*/
@Excel(name = "规格型号")
private String equipmentSpec;
/**
* ID
*/
@Excel(name = "设备类型ID")
private Long equipmentTypeId;
/**
*
*/
@Excel(name = "设备类型编码")
private String equipmentTypeCode;
/**
*
*/
@Excel(name = "设备类型名称")
private String equipmentTypeName;
/**
* ID
*/
@Excel(name = "所属车间ID")
private Long workshopId;
/**
*
*/
@Excel(name = "所属车间编码")
private String workshopCode;
/**
*
*/
@Excel(name = "所属车间名称")
private String workshopName;
/**
*
*/
@Excel(name = "设备是否启用")
private String status;
/**
* 1
*/
@Excel(name = "预留字段1")
private String attr1;
/**
* 2
*/
@Excel(name = "预留字段2")
private String attr2;
/**
* 3
*/
@Excel(name = "预留字段3")
private Long attr3;
/**
* 4
*/
@Excel(name = "预留字段4")
private Long attr4;
/**
*
*/
@Excel(name = "单台能力工时")
private String unitWorkingHours;
/**
*
*/
@Excel(name = "工段")
private String workshopSection;
/**
*
*/
@Excel(name = "设备位置")
private String equipmentLocation;
/**
*
*/
@Excel(name = "工时单价")
private String hourlyUnitPrice;
//附属字段
/**
*
*/
@Excel(name = "成型机存料状态")
private String starving;
/**
*
*/
@Excel(name = "该成型机存放的物料")
private String material;
/**
*
*/
@Excel(name = "烘房是否开门")
private String isOpen;
/**
* 2
*/
@Excel(name = "烘房2门前小车数量")
private String dollyNumber;
/**
*
*/
@Excel(name = "烘房温度")
private String temperature;
/**
*
*/
@Excel(name = "烘房压强")
private String intensityOfPressure;
/**
* 湿
*/
@Excel(name = "烘房湿度")
private String humidity;
/**
*
*/
@Excel(name = "烘房状态")
private String state;
/**
*
*/
/////////////////////////
@Excel(name = "删除标志")
private String delFlag;
/**
*
*/
@Excel(name = "属性")
private String property;
/**
*
*/
@Excel(name = "说明")
private String explain;
/**
* IP
*/
@Excel(name = "IP")
private String plcIp;
/**
*
*/
@Excel(name = "端口号")
private String plcPort;
/**
* SAP
*/
@Excel(name = "SAP资产号")
private String sapAsset;
/**
*
*/
@Excel(name = "设备条码")
private String equipmentBarcode;
/**
*
*/
@Excel(name = "设备条码图片")
private String equipmentBarcodeImage;
/**
*
*/
@Excel(name = "生产厂商")
private String manufacturer;
/**
*
*/
@Excel(name = "供应商")
private String supplier;
/**
* 使寿
*/
@Excel(name = "使用寿命")
private String useLife;
/**
*
*/
@Excel(name = "购买时间", width = 30, dateFormat = "yyyy-MM-dd")
private String buyTime;
/**
*
*/
@Excel(name = "资产原值")
private String assetOriginalValue;
/**
*
*/
@Excel(name = "资产净值")
private String netAssetValue;
/**
*
*/
@Excel(name = "资产负责人")
private String assetHead;
/**
*
*/
@Excel(name = "固定资产编码")
private String fixedAssetCode;
/**
*
*/
@Excel(name = "部门")
private String department;
/**
*
*/
@Excel(name = "负责人工号")
private String equipmentHead;
/**
*
*/
@Excel(name = "工厂号")
private String factoryCode;
/**
*
*/
@Excel(name = "设备状态")
private String equipmentStatus;
/**
*
*/
@Excel(name = "设备类别")
private String equipmentCategory;
/**
*
*/
@Excel(name = "资产分类名称")
private String assetClassificationName;
/**
*
*/
@Excel(name = "资产描述")
private String assetDescription;
/**
*
*/
@Excel(name = "数量")
private String equipmentNumber;
/**
*
*/
@Excel(name = "存货号")
private String inventoryNumber;
/**
*
*/
@Excel(name = "计量单位")
private String unitMeasurement;
//新增SAP字段
/**
* SAP线
*/
@Excel(name = "SAP线体编码")
private String sapCode;
/**
* SAP线
*/
@Excel(name = "SAP线体名称")
private String sapName;
@Excel(name = "工厂车间")
private String factoryWorkshop;
private String imageFileList;
private String barCodeFileList;
@ -381,100 +217,31 @@ public class BaseEquipment extends BaseEntity {
private List<EquBindAuxiliaryEquipment> selectedEquipmentData;
/////////////////////////维修记录
/**
*
*/
private String workCode;
/**
*
*/
private String workPerson;
/**
*
*/
private String workTeam;
/**
*
*/
private String workReason;
/**
*
*/
private String workFaultDesc;
/**
*
*/
private String repairMeasures;
/**
*
*/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date workStartTime;
/**
*
*/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private String workCode;//维修单号
private String workPerson;//维修人员
private String workTeam;//维修组
private String workReason;//原因分析
private String workFaultDesc;//故障描述
private String repairMeasures;//设备维修措施
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")//维修开始时间
private Date workStartTime;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")//维修结束时间
private Date workEndTime;
/**
*
*/
private String workStatus;
private String workStatus;//维修状态
/////////////////////////保养记录
/**
*
*/
private String orderCode;
/**
*
*/
private String planLoop;
/**
*
*/
@JsonFormat(pattern = "yyyy-MM-dd")
private String orderCode;//单号
private String planLoop;//循环周期
@JsonFormat(pattern = "yyyy-MM-dd")//实际开始时间
private Date orderStart;
/**
*
*/
@JsonFormat(pattern = "yyyy-MM-dd")
@JsonFormat(pattern = "yyyy-MM-dd")//实际结束时间
private Date orderEnd;
/**
*
*/
private String orderStatus;
/**
*
*/
private BigDecimal orderCost;
/**
*
*/
private String planPerson;
/**
*
*/
private String orderCostTime;
/**
*
*/
private String orderSignPerson;
private String orderStatus;//工单状态
private BigDecimal orderCost;//工单费用
private String planPerson;//责任人
private String orderCostTime;//工单用时
private String orderSignPerson;//签字
///////////////////////////////////
public void setOrderCode(String orderCode) {
@ -1153,12 +920,12 @@ public class BaseEquipment extends BaseEntity {
}
//SAP线体名称
public void setSapName(String sapName) {
this.sapName = sapName;
}
public String getSapName() {
return sapName;
}
public void setSapName(String sapName) { this.sapName = sapName; }
public String getSapName() { return sapName; }
//工厂车间
public void setFactoryWorkshop(String factoryWorkshop) { this.factoryWorkshop = factoryWorkshop; }
public String getFactoryWorkshop() { return factoryWorkshop; }
@Override
public String toString() {

@ -56,6 +56,7 @@
<result property="unitMeasurement" column="unit_measurement"/>
<result property="sapCode" column="sap_code"/>
<result property="sapName" column="sap_name"/>
<result property="factoryWorkshop" column="factory_workshop"/>
</resultMap>
<resultMap type="WmsSparePartsLedger" id="WmsSparePartsLedgerResult">
@ -178,63 +179,43 @@
inventory_number,
unit_measurement,
sap_code,
sap_name
sap_name,
factory_workshop
from base_equipment
</sql>
<select id="selectBaseEquipmentList" parameterType="BaseEquipment" resultMap="BaseEquipmentResult">
<include refid="selectBaseEquipmentVo"/>
<where>
<if test="equipmentCode != null and equipmentCode != ''">and equipment_code like concat('%',
#{equipmentCode}, '%')
</if>
<if test="equipmentName != null and equipmentName != ''">and equipment_name like concat('%',
#{equipmentName}, '%')
</if>
<if test="equipmentCode != null and equipmentCode != ''">and equipment_code like concat('%',#{equipmentCode}, '%')</if>
<if test="equipmentName != null and equipmentName != ''">and equipment_name like concat('%',#{equipmentName}, '%')</if>
<if test="equipmentBrand != null and equipmentBrand != ''">and equipment_brand = #{equipmentBrand}</if>
<if test="equipmentSpec != null and equipmentSpec != ''">and equipment_spec = #{equipmentSpec}</if>
<if test="equipmentTypeId != null ">and equipment_type_id = #{equipmentTypeId}</if>
<if test="equipmentTypeCode != null and equipmentTypeCode != ''">and equipment_type_code like concat('%',
#{equipmentTypeCode}, '%')
</if>
<if test="equipmentTypeName != null and equipmentTypeName != ''">and equipment_type_name like concat('%',
#{equipmentTypeName}, '%')
</if>
<if test="equipmentTypeCode != null and equipmentTypeCode != ''">and equipment_type_code like concat('%',#{equipmentTypeCode}, '%')</if>
<if test="equipmentTypeName != null and equipmentTypeName != ''">and equipment_type_name like concat('%',#{equipmentTypeName}, '%')</if>
<if test="workshopId != null ">and workshop_id = #{workshopId}</if>
<if test="workshopCode != null and workshopCode != ''">and workshop_code = #{workshopCode}</if>
<if test="workshopName != null and workshopName != ''">and workshop_name like concat('%', #{workshopName},
'%')
</if>
<if test="workshopName != null and workshopName != ''">and workshop_name like concat('%', #{workshopName},'%')</if>
<if test="status != null and status != ''">and status = #{status}</if>
<if test="attr1 != null and attr1 != ''">and attr1 = #{attr1}</if>
<if test="attr2 != null and attr2 != ''">and attr2 = #{attr2}</if>
<if test="attr3 != null ">and attr3 = #{attr3}</if>
<if test="attr4 != null ">and attr4 = #{attr4}</if>
<if test="unitWorkingHours != null and unitWorkingHours != ''">and unit_working_hours =
#{unitWorkingHours}
</if>
<if test="unitWorkingHours != null and unitWorkingHours != ''">and unit_working_hours = #{unitWorkingHours}</if>
<if test="workshopSection != null and workshopSection != ''">and workshop_section = #{workshopSection}</if>
<if test="equipmentLocation != null and equipmentLocation != ''">and equipment_location =
#{equipmentLocation}
</if>
<if test="hourlyUnitPrice != null and hourlyUnitPrice != ''">and hourly_unit_price = #{hourlyUnitPrice}
</if>
<if test="equipmentLocation != null and equipmentLocation != ''">and equipment_location = #{equipmentLocation}</if>
<if test="hourlyUnitPrice != null and hourlyUnitPrice != ''">and hourly_unit_price = #{hourlyUnitPrice}</if>
<if test="plcIp != null and plcIp != ''">and plc_ip = #{plcIp}</if>
<if test="plcPort != null and plcPort != ''">and plc_port = #{plcPort}</if>
<if test="equipmentHead != null and equipmentHead != ''">and equipment_head = #{equipmentHead}</if>
<if test="equipmentBarcode != null and equipmentBarcode != ''">and equipment_barcode =
#{equipmentBarcode}
</if>
<if test="equipmentBarcodeImage != null and equipmentBarcodeImage != ''">and equipment_barcode_image =
#{equipmentBarcodeImage}
</if>
<if test="equipmentBarcode != null and equipmentBarcode != ''">and equipment_barcode = #{equipmentBarcode}</if>
<if test="equipmentBarcodeImage != null and equipmentBarcodeImage != ''">and equipment_barcode_image = #{equipmentBarcodeImage}</if>
<if test="manufacturer != null and manufacturer != ''">and manufacturer = #{manufacturer}</if>
<if test="supplier != null and supplier != ''">and supplier = #{supplier}</if>
<if test="useLife != null and useLife != ''">and use_life = #{useLife}</if>
<if test="buyTime != null ">and buy_time = #{buyTime}</if>
<if test="assetOriginalValue != null and assetOriginalValue != ''">and asset_original_value =
#{assetOriginalValue}
</if>
<if test="assetOriginalValue != null and assetOriginalValue != ''">and asset_original_value = #{assetOriginalValue}</if>
<if test="netAssetValue != null and netAssetValue != ''">and net_asset_value = #{netAssetValue}</if>
<if test="assetHead != null and assetHead != ''">and asset_head = #{assetHead}</if>
<if test="fixedAssetCode != null and fixedAssetCode != ''">and fixed_asset_code = #{fixedAssetCode}</if>
@ -242,20 +223,15 @@
<if test="sapAsset != null and sapAsset != ''">and sap_asset = #{sapAsset}</if>
<if test="factoryCode != null and factoryCode != ''">and factory_code = #{factoryCode}</if>
<if test="equipmentStatus != null and equipmentStatus != ''">and equipment_status = #{equipmentStatus}</if>
<if test="equipmentCategory != null and equipmentCategory != ''">and equipment_category =
#{equipmentCategory}
</if>
<if test="assetClassificationName != null and assetClassificationName != ''">and asset_classification_name
= #{assetClassificationName}
</if>
<if test="assetDescription != null and assetDescription != ''">and asset_description =
#{assetDescription}
</if>
<if test="equipmentCategory != null and equipmentCategory != ''">and equipment_category = #{equipmentCategory}</if>
<if test="assetClassificationName != null and assetClassificationName != ''">and asset_classification_name = #{assetClassificationName}</if>
<if test="assetDescription != null and assetDescription != ''">and asset_description = #{assetDescription}</if>
<if test="equipmentNumber != null and equipmentNumber != ''">and equipment_number = #{equipmentNumber}</if>
<if test="inventoryNumber != null and inventoryNumber != ''">and inventory_number = #{inventoryNumber}</if>
<if test="unitMeasurement != null and unitMeasurement != ''">and unit_measurement = #{unitMeasurement}</if>
<if test="sapCode != null and sapCode != ''">and sap_code = #{sapCode}</if>
<if test="sapName != null and sapName != ''">and sap_name = #{sapName}</if>
<if test="factoryWorkshop != null and factoryWorkshop != ''">and factory_workshop like concat('%', #{factoryWorkshop},'%')</if>
and del_flag ='0'
</where>
</select>
@ -325,6 +301,7 @@
<if test="unitMeasurement != null">unit_measurement,</if>
<if test="sapCode != null">sap_code,</if>
<if test="sapName != null">sap_name,</if>
<if test="factoryWorkshop != null">factory_workshop,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="equipmentCode != null and equipmentCode != ''">#{equipmentCode},</if>
@ -369,21 +346,21 @@
<if test="factoryCode != null">#{factoryCode},</if>
<if test="equipmentStatus != null">#{equipmentStatus},</if>
<if test="equipmentCategory != null">#{equipmentCategory},</if>
<if test="assetClassificationName != null and assetClassificationName != ''">#{assetClassificationName},
</if>
<if test="assetClassificationName != null and assetClassificationName != ''">#{assetClassificationName},</if>
<if test="assetDescription != null and assetDescription != ''">#{assetDescription},</if>
<if test="equipmentNumber != null and equipmentNumber != ''">#{equipmentNumber},</if>
<if test="inventoryNumber != null and inventoryNumber != ''">#{inventoryNumber},</if>
<if test="unitMeasurement != null and unitMeasurement != ''">#{unitMeasurement},</if>
<if test="sapCode != null and sapCode != ''">#{sapCode},</if>
<if test="sapName != null and sapName != ''">#{sapName},</if>
<if test="factoryWorkshop != null and factoryWorkshop != ''">#{factoryWorkshop},</if>
</trim>
</insert>
<update id="updateBaseEquipment" parameterType="BaseEquipment">
update base_equipment
<trim prefix="SET" suffixOverrides=",">
<if test="equipmentCode != null and equipmentCode != ''">equipment_code = #{equipmentCode},</if>
<if test="equipmentCode != null">equipment_code = #{equipmentCode},</if>
<if test="equipmentName != null">equipment_name = #{equipmentName},</if>
<if test="equipmentBrand != null">equipment_brand = #{equipmentBrand},</if>
<if test="equipmentSpec != null">equipment_spec = #{equipmentSpec},</if>
@ -403,15 +380,12 @@
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="unitWorkingHours != null and unitWorkingHours != ''">unit_working_hours = #{unitWorkingHours},
</if>
<if test="workshopSection != null and workshopSection != ''">workshop_section = #{workshopSection},</if>
<if test="equipmentLocation != null and equipmentLocation != ''">equipment_location =
#{equipmentLocation},
</if>
<if test="hourlyUnitPrice != null and hourlyUnitPrice != ''">hourly_unit_price = #{hourlyUnitPrice},</if>
<if test="plcIp != null and plcIp != ''">plc_ip = #{plcIp},</if>
<if test="plcPort != null and plcPort != ''">plc_port = #{plcPort},</if>
<if test="unitWorkingHours != null ">unit_working_hours = #{unitWorkingHours},</if>
<if test="workshopSection != null">workshop_section = #{workshopSection},</if>
<if test="equipmentLocation != null">equipment_location = #{equipmentLocation},</if>
<if test="hourlyUnitPrice != null">hourly_unit_price = #{hourlyUnitPrice},</if>
<if test="plcIp != null">plc_ip = #{plcIp},</if>
<if test="plcPort != null">plc_port = #{plcPort},</if>
<if test="equipmentBarcode != null">equipment_barcode = #{equipmentBarcode},</if>
<if test="equipmentBarcodeImage != null">equipment_barcode_image = #{equipmentBarcodeImage},</if>
<if test="manufacturer != null">manufacturer = #{manufacturer},</if>
@ -428,16 +402,14 @@
<if test="factoryCode != null">factory_code = #{factoryCode},</if>
<if test="equipmentStatus != null">equipment_status = #{equipmentStatus},</if>
<if test="equipmentCategory != null">equipment_category = #{equipmentCategory},</if>
<if test="assetClassificationName != null and assetClassificationName != ''">asset_classification_name =
#{assetClassificationName},
</if>
<if test="assetDescription != null and assetDescription != ''">asset_description = #{assetDescription},
</if>
<if test="equipmentNumber != null and equipmentNumber != ''">equipment_number = #{equipmentNumber},</if>
<if test="inventoryNumber != null and inventoryNumber != ''">inventory_number = #{inventoryNumber},</if>
<if test="unitMeasurement != null and unitMeasurement != ''">unit_measurement = #{unitMeasurement},</if>
<if test="sapCode != null and sapCode != ''">sap_code = #{sapCode},</if>
<if test="sapName != null and sapName != ''">sap_name = #{sapName},</if>
<if test="assetClassificationName != null">asset_classification_name = #{assetClassificationName},</if>
<if test="assetDescription != null">asset_description = #{assetDescription},</if>
<if test="equipmentNumber != null">equipment_number = #{equipmentNumber},</if>
<if test="inventoryNumber != null">inventory_number = #{inventoryNumber},</if>
<if test="unitMeasurement != null">unit_measurement = #{unitMeasurement},</if>
<if test="sapCode != null">sap_code = #{sapCode},</if>
<if test="sapName != null">sap_name = #{sapName},</if>
<if test="factoryWorkshop != null">factory_workshop = #{factoryWorkshop},</if>
</trim>
where equipment_id = #{equipmentId}
</update>

Loading…
Cancel
Save