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

onCancel function? #88

Open
reedhastings opened this issue May 28, 2020 · 1 comment
Open

onCancel function? #88

reedhastings opened this issue May 28, 2020 · 1 comment

Comments

@reedhastings
Copy link

Is there a way to cause something to happen if the user cancels out of the edit? For example, on a scrollable list of many rows, I want to make sure focus in set back to that row instead of the table being redrawn and focus moving to beginning of list.

I was thinking of using the scrollTo() function on DataTables but not sure where that code should go. Maybe there is another way to accomplish this.

@reedhastings
Copy link
Author

I was able to achieve my goal by commenting out "table.draw();" under "cancelEditableCell" in dataTables.cellEdit.js. Is there a reason the entire table was being redrawn on cancel?

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