I'm new to rails, any tips? and it would be better if you could offer me what to read.
I am adding a date picker plugin to an existing rails4 application. I found this plugin on Github. I followed the instructions and configured everything in my application. A visit to http: // localhost: 3000 / bookings / new looks good, but after I fill in the information and submit it, an error occurs:
ArgumentError in BookingsController
booking_controller.rb:
def new @booking = Booking.new end def create @booking = current_user.bookings.build(booking_params)
new.html.rb
<%= form_for (@booking) do |f| %> <%= render 'shared/errorbooking_messages' %> <%= f.label :date_of_tour %> <input data-provide="datepicker"> <%= f.label :hotel_name %> <%= f.text_field :hotel_name, class: 'form-control' %> <%= f.label :hotel_address %> <%= f.text_field :hotel_address, class: 'form-control' %>
source share