Fixes #6949/BZ970600: restore sorting on task status.

The functionality for sorting on task status was removed
with a1de666c5722df480639ee28a38b9739763c5428 and never
ported over to the v2 API.  This commit adds the sorting
back into the v2 API controller.

http://projects.theforeman.org/issues/6949
https://bugzilla.redhat.com/show_bug.cgi?id=970600

Note that this PR is dependent on #4540 being merged.
True, perhaps we should just remove this controller and mark the bug as invalid?