|
|
@@ -1,15 +1,19 @@
|
|
|
package org.jeecg.modules.business.mapper;
|
|
|
|
|
|
import java.util.Date;
|
|
|
+import java.util.HashMap;
|
|
|
import java.util.List;
|
|
|
|
|
|
+import cn.hutool.core.date.DateTime;
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
import org.apache.ibatis.annotations.Param;
|
|
|
import org.apache.ibatis.annotations.Select;
|
|
|
import org.jeecg.modules.business.dto.TodayBookingQueryDto;
|
|
|
import org.jeecg.modules.business.entity.BusBookingRooms;
|
|
|
import org.jeecg.modules.business.entity.BusRoomBookingOrders;
|
|
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
|
|
+import org.jeecg.modules.business.entity.BusRoomPayType;
|
|
|
import org.jeecg.modules.business.vo.*;
|
|
|
import org.jeecg.modules.rooms.entity.CesRooms;
|
|
|
import org.springframework.format.annotation.DateTimeFormat;
|
|
|
@@ -41,4 +45,25 @@ public interface BusRoomBookingOrdersMapper extends BaseMapper<BusRoomBookingOrd
|
|
|
IPage<KeLiItemVo> getKeBooking(IPage<KeLiItemVo> page,String thirdUserId, String hotelId,String keyw,Integer status);
|
|
|
@Select("SELECT o.id from bus_room_booking_orders o inner join bus_booking_rooms br on o.id = br.booking_orders_id inner join ces_room_layout l on l.id = br.room_layout_id where l.hotel_id = #{hotelId} and o.arrival_time >= now() and o.arrival_time <= DATE_ADD(o.arrival_time,interval 1 day)")
|
|
|
List<BusRoomBookingOrders> countTodayYD(String hotelId);
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 根据手机号查询入住历史列表
|
|
|
+ * @param page
|
|
|
+ * @param hotelId
|
|
|
+ * @param phone
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ @Select("<script>select o.due_out_time,r.name as room_name,layout.name as layout_name,ldp.price,bc.`name`,bc.phone,bc.cert_no, case ifnull(card.id,'0') when '0' then '否' else '是' end as huiyuan from bus_rooms_living_order o inner join bus_customer bc on bc.id=o.contact_id\n" +
|
|
|
+ "left join bus_booking_rooms br on br.id=o.booking_room_id\n" +
|
|
|
+ "left join ces_rooms r on r.id=br.room_id\n" +
|
|
|
+ "left join ces_room_layout layout on layout.id=r.layout_id\n" +
|
|
|
+ "left join (select living_order_id,max(price) as price from bus_living_layout_day_price group by living_order_id) ldp on ldp.living_order_id=o.id\n" +
|
|
|
+ "left join bus_member_card card on card.mobile=bc.phone\n"+
|
|
|
+ "where 1=1" +
|
|
|
+ "<if test='hotelId != null and hotelId !=\"\"'> and o.hotel_id = '${hotelId}' </if>" +
|
|
|
+ "<if test='phone != null and phone !=\"\"'> and bc.phone = '${phone}' </if>" +
|
|
|
+ "</script>")
|
|
|
+ public List<HashMap<String, Object>> ruZhuHistoryList(Page<HashMap<String, Object>> page, @Param("hotelId") String hotelId, @Param("phone") String phone);
|
|
|
+
|
|
|
}
|