Add Issue Stats from the Issues API
Closed via https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/27366
Changes to issues api
When issues_controller endpoint was used for search, the parameters passed to the controller were slightly different then the ones passed to API. Because the searchbar UI is reused in different places and builds the parameters passed to request in same way we need to account for old parameter names.
Add issues_statistics api endpoints
Adds issue_statistics api endpoints for issue lists and returns counts of issues for all, closed and opened states.
Expose more label attributes based on a param
When requesting issues list through API expose more attributes for labels, like color, description if with_labels_data param is being passed, avoiding this way to change response schema for users that already use API.