2017-01-20 09:02:50 +00:00
|
|
|
Rails.application.routes.draw do
|
|
|
|
|
|
|
|
locales = Site.find_by(site_active: true).in_use_locales rescue I18n.available_locales
|
|
|
|
scope "(:locale)", locale: Regexp.new(locales.join("|")) do
|
2018-01-24 08:29:28 +00:00
|
|
|
get "/xhr/property_hires/check_availability" => "property_hires#check_availability"
|
2017-01-20 09:02:50 +00:00
|
|
|
post "/xhr/property_hires/make_booking" => "property_hires#make_booking"
|
|
|
|
get "/xhr/property_hires/get_bookings" => "property_hires#get_bookings"
|
|
|
|
namespace :admin do
|
|
|
|
resources :property_hires do
|
|
|
|
member do
|
|
|
|
get "edit_location"
|
|
|
|
patch "update_location"
|
|
|
|
delete "destroy_location"
|
|
|
|
get "show_booking_details"
|
|
|
|
get "pass_booking"
|
2018-01-17 07:53:58 +00:00
|
|
|
delete "delete_booking_details"
|
2017-01-20 09:02:50 +00:00
|
|
|
end
|
|
|
|
collection do
|
|
|
|
get "manage_locations"
|
|
|
|
get "add_location"
|
|
|
|
post "create_location"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|