From 75626d5f0134770065a18c73223bdd798866fa5b Mon Sep 17 00:00:00 2001 From: Phil Hughes Date: Wed, 20 Apr 2016 17:00:12 +0100 Subject: Label text color comes from JSON Created issuable singleton to house the filtering --- app/controllers/projects/issues_controller.rb | 2 +- app/controllers/projects/merge_requests_controller.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'app/controllers/projects') diff --git a/app/controllers/projects/issues_controller.rb b/app/controllers/projects/issues_controller.rb index 8ce6772c400..89e43164926 100644 --- a/app/controllers/projects/issues_controller.rb +++ b/app/controllers/projects/issues_controller.rb @@ -41,7 +41,7 @@ class Projects::IssuesController < Projects::ApplicationController format.json do render json: { html: view_to_html_string("projects/issues/_issues"), - labels: @labels + labels: @labels.as_json(methods: :text_color) } end end diff --git a/app/controllers/projects/merge_requests_controller.rb b/app/controllers/projects/merge_requests_controller.rb index e33fb4ddf13..1388ea9d66c 100644 --- a/app/controllers/projects/merge_requests_controller.rb +++ b/app/controllers/projects/merge_requests_controller.rb @@ -45,7 +45,7 @@ class Projects::MergeRequestsController < Projects::ApplicationController format.json do render json: { html: view_to_html_string("projects/merge_requests/_merge_requests"), - labels: @labels + labels: @labels.as_json(methods: :text_color) } end end -- cgit v1.2.1