This line gives: TypeError: Cannot read property 'value' of null 
Verify this file is only loaded as needed (the calendar view).