title: Rails Date Format in edit view
body: <p>I'm creating Edit form in rails using partial for new and edit
  I'm using date picker jquery so user can choose date with jquery-ui</p>
  
  <p>my problem is how do I format all my date fields
  because in edit form it's all showing 'YYYY-MM-DD' 
  I would like it's showing 'dd-mm-yyyy'</p>
  
  <p>for example booking-date, it's showing 2014-04-20, I would like 20-04-2014</p>
  
  <p>I did change
   config/initializers/date_formats.rb
  Date::DATE_FORMATS[:default] = "%d-%m-%Y"
  it's working only in show form but not in Edit mode</p>
  
  <p>also in rails console (using debugger) I check the date format is
  'YYYY-MM-DD' , is there a way to change it</p>
  
  <p>for reference below is my show.html.erb and edit.html.erb (partial)</p>
  
  <p>show.html.erb</p>
  
  <pre><code>  &lt;% if logged_in? %&gt;
      &lt;p&gt;Booking Date &lt;br&gt; &lt;%= @booking.booking_date %&gt;  &lt;/p&gt;
  </code></pre>
  
  <p>edit.html.erb</p>
  
  <pre><code>&lt;%= form_for @booking do |f| %&gt;
      &lt;%= render 'common/form_errors', object: @booking %&gt;
      &lt;%= f.label :booking_date, "Booking Date" %&gt;&lt;br&gt;
      &lt;%= f.text_field :booking_date, :class =&gt; :datepicker, size: 10  %&gt;
  </code></pre>