app/controllers/custom_fields_controller.rb | 2 ++ app/views/custom_fields/_index.html.erb | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/controllers/custom_fields_controller.rb b/app/controllers/custom_fields_controller.rb index 1679846..a6d1268 100644 --- a/app/controllers/custom_fields_controller.rb +++ b/app/controllers/custom_fields_controller.rb @@ -27,6 +27,8 @@ class CustomFieldsController < ApplicationController respond_to do |format| format.html { @custom_fields_by_type = CustomField.all.group_by {|f| f.class.name } + @custom_fields_projects_count = + IssueCustomField.where(is_for_all: false).joins(:projects).group(:custom_field_id).count } format.api { @custom_fields = CustomField.all diff --git a/app/views/custom_fields/_index.html.erb b/app/views/custom_fields/_index.html.erb index 42efe35..ecff418 100644 --- a/app/views/custom_fields/_index.html.erb +++ b/app/views/custom_fields/_index.html.erb @@ -19,7 +19,7 @@