fix bugs and improvement

This commit is contained in:
Thein Lin Kyaw
2020-06-16 12:26:25 +06:30
parent 160c43699e
commit e697108a6e
8 changed files with 18 additions and 26 deletions

View File

@@ -61,7 +61,6 @@ class Booking < ApplicationRecord
scope :active, -> {where("booking_status != 'moved'")}
scope :today, -> {where("created_at >= #{Time.now.utc}")}
scope :assign, -> { where(booking_status: 'assign')}
scope :within_time_limit, -> { where(checkin_at: Lookup.get_checkin_time_limit.hours.ago..DateTime::Infinity.new) }
def self.sync_booking_records(bookings)
if !bookings.nil?