Class: Spree::Api::V2::Storefront::TripSearchController
- Inherits:
-
ResourceController
- Object
- ResourceController
- Spree::Api::V2::Storefront::TripSearchController
- Defined in:
- app/controllers/spree/api/v2/storefront/trip_search_controller.rb
Instance Method Summary collapse
Instance Method Details
#index ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'app/controllers/spree/api/v2/storefront/trip_search_controller.rb', line 6 def index trips = SpreeCmCommissioner::TripQuery.new( origin_id: params[:origin_id], destination_id: params[:destination_id], date: params[:date], vendor_id: params[:vendor_id], number_of_guests: params[:number_of_guests], params: params ).call render_serialized_payload { serialize_collection(trips) } end |