On the Syllabus page, "Jump to Today" does not work if there are no dates on assignments or if assignments are in the future
Steps to reproduce:
Add assignments with due dates in the future
Edit the Syllabus and add significant content. Save.
Click the Jump to Today link
Expected behavior:
Jump to the first row of the assignments table
Actual behavior:
Does not jump
Additional notes:
I think the problem is on line 176 of SyllabusBehaviors.js where the code sets a value for $lastBefore if it has not been set. However, the code on this line sets the variable to a row object rather than a date string. I suspect the correct code would be:
if (!$lastBefore) $lastBefore = $('tr.date:first').find('.day_date').attr('data-date')
Summary:
On the Syllabus page, "Jump to Today" does not work if there are no dates on assignments or if assignments are in the future
Steps to reproduce:
Expected behavior:
Jump to the first row of the assignments table
Actual behavior:
Does not jump
Additional notes:
I think the problem is on line 176 of SyllabusBehaviors.js where the code sets a value for $lastBefore if it has not been set. However, the code on this line sets the variable to a row object rather than a date string. I suspect the correct code would be:
if (!$lastBefore) $lastBefore = $('tr.date:first').find('.day_date').attr('data-date')