add booking

This commit is contained in:
phyusin
2018-02-05 11:05:58 +06:30
parent 991bc48505
commit 8fed8d701a
2 changed files with 13 additions and 5 deletions

View File

@@ -49,10 +49,15 @@ class Origami::SplitBillController < BaseOrigamiController
end
end
else
puts "new booking"
puts "new order"
puts "update order_id in order"
puts "do process"
if params[:type] == "Table"
type = "TableBooking"
else
type = "RoomBooking"
end
booking = Booking.create({:dining_facility_id => params[:dining_id],:type => type,
:checkin_at => Time.now.utc, :checkin_by => current_user.name,
:booking_status => "assign" })
end
# Bind shift sale id to sale