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

Timepicker buttons not binding to the correct timepicker on page #55

Open
borzale opened this issue Dec 10, 2012 · 0 comments
Open

Timepicker buttons not binding to the correct timepicker on page #55

borzale opened this issue Dec 10, 2012 · 0 comments

Comments

@borzale
Copy link

borzale commented Dec 10, 2012

Hey there,

While using this plugin today I found a problem where if I had more than one timepicker on the page which used a button to open, it would not take into account all the timepickers. It would just bind it to the last one.

The problem line seems to be here (#280):
$(button).bind("click.timepicker", function () {

I have gone ahead and quickly changed it to suit my application. As in, all my timepickers are contained in their own parent div element. It will use the input variable to bind the event, rather than inserting it straight into a jQuery selector object:
input.parent().find(button).bind("click.timepicker", function () {

This is not the best solution and won't work for everyone, but I thought it would be helpful pointing out the issue.

Cheers, thanks for the plugin!

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

No branches or pull requests

1 participant