caktus/django-timepiece — pull request #703 by rebecca-caktus (2013-05-20 20:26:53+00:00)
Title: Fixes #651 - Prevent creation two active entries on clock in

Addresses the situation in two active entries are created when the user clicks the "clock in" button twice in a row. In accordance with the discussion on #651, I added some Javascript to prevent double clicks, and used select_for_update() to lock the user during clock in.

There may be other places where this code could be useful - let me know and I will add it.

See #651.