自动化立体仓库 - WMS系统
zhang
2025-10-17 6867f6de91378cc8e9e1fe291131d7db0d2993a0
src/main/resources/mapper/OrderMapper.xml
@@ -42,13 +42,59 @@
    </resultMap>
    <update id="updateTel">
        update man_order
        set tel = #{tel}
        where 1=1
        and id = #{orderId}
    </update>
    <update id="updateSettle">
        update man_order
        set settle = #{settle}
        ,update_time = getdate()
        ,update_by = #{userId}
        <if test="userId != null">
            ,update_by = #{userId}
        </if>
        where 1=1
        and id = #{orderId}
    </update>
    <update id="updateSettle2">
        update man_order
        set settle = #{settle}
        ,update_time = getdate()
        ,plt_type = #{plt}
        ,in_time = #{inTime}
        where 1=1
        and id = #{orderId}
    </update>
    <select id="selectComplete" resultMap="BaseResultMap">
        select TOP 5 *
        from man_order
        where 1=1
        and settle = 4
        and status = 1
        order by newID(), create_time asc
    </select>
    <select id="selectorderNoL" resultMap="BaseResultMap">
        select top 10 *
        from man_order
        where 1=1
        <if test="orderNo != null">
            and order_no = #{orderNo}
        </if>
    </select>
    <select id="selectThreeCode" parameterType="string" resultType="string">
        select top 50 three_code
        from three_code_view
        where 1=1
        <if test="threeCode != null">
           and three_code like '%' + #{threeCode} + '%'
        </if>
    </select>
</mapper>