fix nfc add customer flow

This commit is contained in:
Thein Lin Kyaw
2020-09-05 13:28:01 +06:30
parent fa630fd527
commit febb398605
8 changed files with 513 additions and 533 deletions

View File

@@ -58,9 +58,9 @@ class Booking < ApplicationRecord
end
end
scope :active, -> {where("booking_status != 'moved'")}
scope :today, -> {where("created_at >= #{Time.now.utc}")}
scope :assign, -> { where(booking_status: 'assign')}
scope :active, -> { where('booking_status != ?', 'moved') }
scope :today, -> { where('created_at >= ?', Time.now) }
scope :assign, -> { where(booking_status: 'assign') }
def self.sync_booking_records(bookings)
if !bookings.nil?