Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to latest version of bootstrap-datepicker #28

Closed
kartik-v opened this issue Mar 22, 2015 · 5 comments
Closed

Update to latest version of bootstrap-datepicker #28

kartik-v opened this issue Mar 22, 2015 · 5 comments

Comments

@kartik-v
Copy link
Owner

No description provided.

@trinhkethanh
Copy link

I update new version then this error:

bootstrap-datepicker.vi.min.js:1 Uncaught TypeError: Cannot read property 'dates' of undefined

untitled

@kartik-v
Copy link
Owner Author

Cannot replicate your error - check the demo pages which use the same release and they work fine.

It can be caching issues on your client - clean up your web server assets folder, clean up your browser cache and restart.

@trinhkethanh
Copy link

I use same release demo pages of you.

'date', 'type' => DatePicker::TYPE_COMPONENT_PREPEND, 'value' => ArrayHelper::getValue($_REQUEST, 'date', ''), 'options' => [ 'placeholder' => Yii::t('cms', 'select_date') ], 'language' => 'en', 'pluginOptions' => [ 'autoclose'=>true, 'format' => 'dd-mm-yyyy', 'endDate' => date('d-m-Y'), ] ]); ?>

However cannot translate language except 'language' => 'en'. When 'language' => 'vi' the error occurred. Thanks so much!

@kartik-v kartik-v reopened this Mar 23, 2015
@kartik-v
Copy link
Owner Author

This is fixed via #29.

Ok this is due to the new noconflict implementation for folks using jquery UI along with this extension. The JUI datepicker uses the same namespace $.fn.datepicker.

The new update involved extending bootstrap-datepicker and using its noconflict method to create a new kvDatepicker plugin. This was not reflecting in locale / translation files - which is now resolved.

@trinhkethanh
Copy link

Ok, thanks :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants