package com.zy.asrs.mapper; import com.baomidou.mybatisplus.mapper.BaseMapper; import com.zy.asrs.entity.LocMast; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Select; import org.springframework.stereotype.Repository; import java.util.List; @Mapper @Repository public interface LocMastMapper extends BaseMapper { List selectLocByLev(Integer lev); LocMast queryFreeLocMast(@Param("row") Integer row, @Param("locType1") Short locType1,@Param("whsType") Long whsType); @Select("select loc_no from asr_loc_mast where 1=1 and loc_sts = 'O' and crn_no = #{crnNo}") List queryGroupEmptyStock(Integer crnNo,@Param("whsType") Long whsType); @Select("select count(*) as count from asr_loc_mast where 1=1 and loc_sts = 'O' and loc_type1 = #{locType1} and crn_no = #{crnNo}") Integer selectEmptyLocCount(@Param("locType1") Short locType1, @Param("crnNo") Integer crnNo,@Param("whsType") Long whsType); List queryShallowLocFMast(@Param("crnNo") Integer crnNo,@Param("whsType") Long whsType); List selectLocShuttleMoveUnilateralY(@Param("bay")Integer bay,@Param("lev")Integer lev,@Param("whsType") Long whsType); List selectLocShuttleMoveUnilateralN(@Param("bay")Integer bay,@Param("lev")Integer lev,@Param("whsType") Long whsType); /* * 获取目标库位所在巷道最浅非空库位 深>浅 * */ // LocMast selectLocByLocStsPakInF1(@Param("locNos") List locNos,@Param("whsType") Long whsType); LocMast selectLocByLocStsPakInF1(@Param("crnNo") Integer crnNo,@Param("bay") Integer bay,@Param("lev") Integer lev,@Param("gro") Integer gro,@Param("whsType") Long whsType); /* * 获取目标库位所在巷道最浅非空库位 深<浅 * */ // LocMast selectLocByLocStsPakInF2(@Param("locNos") List locNos,@Param("whsType") Long whsType); LocMast selectLocByLocStsPakInF2(@Param("crnNo") Integer crnNo,@Param("bay") Integer bay,@Param("lev") Integer lev,@Param("gro") Integer gro,@Param("whsType") Long whsType); /* * 获取目标库位所在巷道最深空库位 深>浅 * */ // LocMast selectLocByLocStsPakInO1(@Param("locNos") List locNos,@Param("whsType") Long whsType); LocMast selectLocByLocStsPakInO1(@Param("crnNo") Integer crnNo,@Param("bay") Integer bay,@Param("lev") Integer lev,@Param("gro") Integer gro,@Param("whsType") Long whsType); /* * 获取目标库位所在巷道最深空库位 深<浅 * */ // LocMast selectLocByLocStsPakInO2(@Param("locNos") List locNos,@Param("whsType") Long whsType); LocMast selectLocByLocStsPakInO2(@Param("crnNo") Integer crnNo,@Param("bay") Integer bay,@Param("lev") Integer lev,@Param("gro") Integer gro,@Param("whsType") Long whsType); /** * 查找第一个冻结的库位 * @param locNoList 库位号集合 * @return 库位号 */ String findFirstFrozenLocNo(@Param("locNoList") List locNoList); }