报表-巡检记录

highway
wws 1 year ago
parent 7f67bc9b15
commit c466027d74

@ -0,0 +1,99 @@
package com.op.device.controller;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import com.op.device.service.IInspectionWorkService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.op.common.log.annotation.Log;
import com.op.common.log.enums.BusinessType;
import com.op.common.security.annotation.RequiresPermissions;
import com.op.device.domain.EquOrder;
import com.op.device.service.IEquOrderService;
import com.op.common.core.web.controller.BaseController;
import com.op.common.core.web.domain.AjaxResult;
import com.op.common.core.utils.poi.ExcelUtil;
import com.op.common.core.web.page.TableDataInfo;
/**
* Controller
*
* @author wws
* @date 2023-11-07
*/
@RestController
@RequestMapping("/inspectionWork")
public class InspectionWorkController extends BaseController{
@Autowired
private IInspectionWorkService iInspectionWorkService;
/**
*
*/
@RequiresPermissions("device:inspectionWork:list")
@GetMapping("/list")
public TableDataInfo list(EquOrder equOrder) {
startPage();
List<EquOrder> list = iInspectionWorkService.selectEquOrderList(equOrder);
return getDataTable(list);
}
/**
*
*/
@RequiresPermissions("device:inspectionWork:export")
@Log(title = "巡检记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, EquOrder equOrder) {
List<EquOrder> list = iInspectionWorkService.selectEquOrderList(equOrder);
ExcelUtil<EquOrder> util = new ExcelUtil<EquOrder>(EquOrder.class);
util.exportExcel(response, list, "巡检记录数据");
}
/**
*
*/
@RequiresPermissions("device:inspectionWork:query")
@GetMapping(value = "/{orderId}")
public AjaxResult getInfo(@PathVariable("orderId") String orderId) {
return iInspectionWorkService.selectEquOrderByOrderId(orderId);
}
/**
*
*/
@RequiresPermissions("device:inspectionWork:add")
@Log(title = "巡检记录", businessType = BusinessType.INSERT)
@PostMapping
public AjaxResult add(@RequestBody EquOrder equOrder) {
return toAjax(iInspectionWorkService.insertEquOrder(equOrder));
}
/**
*
*/
@RequiresPermissions("device:inspectionWork:edit")
@Log(title = "巡检记录", businessType = BusinessType.UPDATE)
@PutMapping
public AjaxResult edit(@RequestBody EquOrder equOrder) {
return toAjax(iInspectionWorkService.updateEquOrder(equOrder));
}
/**
*
*/
@RequiresPermissions("device:inspectionWork:remove")
@Log(title = "巡检记录", businessType = BusinessType.DELETE)
@DeleteMapping("/{orderIds}")
public AjaxResult remove(@PathVariable String[] orderIds) {
return toAjax(iInspectionWorkService.deleteEquOrderByOrderIds(orderIds));
}
}

@ -84,6 +84,16 @@ public class EquOrderStandard extends BaseEntity {
// 图片路径
private String picturePath;
private String standardTypeName;
public String getStandardTypeName() {
return standardTypeName;
}
public void setStandardTypeName(String standardTypeName) {
this.standardTypeName = standardTypeName;
}
public String getPicturePath() {
return picturePath;
}

@ -0,0 +1,441 @@
package com.op.device.domain;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.op.common.core.annotation.Excel;
import com.op.common.core.web.domain.BaseEntity;
public class Equipment extends BaseEntity {
/** 设备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;
/** 设备状态,0异常 */
@Excel(name = "设备状态,0异常")
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 workshopSection;
/** 设备位置 */
@Excel(name = "设备位置")
private String equipmentLocation;
/** 工时单价 */
@Excel(name = "工时单价")
private Long hourlyUnitPrice;
/** 设备条码 */
@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;
/** 购买时间 */
@JsonFormat(pattern = "yyyy-MM-dd")
@Excel(name = "购买时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date 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 unitWorkingHours;
/** PLCIP */
@Excel(name = "PLCIP")
private String plcIp;
/** PLC端口 */
@Excel(name = "PLC端口")
private Long plcPort;
/** 删除标志1删除,0正常 */
private String delFlag;
/** SAP资产号 */
@Excel(name = "SAP资产号")
private String sapAsset;
public void setEquipmentId(Long equipmentId) {
this.equipmentId = equipmentId;
}
public Long getEquipmentId() {
return equipmentId;
}
public void setEquipmentCode(String equipmentCode) {
this.equipmentCode = equipmentCode;
}
public String getEquipmentCode() {
return equipmentCode;
}
public void setEquipmentName(String equipmentName) {
this.equipmentName = equipmentName;
}
public String getEquipmentName() {
return equipmentName;
}
public void setEquipmentBrand(String equipmentBrand) {
this.equipmentBrand = equipmentBrand;
}
public String getEquipmentBrand() {
return equipmentBrand;
}
public void setEquipmentSpec(String equipmentSpec) {
this.equipmentSpec = equipmentSpec;
}
public String getEquipmentSpec() {
return equipmentSpec;
}
public void setEquipmentTypeId(Long equipmentTypeId) {
this.equipmentTypeId = equipmentTypeId;
}
public Long getEquipmentTypeId() {
return equipmentTypeId;
}
public void setEquipmentTypeCode(String equipmentTypeCode) {
this.equipmentTypeCode = equipmentTypeCode;
}
public String getEquipmentTypeCode() {
return equipmentTypeCode;
}
public void setEquipmentTypeName(String equipmentTypeName) {
this.equipmentTypeName = equipmentTypeName;
}
public String getEquipmentTypeName() {
return equipmentTypeName;
}
public void setWorkshopId(Long workshopId) {
this.workshopId = workshopId;
}
public Long getWorkshopId() {
return workshopId;
}
public void setWorkshopCode(String workshopCode) {
this.workshopCode = workshopCode;
}
public String getWorkshopCode() {
return workshopCode;
}
public void setWorkshopName(String workshopName) {
this.workshopName = workshopName;
}
public String getWorkshopName() {
return workshopName;
}
public void setStatus(String status) {
this.status = status;
}
public String getStatus() {
return status;
}
public void setAttr1(String attr1) {
this.attr1 = attr1;
}
public String getAttr1() {
return attr1;
}
public void setAttr2(String attr2) {
this.attr2 = attr2;
}
public String getAttr2() {
return attr2;
}
public void setAttr3(Long attr3) {
this.attr3 = attr3;
}
public Long getAttr3() {
return attr3;
}
public void setAttr4(Long attr4) {
this.attr4 = attr4;
}
public Long getAttr4() {
return attr4;
}
public void setWorkshopSection(String workshopSection) {
this.workshopSection = workshopSection;
}
public String getWorkshopSection() {
return workshopSection;
}
public void setEquipmentLocation(String equipmentLocation) {
this.equipmentLocation = equipmentLocation;
}
public String getEquipmentLocation() {
return equipmentLocation;
}
public void setHourlyUnitPrice(Long hourlyUnitPrice) {
this.hourlyUnitPrice = hourlyUnitPrice;
}
public Long getHourlyUnitPrice() {
return hourlyUnitPrice;
}
public void setEquipmentBarcode(String equipmentBarcode) {
this.equipmentBarcode = equipmentBarcode;
}
public String getEquipmentBarcode() {
return equipmentBarcode;
}
public void setEquipmentBarcodeImage(String equipmentBarcodeImage) {
this.equipmentBarcodeImage = equipmentBarcodeImage;
}
public String getEquipmentBarcodeImage() {
return equipmentBarcodeImage;
}
public void setManufacturer(String manufacturer) {
this.manufacturer = manufacturer;
}
public String getManufacturer() {
return manufacturer;
}
public void setSupplier(String supplier) {
this.supplier = supplier;
}
public String getSupplier() {
return supplier;
}
public void setUseLife(String useLife) {
this.useLife = useLife;
}
public String getUseLife() {
return useLife;
}
public void setBuyTime(Date buyTime) {
this.buyTime = buyTime;
}
public Date getBuyTime() {
return buyTime;
}
public void setAssetOriginalValue(String assetOriginalValue) {
this.assetOriginalValue = assetOriginalValue;
}
public String getAssetOriginalValue() {
return assetOriginalValue;
}
public void setNetAssetValue(String netAssetValue) {
this.netAssetValue = netAssetValue;
}
public String getNetAssetValue() {
return netAssetValue;
}
public void setAssetHead(String assetHead) {
this.assetHead = assetHead;
}
public String getAssetHead() {
return assetHead;
}
public void setFixedAssetCode(String fixedAssetCode) {
this.fixedAssetCode = fixedAssetCode;
}
public String getFixedAssetCode() {
return fixedAssetCode;
}
public void setDepartment(String department) {
this.department = department;
}
public String getDepartment() {
return department;
}
public void setUnitWorkingHours(String unitWorkingHours) {
this.unitWorkingHours = unitWorkingHours;
}
public String getUnitWorkingHours() {
return unitWorkingHours;
}
public void setPlcIp(String plcIp) {
this.plcIp = plcIp;
}
public String getPlcIp() {
return plcIp;
}
public void setPlcPort(Long plcPort) {
this.plcPort = plcPort;
}
public Long getPlcPort() {
return plcPort;
}
public void setDelFlag(String delFlag) {
this.delFlag = delFlag;
}
public String getDelFlag() {
return delFlag;
}
public void setSapAsset(String sapAsset) {
this.sapAsset = sapAsset;
}
public String getSapAsset() {
return sapAsset;
}
@Override
public String toString() {
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
.append("equipmentId", getEquipmentId())
.append("equipmentCode", getEquipmentCode())
.append("equipmentName", getEquipmentName())
.append("equipmentBrand", getEquipmentBrand())
.append("equipmentSpec", getEquipmentSpec())
.append("equipmentTypeId", getEquipmentTypeId())
.append("equipmentTypeCode", getEquipmentTypeCode())
.append("equipmentTypeName", getEquipmentTypeName())
.append("workshopId", getWorkshopId())
.append("workshopCode", getWorkshopCode())
.append("workshopName", getWorkshopName())
.append("status", getStatus())
.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())
.append("workshopSection", getWorkshopSection())
.append("equipmentLocation", getEquipmentLocation())
.append("hourlyUnitPrice", getHourlyUnitPrice())
.append("equipmentBarcode", getEquipmentBarcode())
.append("equipmentBarcodeImage", getEquipmentBarcodeImage())
.append("manufacturer", getManufacturer())
.append("supplier", getSupplier())
.append("useLife", getUseLife())
.append("buyTime", getBuyTime())
.append("assetOriginalValue", getAssetOriginalValue())
.append("netAssetValue", getNetAssetValue())
.append("assetHead", getAssetHead())
.append("fixedAssetCode", getFixedAssetCode())
.append("department", getDepartment())
.append("unitWorkingHours", getUnitWorkingHours())
.append("plcIp", getPlcIp())
.append("plcPort", getPlcPort())
.append("delFlag", getDelFlag())
.append("sapAsset", getSapAsset())
.toString();
}
}

@ -0,0 +1,38 @@
package com.op.device.domain.vo;
import com.op.device.domain.EquOrder;
import com.op.device.domain.EquOrderDetail;
import com.op.device.domain.Equipment;
import java.util.List;
// 工单-报表VO
public class InspectionWorkVO {
private EquOrder order;
private Equipment equ;
private List<EquOrderDetail> detailList;
public EquOrder getOrder() {
return order;
}
public void setOrder(EquOrder order) {
this.order = order;
}
public Equipment getEqu() {
return equ;
}
public void setEqu(Equipment equ) {
this.equ = equ;
}
public List<EquOrderDetail> getDetailList() {
return detailList;
}
public void setDetailList(List<EquOrderDetail> detailList) {
this.detailList = detailList;
}
}

@ -65,4 +65,11 @@ public interface EquOrderDetailMapper {
* @return
*/
List<EquOrderDetail> selectEquOrderDetailByParentCode(String code);
/**
* list-code
* @param orderCode
* @return
*/
List<EquOrderDetail> selectEquOrderDetailByOrderCode(String orderCode);
}

@ -2,6 +2,7 @@ package com.op.device.mapper;
import java.util.List;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.op.device.domain.EquOrder;
/**
@ -98,4 +99,12 @@ public interface EquOrderMapper {
* @return
*/
int selectSerialNumber();
/**
*
* @param planLoopType
* @return
*/
@DS("#master")
String changeLoopType(String planLoopType);
}

@ -0,0 +1,13 @@
package com.op.device.mapper;
import com.op.device.domain.Equipment;
public interface EquipmentMapper {
/**
*
*
* @param equipmentId
* @return
*/
public Equipment selectEquipmentByEquipmentCode(String equipmentCode);
}

@ -0,0 +1,62 @@
package com.op.device.service;
import java.util.List;
import com.op.common.core.web.domain.AjaxResult;
import com.op.device.domain.EquOrder;
/**
* Service
*
* @author wws
* @date 2023-11-07
*/
public interface IInspectionWorkService {
/**
*
*
* @param orderId
* @return
*/
public AjaxResult selectEquOrderByOrderId(String orderId);
/**
*
*
* @param equOrder
* @return
*/
public List<EquOrder> selectEquOrderList(EquOrder equOrder);
/**
*
*
* @param equOrder
* @return
*/
public int insertEquOrder(EquOrder equOrder);
/**
*
*
* @param equOrder
* @return
*/
public int updateEquOrder(EquOrder equOrder);
/**
*
*
* @param orderIds
* @return
*/
public int deleteEquOrderByOrderIds(String[] orderIds);
/**
*
*
* @param orderId
* @return
*/
public int deleteEquOrderByOrderId(String orderId);
}

@ -0,0 +1,145 @@
package com.op.device.service.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.op.common.core.web.domain.AjaxResult;
import com.op.device.domain.*;
import com.op.device.domain.vo.InspectionWorkVO;
import com.op.device.mapper.*;
import com.op.device.service.IInspectionWorkService;
import java.util.List;
import com.op.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.op.device.service.IEquOrderService;
import static com.op.common.core.web.domain.AjaxResult.success;
/**
* Service
*
* @author wws
* @date 2023-11-07
*/
@Service
public class InspectionWorkServiceImpl implements IInspectionWorkService {
@Autowired
private EquOrderMapper equOrderMapper;
@Autowired
private EquipmentMapper equipmentMapper;
@Autowired
private EquOrderDetailMapper equOrderDetailMapper;
@Autowired
private EquOrderStandardMapper equOrderStandardMapper;
@Autowired
private EquPlanMapper equPlanMapper;
/**
*
*
* @param orderId
* @return
*/
@Override
@DS("#header.poolName")
public AjaxResult selectEquOrderByOrderId(String orderId) {
InspectionWorkVO workVO = new InspectionWorkVO();
EquOrder order = equOrderMapper.selectEquOrderByOrderId(orderId);
// 设置计划名称
EquPlan equPlan = equPlanMapper.selectEquPlanByPlanCode(order.getPlanCode());
order.setPlanName(equPlan.getPlanName());
// 替换循环周期
order.setPlanLoopType(equOrderMapper.changeLoopType(order.getPlanLoopType()));
Equipment equipment = equipmentMapper.selectEquipmentByEquipmentCode(order.getEquipmentCode());
List<EquOrderDetail> detailList = equOrderDetailMapper.selectEquOrderDetailByOrderCode(order.getOrderCode());
for (EquOrderDetail detail : detailList) {
List<EquOrderStandard> standardList = equOrderStandardMapper.selectEquOrderStandardByParentCode(detail.getCode());
for (EquOrderStandard standard : standardList) {
if (standard.getStandardType().equals("quantify")){
standard.setStandardTypeName("定量");
}else {
standard.setStandardTypeName("定性");
}
if (standard.getDetailReach() != null) {
if (standard.getDetailReach().equals("0")){
standard.setDetailReach("未达标");
}else {
standard.setDetailReach("达标");
}
}
}
detail.setStandardList(standardList);
}
workVO.setOrder(order);
workVO.setEqu(equipment);
workVO.setDetailList(detailList);
return success(workVO);
}
/**
*
*
* @param equOrder
* @return
*/
@Override
@DS("#header.poolName")
public List<EquOrder> selectEquOrderList(EquOrder equOrder) {
return equOrderMapper.selectEquOrderList(equOrder);
}
/**
*
*
* @param equOrder
* @return
*/
@Override
@DS("#header.poolName")
public int insertEquOrder(EquOrder equOrder) {
equOrder.setCreateTime(DateUtils.getNowDate());
return equOrderMapper.insertEquOrder(equOrder);
}
/**
*
*
* @param equOrder
* @return
*/
@Override
@DS("#header.poolName")
public int updateEquOrder(EquOrder equOrder) {
equOrder.setUpdateTime(DateUtils.getNowDate());
return equOrderMapper.updateEquOrder(equOrder);
}
/**
*
*
* @param orderIds
* @return
*/
@Override
@DS("#header.poolName")
public int deleteEquOrderByOrderIds(String[] orderIds) {
return equOrderMapper.deleteEquOrderByOrderIds(orderIds);
}
/**
*
*
* @param orderId
* @return
*/
@Override
@DS("#header.poolName")
public int deleteEquOrderByOrderId(String orderId) {
return equOrderMapper.deleteEquOrderByOrderId(orderId);
}
}

@ -57,6 +57,11 @@
where parent_code = #{parentCode}
</select>
<select id="selectEquOrderDetailByOrderCode" parameterType="String" resultMap="EquOrderDetailResult">
<include refid="selectEquOrderDetailVo"/>
where order_code = #{orderCode}
</select>
<insert id="insertEquOrderDetail" parameterType="EquOrderDetail">
insert into equ_order_detail
<trim prefix="(" suffix=")" suffixOverrides=",">

@ -70,9 +70,9 @@
<if test="attr3 != null and attr3 != ''"> and attr3 = #{attr3}</if>
<if test="delFlag != null and delFlag != ''"> and del_flag = #{delFlag}</if>
<if test="createBy != null and createBy != ''"> and create_by like concat('%', #{createBy}, '%')</if>
<if test="createTime != null "> and create_time = #{createTime}</if>
<if test="createTime != null "> and CONVERT(date,create_time) = #{createTime}</if>
<if test="updateBy != null and updateBy != ''"> and update_by like concat('%', #{updateBy}, '%')</if>
<if test="updateTime != null "> and update_time = #{updateTime}</if>
<if test="updateTime != null "> and CONVERT(date,update_time) = #{updateTime}</if>
<if test="upkeep != null "> and upkeep = #{upkeep}</if>
<if test="calculationRule != null "> and calculation_rule = #{calculationRule}</if>
<if test="shutDown != null "> and shut_down = #{shutDown}</if>
@ -119,7 +119,11 @@
WHERE CONVERT(date, GETDATE()) = CONVERT(date,create_time) and del_flag = '0'
</select>
<insert id="insertEquOrder" parameterType="EquOrder">
<select id="changeLoopType" resultType="java.lang.String">
select dict_label from sys_dict_data where dict_value = #{planLoopType}
</select>
<insert id="insertEquOrder" parameterType="EquOrder">
insert into equ_order
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="orderId != null">order_id,</if>

@ -0,0 +1,59 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.op.device.mapper.EquipmentMapper">
<resultMap type="Equipment" id="EquipmentResult">
<result property="equipmentId" column="equipment_id" />
<result property="equipmentCode" column="equipment_code" />
<result property="equipmentName" column="equipment_name" />
<result property="equipmentBrand" column="equipment_brand" />
<result property="equipmentSpec" column="equipment_spec" />
<result property="equipmentTypeId" column="equipment_type_id" />
<result property="equipmentTypeCode" column="equipment_type_code" />
<result property="equipmentTypeName" column="equipment_type_name" />
<result property="workshopId" column="workshop_id" />
<result property="workshopCode" column="workshop_code" />
<result property="workshopName" column="workshop_name" />
<result property="status" column="status" />
<result property="remark" column="remark" />
<result property="attr1" column="attr1" />
<result property="attr2" column="attr2" />
<result property="attr3" column="attr3" />
<result property="attr4" column="attr4" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="workshopSection" column="workshop_section" />
<result property="equipmentLocation" column="equipment_location" />
<result property="hourlyUnitPrice" column="hourly_unit_price" />
<result property="equipmentBarcode" column="equipment_barcode" />
<result property="equipmentBarcodeImage" column="equipment_barcode_image" />
<result property="manufacturer" column="manufacturer" />
<result property="supplier" column="supplier" />
<result property="useLife" column="use_life" />
<result property="buyTime" column="buy_time" />
<result property="assetOriginalValue" column="asset_original_value" />
<result property="netAssetValue" column="net_asset_value" />
<result property="assetHead" column="asset_head" />
<result property="fixedAssetCode" column="fixed_asset_code" />
<result property="department" column="department" />
<result property="unitWorkingHours" column="unit_working_hours" />
<result property="plcIp" column="plc_ip" />
<result property="plcPort" column="plc_port" />
<result property="delFlag" column="del_flag" />
<result property="sapAsset" column="sap_asset" />
</resultMap>
<sql id="selectEquipmentVo">
select equipment_id, equipment_code, equipment_name, equipment_brand, equipment_spec, equipment_type_id, equipment_type_code, equipment_type_name, workshop_id, workshop_code, workshop_name, status, remark, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time, workshop_section, equipment_location, hourly_unit_price, equipment_barcode, equipment_barcode_image, manufacturer, supplier, use_life, buy_time, asset_original_value, net_asset_value, asset_head, fixed_asset_code, department, unit_working_hours, plc_ip, plc_port, del_flag, sap_asset from base_equipment
</sql>
<select id="selectEquipmentByEquipmentCode" parameterType="String" resultMap="EquipmentResult">
<include refid="selectEquipmentVo"/>
where equipment_code = #{equipmentCode}
</select>
</mapper>
Loading…
Cancel
Save