设备作业中心字段修改+sql文件

develop-QA
qinyulong 3 months ago committed by sunjianxi
parent 29a13ebe1b
commit 343510c716
  1. 27
      blade-service-api/blade-desk-api/src/main/java/org/springblade/desk/device/pojo/entity/EquipmentEntity.java
  2. 2
      blade-service/blade-desk/src/main/java/org/springblade/desk/device/mapper/EquipmentMapper.xml
  3. 2
      blade-service/blade-desk/src/main/java/org/springblade/desk/device/service/impl/EquipmentServiceImpl.java
  4. 5
      doc/sql/mes/increase-260113.sql

@ -1,28 +1,3 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.desk.device.pojo.entity;
import com.baomidou.mybatisplus.annotation.TableName;
@ -153,7 +128,7 @@ public class EquipmentEntity extends BaseEntity {
* 作业中心ID
*/
@Schema(description = "作业中心ID")
private Long workstationId;
private Long workCenterId;
public void setDocking(String docking) {
// 核心逻辑:如果传入的是 null 或空字符串,则使用默认值 "0"
if (docking == null || docking.trim().isEmpty()) {

@ -27,7 +27,7 @@
<result column="IS_DELETED" property="isDeleted"/>
<result column="ATTACH_LINK" property="attachLink"/>
<result column="EQUIPMENT_LOCATION" property="equipmentLocation"/>
<result column="WORKSTATION_ID" property="workstationId"/>
<result column="WORK_CENTER_ID" property="workCenterId"/>
</resultMap>
<!-- 定义结果映射,将查询结果的列映射到VO的属性上 -->
<resultMap id="EquipmentStatusStatisticsResultMap"

@ -66,7 +66,7 @@ public class EquipmentServiceImpl extends BaseServiceImpl<EquipmentMapper, Equip
.like(Objects.nonNull(equipment.getEquipmentLocation()), EquipmentEntity::getEquipmentLocation, equipment.getEquipmentLocation())
.eq(Objects.nonNull(equipment.getUsed()), EquipmentEntity::getUsed, equipment.getUsed())
.eq(Objects.nonNull(equipment.getVirtualMac()), EquipmentEntity::getVirtualMac, equipment.getVirtualMac())
.eq(Objects.nonNull(equipment.getWorkstationId()), EquipmentEntity::getWorkstationId, equipment.getWorkstationId());
.eq(Objects.nonNull(equipment.getWorkCenterId()), EquipmentEntity::getWorkCenterId, equipment.getWorkCenterId());
// 3. 执行分页查询
return baseMapper.selectPage(page, wrapper);
}

@ -0,0 +1,5 @@
--
ALTER TABLE MES_EQUIPMENT
MODIFY (WORKSTATION_ID NUMBER (20,0));
ALTER TABLE MES_EQUIPMENT RENAME COLUMN WORKSTATION_ID TO WORK_CENTER_ID;
Loading…
Cancel
Save