Commit ab722343 authored by Phil Hughes's avatar Phil Hughes

Fixed tests

parent 9d09bd08
...@@ -2,12 +2,14 @@ class @DueDateSelect ...@@ -2,12 +2,14 @@ class @DueDateSelect
constructor: -> constructor: ->
# Milestone edit/new form # Milestone edit/new form
$datePicker = $('.datepicker') $datePicker = $('.datepicker')
$dueDate = $('#milestone_due_date')
$datePicker.datepicker if $datePicker.length
dateFormat: 'yy-mm-dd' $dueDate = $('#milestone_due_date')
onSelect: (dateText, inst) -> $datePicker.datepicker
$dueDate.val(dateText) dateFormat: 'yy-mm-dd'
.datepicker('setDate', $.datepicker.parseDate('yy-mm-dd', $dueDate.val())) onSelect: (dateText, inst) ->
$dueDate.val(dateText)
.datepicker('setDate', $.datepicker.parseDate('yy-mm-dd', $dueDate.val()))
$('.js-clear-due-date').on 'click', (e) -> $('.js-clear-due-date').on 'click', (e) ->
e.preventDefault() e.preventDefault()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment