I have a Rails 4 app in which we have to present the user with a datepicker but the chosen date displayed should be in `MM-DD-YYYY` format. When sending the date to Rails, ActiveRecord does not recognize the format as, I know, it is expecting `YYYY-MM-DD`. Validations fails (date is not present). 

The JS is as follows:

```
$("#some_date").datetimepicker
  pickTime: false
  format: 'MM-DD-YYYY'

```

(the display works great with a superb datepicker that appears). 

Then my slim template:

```
= f.input :date, as: :string, label: false, input_html: { class: 'form-control', value: @visit.date.strftime('%m-%d-%Y') }
p.help-block MM-DD-YYYY

```

If I change the format to `YYYY-MM-DD` it works perfectly and date is saved into PostgreSQL as is, however in the US, the date is usually displayed as `MM-DD-YYYY`. 

I also don't want to get too involved with helper methods or converting the date from html inputs on each controller so PostgreSQL is happy. I was wondering if there is some way the date format can be changed as it goes to the backend?

Within my `config/locales/en.yml`, I do have:

```
date:
  formats:
     default: '%m/%d/%Y'

```

Cheers!