pass locale to datepicker, use gem for that

This commit is contained in:
wvengen 2013-07-07 01:47:22 +02:00
parent 76645ebd12
commit 8080cd6b7e
8 changed files with 12 additions and 840 deletions

View file

@ -3,8 +3,9 @@
//= require jquery_ujs
//= require twitter/bootstrap
//= require jquery.tokeninput
//= require bootstrap-datepicker
//= require bootstrap-datepicker.de
//= require bootstrap-datepicker/core
//= require bootstrap-datepicker/locales/bootstrap-datepicker.de
//= require bootstrap-datepicker/locales/bootstrap-datepicker.nl
//= require jquery.observe_field
//= require rails.validations
//= require_self
@ -112,7 +113,7 @@ $(function() {
});
// Use bootstrap datepicker for dateinput
$('.datepicker').datepicker({format: 'yyyy-mm-dd', weekStart: 1, language: 'de'});
$('.datepicker').datepicker({format: 'yyyy-mm-dd', language: I18n.locale});
});

View file

@ -1,4 +1,5 @@
/*
*= require bootstrap_and_overrides
*= require token-input-bootstrappy
*/
*= require bootstrap-datepicker
*/

View file

@ -31,10 +31,6 @@ body {
// Example:
// @linkColor: #ff0000;
// Bootstrap datepicker
@import "datepicker";
// Custom styles
// Fix empty dd tags in horizontal dl, see https://github.com/twitter/bootstrap/issues/4062