fix module item publish/unpublish logic

test plan:
 in modules page, with draft state enabled:
 - should be able to publish unpublished discussion topics,
   quizzes, assignments, and wiki pages by clicking the cloud icon
 - should be able to unpublish, via the cloud icon:
   * assignments with no submissions
   * quizzes with no submissions
   * discussion topics with no replies
   * wiki pages other than the front page
 - should not be able to unpublish (and a tooltip should appear
   explaining why, rather than an error message when you try):
   * assignments with one or more submissions
   * quizzes with one or more submissions
   * discussion topics with one or more replies
   * the front wiki page
   * attachments

fixes CNVS-9940

Change-Id: I57cd668ff5fa56d9aa2bb219bf06a54f97b8057c
Reviewed-on: https://gerrit.instructure.com/28105
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Sterling Cobb <sterling@instructure.com>
QA-Review: Matt Fairbourn <mfairbourn@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>