台桌列表返回订单id

打印订单接口
This commit is contained in:
张松
2025-03-06 16:23:38 +08:00
parent ce303ca0b5
commit f3866b0f15
11 changed files with 198 additions and 25 deletions

View File

@@ -4,4 +4,26 @@
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.czg.service.account.mapper.ShopTableMapper">
<select id="pageInfo" resultType="com.czg.account.vo.ShopTableVO">
select a.*, b.id orderId, b.user_id
from tb_shop_table as a
left join tb_order_info as b
on a.table_code = b.table_code and b.`status` = 'unpaid' and b.table_code != '' and
b.table_code is not null
where a.shop_id=#{shopId}
<if test="areaId != null">
and a.area_id=#{areaId}
</if>
<if test="tableCode != null and tableCode != ''">
and a.area_id=#{areaId}
</if>
<if test="status != null and status != ''">
and a.status=#{status}
</if>
<if test="name != null and name != ''">
and a.name like concat('%', #{name}, '%')
</if>
ORDER BY a.create_time
</select>
</mapper>