优化页面,修正入库逻辑

This commit is contained in:
zgw
2025-12-22 16:44:13 +08:00
parent 34e931cf37
commit 9fc1cc53e9
10 changed files with 697 additions and 576 deletions

View File

@@ -40,7 +40,7 @@ public class ToWcsServiceImpl implements IToWcsService {
@Override
//@Scheduled(fixedDelay=1500)
@Scheduled(fixedDelay=1500)
public void pushOutMydoJob() {
//查询所有未推送的料箱出库作业
MydoJob mydoJobParam = new MydoJob();

View File

@@ -110,17 +110,21 @@ public class ToWmsServiceImpl implements IToWmsService {
MydoJob mydoJob1 = mydoJobService.selectMydoJobByTrayCode(requestEnter.getTrayCode());
if (ObjUtil.isNotNull(mydoJob1) && !"1".equals(mydoJob1.getInOrOut())) {
//空托盘处理
String productId = "KTP0001";
String cargoSpaceId = getCargoSpaceByProductInfo(productId);
if (!StringUtils.isNotBlank(cargoSpaceId)) {
return AjaxResult.error("无符合条件的货位用于分配,请检查库存区占用情况,物料号:" + productId);
if (mydoJob1.getCargoSpaceId()==null){
String productId = "KTP0001";
String cargoSpaceId = getCargoSpaceByProductInfo(productId);
if (!StringUtils.isNotBlank(cargoSpaceId)) {
return AjaxResult.error("无符合条件的货位用于分配,请检查库存区占用情况,物料号:" + productId);
}
mydoJob1.setCargoSpaceId(cargoSpaceId);
BasCargoSpace basCargoSpace = basCargoSpaceService.selectBasCargoSpaceByCargoSpaceId(cargoSpaceId);
mydoJob1.setRoadwayId(basCargoSpace.getTheFloor().toString());
mydoJob1.setStatus("3");
mydoJobService.updateMydoJob(mydoJob1);
return AjaxResult.success(mydoJob1);
}else {
return AjaxResult.success(mydoJob1);
}
mydoJob1.setCargoSpaceId(cargoSpaceId);
BasCargoSpace basCargoSpace = basCargoSpaceService.selectBasCargoSpaceByCargoSpaceId(cargoSpaceId);
mydoJob1.setRoadwayId(basCargoSpace.getTheFloor().toString());
mydoJob1.setStatus("3");
mydoJobService.insertMydoJob(mydoJob1);
return AjaxResult.success(mydoJob1);
}
//校验 - 条码已经有作业
if (ObjUtil.isNotNull(mydoJob1) && "1".equals(mydoJob1.getInOrOut())) {
@@ -169,6 +173,7 @@ public class ToWmsServiceImpl implements IToWmsService {
mydoJobDetail.setInOrOutDId(stockinDetailId);
mydoJobDetail.setInOrOutId(inStockinDetail.getStockinId());
mydoJobDetailService.insertMydoJobDetail(mydoJobDetail);
trayMsgService.deleteTrayMsgById(trayMsg.getId());
return AjaxResult.success(mydoJob);
}
@@ -188,52 +193,52 @@ public class ToWmsServiceImpl implements IToWmsService {
List<BasStock> stocks = basStockService.selectBasStockListByProductId(productId);
//如果集合空 - 寻找未被占用的存储区组放货
if (stocks.size() == 0) {
for (int i = 1; i <= 45; i++) {
BasCargoSpace cargospace = new BasCargoSpace();
if (!stocks.isEmpty()) {
//如果物料已经存放在多个货位(区域) - 去重
List<BasStock> stocksNew = stocks.stream().distinct().collect(Collectors.toList());
//存储区
String groupCodingNo = String.format("%03d", i);
cargospace.setGroupCodingNo(groupCodingNo);
//查询对应货位的区域在【BasCargoSpace】是否有空位 - 在groupCodingNo的分组中是否仍然有状态【1】的货位
for (BasStock stock : stocksNew) {
//获取每种物料的存放货位信息
BasCargoSpace cargoSpace = basCargoSpaceService.selectBasCargoSpaceByCargoSpaceId(stock.getCargoSpaceId());
//获取【groupCodingNo】所有货位
List<BasCargoSpace> cargoSpaces = basCargoSpaceService.selectBasCargoSpaceList(cargospace);
//获取每种物料的存放货位信息 - 存储区
String group = cargoSpace.getGroupCodingNo();
//判断是否全部未占用,即某存储区全部为空位 - 避免物料混放
boolean isAllEmpty = cargoSpaces.stream().allMatch(c -> "1".equals(c.getStatus()));
//获取该存储区组的所有货位
List<BasCargoSpace> cargoSpaces = basCargoSpaceService.selectBasCargoSpaceListByGroupCodingNo(group);
//区域未占用 - 则分配最内侧货位
if (isAllEmpty && cargoSpaces.size() > 0) {
cargoSpaces.sort(Comparator.comparing(BasCargoSpace::getGroupCoding).reversed());
return cargoSpaces.get(0).getCargoSpaceId();
//在集合中获取状态为【1】的货位
for (BasCargoSpace cs : cargoSpaces) {
//货位状态:1(未占用) -> 返回该货位结果
if ("1".equals(cs.getStatus())) {
return cs.getCargoSpaceId();
}
}
}
}
}
for (int i = 1; i <= 45; i++) {
BasCargoSpace cargospace = new BasCargoSpace();
//存储区
String groupCodingNo = String.format("%03d", i);
cargospace.setGroupCodingNo(groupCodingNo);
//获取【groupCodingNo】所有货位
List<BasCargoSpace> cargoSpaces = basCargoSpaceService.selectBasCargoSpaceList(cargospace);
//判断是否全部未占用,即某存储区全部为空位 - 避免物料混放
boolean isAllEmpty = cargoSpaces.stream().allMatch(c -> "1".equals(c.getStatus()));
//区域未占用 - 则分配最内侧货位
if (isAllEmpty && cargoSpaces.size() > 0) {
cargoSpaces.sort(Comparator.comparing(BasCargoSpace::getGroupCoding).reversed());
return cargoSpaces.get(0).getCargoSpaceId();
}
}
//如果物料已经存放在多个货位(区域) - 去重
List<BasStock> stocksNew = stocks.stream().distinct().collect(Collectors.toList());
//查询对应货位的区域在【BasCargoSpace】是否有空位 - 在groupCodingNo的分组中是否仍然有状态【1】的货位
for (BasStock stock : stocksNew) {
//获取每种物料的存放货位信息
BasCargoSpace cargoSpace = basCargoSpaceService.selectBasCargoSpaceByCargoSpaceId(stock.getCargoSpaceId());
//获取每种物料的存放货位信息 - 存储区
String group = cargoSpace.getGroupCodingNo();
//获取该存储区组的所有货位
List<BasCargoSpace> cargoSpaces = basCargoSpaceService.selectBasCargoSpaceListByGroupCodingNo(group);
//在集合中获取状态为【1】的货位
for (BasCargoSpace cs : cargoSpaces) {
//货位状态:1(未占用) -> 返回该货位结果
if ("1".equals(cs.getStatus())) {
return cs.getCargoSpaceId();
}
}
}
} catch (Exception e) {
log.error("入库子单获取目标货位失败,异常信息:" + e.getMessage());
}

View File

@@ -2,6 +2,7 @@ package com.ruoyi.bas.cargoSpace.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.bas.cargoSpace.domain.BasCargoSpace;
import org.apache.ibatis.annotations.Param;
import java.util.List;
import java.util.Map;
@@ -36,7 +37,7 @@ public interface BasCargoSpaceMapper extends BaseMapper<BasCargoSpace>
* @param groupCodingNo 存储区组
* @return 库存信息集合
*/
public List<BasCargoSpace> selectBasCargoSpaceListByGroupCodingNo(String groupCodingNo);
public List<BasCargoSpace> selectBasCargoSpaceListByGroupCodingNo(@Param("groupCodingNo") String groupCodingNo);
/**
* 新增库存信息

View File

@@ -278,8 +278,6 @@ public class MydoJobServiceImpl implements IMydoJobService {
BasCargoSpace basCargoSpace = basCargoSpaceService.selectBasCargoSpaceByCargoSpaceId(mydoJob.getCargoSpaceId());
if (CollUtil.isNotEmpty(mydoJobDetails)) {
List<BasStock> list = new ArrayList<>();
//查询盘点信息中的异常信息
CheckDifferenceRecord checkDifferenceRecordParam = new CheckDifferenceRecord();
checkDifferenceRecordParam.setTrayCode(mydoJob.getTrayCode());
@@ -307,18 +305,14 @@ public class MydoJobServiceImpl implements IMydoJobService {
//正常库存
list.add(stockByInStockinDetail);
}
}
//修改货位状态
basCargoSpace.setStatus("2");
basCargoSpace.setTrayCode(mydoJob.getTrayCode());
basCargoSpace.setCargoSpaceId(mydoJob.getCargoSpaceId());
basCargoSpaceService.updateBasCargoSpace(basCargoSpace);
//插入库存信息
basStockService.insertBasStockList(list);
//结束任务
mydoJob.setStatus("4");
mydoJob.setFinishTime(DateUtil.formatDateTime(DateUtil.date()));

View File

@@ -1,54 +1,53 @@
<?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">
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.bas.cargoSpace.mapper.BasCargoSpaceMapper">
<resultMap type="com.ruoyi.bas.cargoSpace.domain.BasCargoSpace" id="BasCargoSpaceResult">
<result property="cargoSpaceId" column="cargo_space_id" />
<result property="warehouseId" column="warehouse_id" />
<result property="warehouseName" column="warehouse_name" />
<result property="roadwayId" column="roadway_id" />
<result property="cargoAreaId" column="cargo_area_id" />
<result property="theType" column="the_type" />
<result property="theTypeName" column="the_type_name" />
<result property="cargoSpaceName" column="cargo_space_name" />
<result property="thePlatoon" column="the_platoon" />
<result property="theColumn" column="the_column" />
<result property="theFloor" column="the_floor" />
<result property="status" column="status" />
<result property="locked" column="locked" />
<result property="trayCode" column="tray_code" />
<result property="cargoHight" column="cargo_hight" />
<result property="issDouble" column="iss_double" />
<result property="groupCodingNo" column="group_coding_no" />
<result property="groupCoding" column="group_coding" />
<result property="cargoSpaceLogo" column="cargo_space_logo" />
<result property="thisCargoArea" column="this_cargo_area" />
<result property="cargoSpaceId" column="cargo_space_id"/>
<result property="warehouseId" column="warehouse_id"/>
<result property="warehouseName" column="warehouse_name"/>
<result property="roadwayId" column="roadway_id"/>
<result property="cargoAreaId" column="cargo_area_id"/>
<result property="theType" column="the_type"/>
<result property="theTypeName" column="the_type_name"/>
<result property="cargoSpaceName" column="cargo_space_name"/>
<result property="thePlatoon" column="the_platoon"/>
<result property="theColumn" column="the_column"/>
<result property="theFloor" column="the_floor"/>
<result property="status" column="status"/>
<result property="locked" column="locked"/>
<result property="trayCode" column="tray_code"/>
<result property="cargoHight" column="cargo_hight"/>
<result property="issDouble" column="iss_double"/>
<result property="groupCodingNo" column="group_coding_no"/>
<result property="groupCoding" column="group_coding"/>
<result property="cargoSpaceLogo" column="cargo_space_logo"/>
<result property="thisCargoArea" column="this_cargo_area"/>
</resultMap>
<sql id="selectBasCargoSpaceVo">
select
bcs.cargo_space_id,
bcs.warehouse_id,
bcs.roadway_id,
bcs.cargo_area_id,
bcs.the_type,
bcs.the_type_name,
bcs.cargo_space_name,
bcs.the_platoon,
bcs.the_column,
bcs.the_floor,
bcs.status,
bcs.locked,
bcs.tray_code,
bcs.cargo_hight,
bcs.iss_double,
bcs.group_coding_no,
bcs.group_coding,
bcs.cargo_space_logo,
bcs.this_cargo_area,
bw.warehouse_name
select bcs.cargo_space_id,
bcs.warehouse_id,
bcs.roadway_id,
bcs.cargo_area_id,
bcs.the_type,
bcs.the_type_name,
bcs.cargo_space_name,
bcs.the_platoon,
bcs.the_column,
bcs.the_floor,
bcs.status,
bcs.locked,
bcs.tray_code,
bcs.cargo_hight,
bcs.iss_double,
bcs.group_coding_no,
bcs.group_coding,
bcs.cargo_space_logo,
bcs.this_cargo_area,
bw.warehouse_name
from bas_cargo_space bcs
left join bas_warehouse bw on bcs.warehouse_id = bw.warehouse_id
@@ -57,58 +56,44 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectBasCargoSpaceList" resultMap="BasCargoSpaceResult">
<include refid="selectBasCargoSpaceVo"/>
<where>
<if test="cargoSpaceId != null and cargoSpaceId != ''"> and bcs.cargo_space_id like concat('%', #{cargoSpaceId}, '%')</if>
<if test="warehouseId != null and warehouseId != ''"> and bcs.warehouse_id = #{warehouseId}</if>
<if test="roadwayId != null and roadwayId != ''"> and bcs.roadway_id = #{roadwayId}</if>
<if test="cargoAreaId != null and cargoAreaId != ''"> and bcs.cargo_area_id = #{cargoAreaId}</if>
<if test="theType != null and theType != ''"> and bcs.the_type = #{theType}</if>
<if test="theTypeName != null and theTypeName != ''"> and bcs.the_type_name like concat('%', #{theTypeName}, '%')</if>
<if test="cargoSpaceName != null and cargoSpaceName != ''"> and bcs.cargo_space_name like concat('%', #{cargoSpaceName}, '%')</if>
<if test="thePlatoon != null "> and bcs.the_platoon = #{thePlatoon}</if>
<if test="theColumn != null "> and bcs.the_column = #{theColumn}</if>
<if test="theFloor != null "> and bcs.the_floor = #{theFloor}</if>
<if test="status != null and status != ''"> and bcs.status = #{status}</if>
<if test="locked != null and locked != ''"> and bcs.locked = #{locked}</if>
<if test="trayCode != null and trayCode != ''"> and bcs.tray_code like concat('%', #{trayCode}, '%')</if>
<if test="cargoHight != null and cargoHight != ''"> and bcs.cargo_hight = #{cargoHight}</if>
<if test="issDouble != null and issDouble != ''"> and bcs.iss_double = #{issDouble}</if>
<if test="groupCodingNo != null and groupCodingNo != ''"> and bcs.group_coding_no = #{groupCodingNo}</if>
<if test="groupCoding != null and groupCoding != ''"> and bcs.group_coding = #{groupCoding}</if>
<if test="cargoSpaceLogo != null and cargoSpaceLogo != ''"> and bcs.cargo_space_logo = #{cargoSpaceLogo}</if>
<if test="thisCargoArea != null and thisCargoArea != ''"> and bcs.this_cargo_area = #{thisCargoArea}</if>
<if test="cargoSpaceId != null and cargoSpaceId != ''">and bcs.cargo_space_id like concat('%',
#{cargoSpaceId}, '%')
</if>
<if test="warehouseId != null and warehouseId != ''">and bcs.warehouse_id = #{warehouseId}</if>
<if test="roadwayId != null and roadwayId != ''">and bcs.roadway_id = #{roadwayId}</if>
<if test="cargoAreaId != null and cargoAreaId != ''">and bcs.cargo_area_id = #{cargoAreaId}</if>
<if test="theType != null and theType != ''">and bcs.the_type = #{theType}</if>
<if test="theTypeName != null and theTypeName != ''">and bcs.the_type_name like concat('%', #{theTypeName},
'%')
</if>
<if test="cargoSpaceName != null and cargoSpaceName != ''">and bcs.cargo_space_name like concat('%',
#{cargoSpaceName}, '%')
</if>
<if test="thePlatoon != null ">and bcs.the_platoon = #{thePlatoon}</if>
<if test="theColumn != null ">and bcs.the_column = #{theColumn}</if>
<if test="theFloor != null ">and bcs.the_floor = #{theFloor}</if>
<if test="status != null and status != ''">and bcs.status = #{status}</if>
<if test="locked != null and locked != ''">and bcs.locked = #{locked}</if>
<if test="trayCode != null and trayCode != ''">and bcs.tray_code like concat('%', #{trayCode}, '%')</if>
<if test="cargoHight != null and cargoHight != ''">and bcs.cargo_hight = #{cargoHight}</if>
<if test="issDouble != null and issDouble != ''">and bcs.iss_double = #{issDouble}</if>
<if test="groupCodingNo != null and groupCodingNo != ''">and bcs.group_coding_no = #{groupCodingNo}</if>
<if test="groupCoding != null and groupCoding != ''">and bcs.group_coding = #{groupCoding}</if>
<if test="cargoSpaceLogo != null and cargoSpaceLogo != ''">and bcs.cargo_space_logo = #{cargoSpaceLogo}
</if>
<if test="thisCargoArea != null and thisCargoArea != ''">and bcs.this_cargo_area = #{thisCargoArea}</if>
<if test="params.warehouseDataScope != null and params.warehouseDataScope !=''">
${params.warehouseDataScope}
</if>
</where>
order by case when bcs.status='1' then 0 else 1 end asc, bcs.the_platoon asc, bcs.the_column asc, bcs.the_floor asc
order by case when bcs.status='1' then 0 else 1 end asc, bcs.the_platoon asc, bcs.the_column asc, bcs.the_floor
asc
</select>
<select id="selectBasCargoSpaceListByGroupCodingNo" parameterType="string" resultMap="BasCargoSpaceResult">
<include refid="selectBasCargoSpaceVo"/>
<where>
<if test="cargoSpaceId != null and cargoSpaceId != ''"> and bcs.cargo_space_id like concat('%', #{cargoSpaceId}, '%')</if>
<if test="warehouseId != null and warehouseId != ''"> and bcs.warehouse_id = #{warehouseId}</if>
<if test="roadwayId != null and roadwayId != ''"> and bcs.roadway_id = #{roadwayId}</if>
<if test="cargoAreaId != null and cargoAreaId != ''"> and bcs.cargo_area_id = #{cargoAreaId}</if>
<if test="theType != null and theType != ''"> and bcs.the_type = #{theType}</if>
<if test="theTypeName != null and theTypeName != ''"> and bcs.the_type_name like concat('%', #{theTypeName}, '%')</if>
<if test="cargoSpaceName != null and cargoSpaceName != ''"> and bcs.cargo_space_name like concat('%', #{cargoSpaceName}, '%')</if>
<if test="thePlatoon != null "> and bcs.the_platoon = #{thePlatoon}</if>
<if test="theColumn != null "> and bcs.the_column = #{theColumn}</if>
<if test="theFloor != null "> and bcs.the_floor = #{theFloor}</if>
<if test="status != null and status != ''"> and bcs.status = #{status}</if>
<if test="locked != null and locked != ''"> and bcs.locked = #{locked}</if>
<if test="trayCode != null and trayCode != ''"> and bcs.tray_code like concat('%', #{trayCode}, '%')</if>
<if test="cargoHight != null and cargoHight != ''"> and bcs.cargo_hight = #{cargoHight}</if>
<if test="issDouble != null and issDouble != ''"> and bcs.iss_double = #{issDouble}</if>
<if test="groupCodingNo != null and groupCodingNo != ''"> and bcs.group_coding_no = #{groupCodingNo}</if>
<if test="groupCoding != null and groupCoding != ''"> and bcs.group_coding = #{groupCoding}</if>
<if test="cargoSpaceLogo != null and cargoSpaceLogo != ''"> and bcs.cargo_space_logo = #{cargoSpaceLogo}</if>
<if test="thisCargoArea != null and thisCargoArea != ''"> and bcs.this_cargo_area = #{thisCargoArea}</if>
<!-- <if test="params.warehouseDataScope != null and params.warehouseDataScope !=''">-->
<!-- ${params.warehouseDataScope}-->
<!-- </if>-->
</where>
where
group_coding_no = #{groupCodingNo}
order by group_coding desc
</select>
@@ -140,7 +125,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="groupCoding != null">group_coding,</if>
<if test="cargoSpaceLogo != null">cargo_space_logo,</if>
<if test="thisCargoArea != null">this_cargo_area,</if>
</trim>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="cargoSpaceId != null">#{cargoSpaceId},</if>
<if test="warehouseId != null and warehouseId != ''">#{warehouseId},</if>
@@ -161,7 +146,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="groupCoding != null">#{groupCoding},</if>
<if test="cargoSpaceLogo != null">#{cargoSpaceLogo},</if>
<if test="thisCargoArea != null">#{thisCargoArea},</if>
</trim>
</trim>
</insert>
<update id="updateBasCargoSpace" parameterType="BasCargoSpace">
@@ -191,14 +176,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<update id="lockedCargoSpace">
update bas_cargo_space
set locked = #{locked}
where group_coding_no in (
select group_coding_no from bas_cargo_space where cargo_space_id = #{cargoSpaceId}
)
and group_coding > #{groupCoding}
where group_coding_no in (select group_coding_no from bas_cargo_space where cargo_space_id = #{cargoSpaceId})
and group_coding > #{groupCoding}
</update>
<delete id="deleteBasCargoSpaceByCargoSpaceId" parameterType="String">
delete from bas_cargo_space where cargo_space_id = #{cargoSpaceId}
delete
from bas_cargo_space
where cargo_space_id = #{cargoSpaceId}
</delete>
<delete id="deleteBasCargoSpaceByCargoSpaceIds" parameterType="String">
@@ -209,9 +194,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</delete>
<select id="selectStatusCount" resultType="java.util.Map">
SELECT
status,
COUNT(*) as count
SELECT status,
COUNT(*) as count
FROM bas_cargo_space
GROUP BY status
</select>
@@ -219,7 +203,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
SELECT TOP 1 cargo_space_id as cargoSpaceId
FROM bas_cargo_space
WHERE status = '1'
and locked = 'N'
and locked = 'N'
<if test="warehouseId != null">
and warehouse_id = #{warehouseId}
</if>
@@ -255,24 +239,28 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join bas_stock bs on bs.cargo_space_id = bcs.cargo_space_id
left join bas_product bp on bp.product_id = bs.product_id
where br.out_locked = 'N'
<if test="warehouseId != null and warehouseId != ''"> and bcs.warehouse_id = #{warehouseId}</if>
<if test="roadwayId != null and roadwayId != ''"> and bcs.roadway_id = #{roadwayId}</if>
<if test="cargoAreaId != null and cargoAreaId != ''"> and bcs.cargo_area_id = #{cargoAreaId}</if>
<if test="theType != null and theType != ''"> and bcs.the_type = #{theType}</if>
<if test="theTypeName != null and theTypeName != ''"> and bcs.the_type_name like concat('%', #{theTypeName}, '%')</if>
<if test="cargoSpaceName != null and cargoSpaceName != ''"> and bcs.cargo_space_name like concat('%', #{cargoSpaceName}, '%')</if>
<if test="thePlatoon != null "> and bcs.the_platoon = #{thePlatoon}</if>
<if test="theColumn != null "> and bcs.the_column = #{theColumn}</if>
<if test="theFloor != null "> and bcs.the_floor = #{theFloor}</if>
<if test="status != null and status != ''"> and bcs.status = #{status}</if>
<if test="locked != null and locked != ''"> and bcs.locked = #{locked}</if>
<if test="trayCode != null and trayCode != ''"> and bcs.tray_code like concat('%', #{trayCode}, '%')</if>
<if test="cargoHight != null and cargoHight != ''"> and bcs.cargo_hight = #{cargoHight}</if>
<if test="issDouble != null and issDouble != ''"> and bcs.iss_double = #{issDouble}</if>
<if test="groupCodingNo != null and groupCodingNo != ''"> and bcs.group_coding_no = #{groupCodingNo}</if>
<if test="groupCoding != null and groupCoding != ''"> and bcs.group_coding = #{groupCoding}</if>
<if test="cargoSpaceLogo != null and cargoSpaceLogo != ''"> and bcs.cargo_space_logo = #{cargoSpaceLogo}</if>
<if test="spare7 != null and spare7 != ''"> and bs.spare7 = #{spare7}</if>
<if test="stockStatus != null and stockStatus != ''"> and bs.stock_status = #{stockStatus}</if>
<if test="warehouseId != null and warehouseId != ''">and bcs.warehouse_id = #{warehouseId}</if>
<if test="roadwayId != null and roadwayId != ''">and bcs.roadway_id = #{roadwayId}</if>
<if test="cargoAreaId != null and cargoAreaId != ''">and bcs.cargo_area_id = #{cargoAreaId}</if>
<if test="theType != null and theType != ''">and bcs.the_type = #{theType}</if>
<if test="theTypeName != null and theTypeName != ''">and bcs.the_type_name like concat('%', #{theTypeName},
'%')
</if>
<if test="cargoSpaceName != null and cargoSpaceName != ''">and bcs.cargo_space_name like concat('%',
#{cargoSpaceName}, '%')
</if>
<if test="thePlatoon != null ">and bcs.the_platoon = #{thePlatoon}</if>
<if test="theColumn != null ">and bcs.the_column = #{theColumn}</if>
<if test="theFloor != null ">and bcs.the_floor = #{theFloor}</if>
<if test="status != null and status != ''">and bcs.status = #{status}</if>
<if test="locked != null and locked != ''">and bcs.locked = #{locked}</if>
<if test="trayCode != null and trayCode != ''">and bcs.tray_code like concat('%', #{trayCode}, '%')</if>
<if test="cargoHight != null and cargoHight != ''">and bcs.cargo_hight = #{cargoHight}</if>
<if test="issDouble != null and issDouble != ''">and bcs.iss_double = #{issDouble}</if>
<if test="groupCodingNo != null and groupCodingNo != ''">and bcs.group_coding_no = #{groupCodingNo}</if>
<if test="groupCoding != null and groupCoding != ''">and bcs.group_coding = #{groupCoding}</if>
<if test="cargoSpaceLogo != null and cargoSpaceLogo != ''">and bcs.cargo_space_logo = #{cargoSpaceLogo}</if>
<if test="spare7 != null and spare7 != ''">and bs.spare7 = #{spare7}</if>
<if test="stockStatus != null and stockStatus != ''">and bs.stock_status = #{stockStatus}</if>
</select>
</mapper>