台桌 用餐人数
This commit is contained in:
@@ -18,6 +18,7 @@ public class BkTableVO {
|
||||
public static class TableVO {
|
||||
private Long tableId;
|
||||
private String tableName;
|
||||
private Integer tableUserNum;
|
||||
private List<BkOrder> bkOrders;
|
||||
}
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
`area`.`name` as area_name,
|
||||
`table`.id as table_id,
|
||||
`table`.`name` as table_name,
|
||||
`table`.`max_capacity` as table_user_num,
|
||||
`order`.call_phone,
|
||||
`order`.call_username,
|
||||
`order`.booking_phone,
|
||||
@@ -54,6 +55,7 @@
|
||||
<!-- 桌台级别映射 -->
|
||||
<id property="tableId" column="table_id"/>
|
||||
<result property="tableName" column="table_name"/>
|
||||
<result property="tableUserNum" column="table_user_num"/>
|
||||
|
||||
<!-- 嵌套集合:订单列表 -->
|
||||
<collection property="bkOrders" ofType="com.czg.account.vo.BkTableVO$BkOrder">
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
detail.food_serve_time AS foodServeTime
|
||||
FROM `tb_order_detail` detail
|
||||
INNER JOIN `tb_order_info` `order` ON detail.order_id = `order`.id AND `order`.`status` = 'unpaid'
|
||||
LEFT JOIN `tb_shop_staff` `staff` ON staff.id = `order`.staff_id
|
||||
LEFT JOIN `tb_shop_staff` `staff` ON staff.id = `order`.staff_id and staff.shop_id = #{shopId}
|
||||
LEFT JOIN `tb_shop_table` `table` ON `order`.table_code = `table`.table_code
|
||||
LEFT JOIN `tb_shop_table_area` `area` ON `table`.area_id = `area`.id
|
||||
WHERE detail.shop_id = #{shopId}
|
||||
@@ -49,7 +49,7 @@
|
||||
FROM
|
||||
`tb_order_detail` detail
|
||||
INNER JOIN `tb_order_info` `order` ON detail.order_id = `order`.id AND `order`.`status` = 'unpaid'
|
||||
LEFT JOIN `tb_shop_staff` `staff` ON staff.id = `order`.staff_id
|
||||
LEFT JOIN `tb_shop_staff` `staff` ON staff.id = `order`.staff_id and staff.shop_id = #{shopId}
|
||||
LEFT JOIN `tb_shop_table` `table` ON `order`.table_code = `table`.table_code
|
||||
LEFT JOIN `tb_shop_table_area` `area` ON `table`.area_id = `area`.id
|
||||
WHERE
|
||||
@@ -81,7 +81,7 @@
|
||||
FROM `tb_order_detail` detail
|
||||
INNER JOIN `tb_order_info` `order` ON detail.order_id = `order`.id AND `order`.`status` = 'unpaid'
|
||||
LEFT JOIN `tb_shop_table` `table` ON `order`.table_code = `table`.table_code
|
||||
LEFT JOIN `tb_shop_staff` `staff` ON staff.id = `order`.staff_id
|
||||
LEFT JOIN `tb_shop_staff` `staff` ON staff.id = `order`.staff_id and staff.shop_id = #{shopId}
|
||||
WHERE detail.shop_id = #{shopId}
|
||||
AND detail.`status` = 'wait-pay'
|
||||
<if test="orderId != null">
|
||||
|
||||
Reference in New Issue
Block a user