diff --git a/eladmin-system/src/main/java/cn/ysk/cashier/mybatis/mapper/TbCashierCartMapper.java b/eladmin-system/src/main/java/cn/ysk/cashier/mybatis/mapper/TbCashierCartMapper.java index d43bb77a..c9455b3c 100644 --- a/eladmin-system/src/main/java/cn/ysk/cashier/mybatis/mapper/TbCashierCartMapper.java +++ b/eladmin-system/src/main/java/cn/ysk/cashier/mybatis/mapper/TbCashierCartMapper.java @@ -20,7 +20,7 @@ public interface TbCashierCartMapper extends BaseMapper { " from tb_cashier_cart where table_id is not null and shop_id = #{shopId} and status = 'refund' group by shop_Id, master_id order by trade_day desc") List selectCar(@Param("shopId") Integer shopId); - @Select(" SELECT order_id orderId, pending_at, sum(total_amount) totalAmount, count(id) totalCount, count(total_number) totalNumber from tb_cashier_cart where status = 'refund' and shop_id=#{shopId} and table_id=#{tableId} " + + @Select(" SELECT order_id orderId, pending_at, sum(total_amount) totalAmount, count(id) totalCount, sum(total_number) totalNumber from tb_cashier_cart where status = 'refund' and shop_id=#{shopId} and table_id=#{tableId} " + " GROUP BY order_id ORDER BY trade_day") List countPending(@Param("shopId") Integer shopId, @Param("tableId") String tableId);