|
|
@@ -853,7 +853,7 @@ public class bookAction extends ActionSupport implements ServletRequestAware {
|
|
|
/**
|
|
|
* 定时任务
|
|
|
*/
|
|
|
- public void setBookStatus() {
|
|
|
+ public void setBookStatus() throws ParseException {
|
|
|
|
|
|
System.out.println("自动接单定时程序");
|
|
|
|
|
|
@@ -864,8 +864,8 @@ public class bookAction extends ActionSupport implements ServletRequestAware {
|
|
|
HotelDict operate = hotelDictService.getById(1000011002);//响应时间 1自动接单 2自动拒单
|
|
|
|
|
|
System.out.println("自动接单定时程序2");
|
|
|
-
|
|
|
- String sqlx = " and create_time <= DATE_SUB(NOW(), INTERVAL " + respTime.getName() + " MINUTE) and order_status = 2 and hotel_is_order = 1";
|
|
|
+ String dateTime = TimeExchange.TimeRangeI(TimeExchange.getTime(), Integer.valueOf(respTime.getName()), "yyyy-MM-dd HH:mm:ss");
|
|
|
+ String sqlx = " and create_time <= '" + dateTime + "' and order_status = 2 and hotel_is_order = 1";
|
|
|
List<Booking> bookings = bookService.queryList(sqlx);
|
|
|
|
|
|
System.out.println("自动接单定时程序3:" + sqlx);
|