|
|
|
@ -16,11 +16,20 @@
|
|
|
|
|
</resultMap>
|
|
|
|
|
<sql id="Base_Column_List">
|
|
|
|
|
<!--@mbg.generated-->
|
|
|
|
|
id, code, `name`, workPlaceIdFk, remark, createTime, updateTime, `createUser`, updateUser
|
|
|
|
|
id,
|
|
|
|
|
code,
|
|
|
|
|
`name`,
|
|
|
|
|
workPlaceIdFk,
|
|
|
|
|
remark,
|
|
|
|
|
createTime,
|
|
|
|
|
updateTime,
|
|
|
|
|
`createUser`,
|
|
|
|
|
updateUser
|
|
|
|
|
</sql>
|
|
|
|
|
|
|
|
|
|
<select id="selectMaxLayer" resultType="java.lang.Integer">
|
|
|
|
|
select max(layer) as layer from sys_workplace_queue
|
|
|
|
|
select max(layer) as layer
|
|
|
|
|
from sys_workplace_queue
|
|
|
|
|
<where>
|
|
|
|
|
<if test="freightCode != null and freightCode != ''">
|
|
|
|
|
AND freightCode = #{freightCode}
|
|
|
|
@ -29,15 +38,19 @@
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
<select id="filterBindList" resultType="com.glxp.api.res.basic.SysWorkplaceQueueResponse">
|
|
|
|
|
select swq.*,bp.nameCode,
|
|
|
|
|
select swq.*,
|
|
|
|
|
bp.nameCode,
|
|
|
|
|
COALESCE(bp.ggxh, bp.bzgg) AS ggxh,
|
|
|
|
|
bp.cpmctymc
|
|
|
|
|
bp.cpmctymc,sys_workplace.workplaceName
|
|
|
|
|
from sys_workplace_queue swq
|
|
|
|
|
left join
|
|
|
|
|
(select bu.id, bp.nameCode, bp.ggxh, bp.cpmctymc, bp.bzgg
|
|
|
|
|
from basic_udirel bu
|
|
|
|
|
left join basic_products bp ON bu.uuid = bp.uuid
|
|
|
|
|
group by bu.id, bp.nameCode, bp.ggxh, bp.cpmctymc) as bp ON bp.id = swq.relId
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
left join sys_workplace on swq.workPlaceIdFk = sys_workplace.workplaceId
|
|
|
|
|
<where>
|
|
|
|
|
<if test="key != null and key != ''">
|
|
|
|
|
AND (
|
|
|
|
@ -125,7 +138,8 @@
|
|
|
|
|
</where>
|
|
|
|
|
</select>
|
|
|
|
|
<select id="selectMaxGrid" resultType="java.lang.Integer">
|
|
|
|
|
select max(grid) as grid from sys_workplace_queue
|
|
|
|
|
select max(grid) as grid
|
|
|
|
|
from sys_workplace_queue
|
|
|
|
|
<where>
|
|
|
|
|
<if test="freightCode != null and freightCode != ''">
|
|
|
|
|
AND freightCode = #{freightCode}
|
|
|
|
@ -136,7 +150,8 @@
|
|
|
|
|
</where>
|
|
|
|
|
</select>
|
|
|
|
|
<select id="selectMaxCode" resultType="java.lang.String">
|
|
|
|
|
select max(code) as code from sys_workplace_queue
|
|
|
|
|
select max(code) as code
|
|
|
|
|
from sys_workplace_queue
|
|
|
|
|
<where>
|
|
|
|
|
<if test="layerCode != null and layerCode != ''">
|
|
|
|
|
AND layerCode = #{layerCode}
|
|
|
|
@ -144,7 +159,8 @@
|
|
|
|
|
</where>
|
|
|
|
|
</select>
|
|
|
|
|
<select id="selectByLayerCode" resultType="com.glxp.api.entity.basic.SysWorkplaceQueue">
|
|
|
|
|
select * from sys_workplace_queue
|
|
|
|
|
select *
|
|
|
|
|
from sys_workplace_queue
|
|
|
|
|
<where>
|
|
|
|
|
<if test="layerCode != null and layerCode != ''">
|
|
|
|
|
AND layerCode = #{layerCode}
|
|
|
|
@ -171,5 +187,4 @@
|
|
|
|
|
</set>
|
|
|
|
|
WHERE code = #{code}
|
|
|
|
|
</update>
|
|
|
|
|
|
|
|
|
|
</mapper>
|
|
|
|
|