MarkUsProject/Markus — pull request #1750 by bmuscede (2014-09-12 21:28:18+00:00)
Title: Issue 1728

**ISSUE:** https://github.com/MarkUsProject/Markus/issues/1728

**DESCRIPTION:** If you try to CSV-upload a hidden assignment, the assignment isn't created properly. Additionally, if you make an assignment hidden, the assignment sidebar does not work properly. It appears to be created in the database, and appears in the table, but trying to access it raises an error.

**FIX:** The link generation methods from `_assignments_dropdown_menu.html.erb` to create the hidden links were not used properly. These would result in error when the sidebar was generated and cause assignments to be unreachable. Instead, the `controller` and `action` sections on lines `97` and `98` were switched to point to the correct page and to have the correct action. Also, on lines `121 - 123` a check was inserted to see if the current assignment is hidden. If so, the assignment sidebar will display that the assignment is hidden.

**TESTING:** Various hidden assignments were added and tested to ensure that all assignments were still reachable. Additionally, previously created assignments were set to `hidden` to see if TAs and the admin could still access all assignments.