check booking checkout_at
This commit is contained in:
@@ -81,6 +81,7 @@ class DiningFacility < ApplicationRecord
|
|||||||
now = Time.now.utc
|
now = Time.now.utc
|
||||||
hr = (now.strftime("%H").to_i).to_int
|
hr = (now.strftime("%H").to_i).to_int
|
||||||
min = (now.strftime("%M").to_i).to_int
|
min = (now.strftime("%M").to_i).to_int
|
||||||
|
if !booking.checkout_at.nil?
|
||||||
checkout_at = booking.checkout_at.utc
|
checkout_at = booking.checkout_at.utc
|
||||||
checkout_at_hr = (checkout_at.utc.strftime("%H").to_i).to_int
|
checkout_at_hr = (checkout_at.utc.strftime("%H").to_i).to_int
|
||||||
checkout_at_min = (checkout_at.utc.strftime("%M").to_i).to_int
|
checkout_at_min = (checkout_at.utc.strftime("%M").to_i).to_int
|
||||||
@@ -90,4 +91,5 @@ class DiningFacility < ApplicationRecord
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user