mirror of
https://github.com/meineerde/redmine.git
synced 2026-02-06 09:03:25 +00:00
Issue#editable_custom_field_values very slow for issues with many custom fields (#23334).
Patch by Stephane Evr. git-svn-id: http://svn.redmine.org/redmine/trunk@15742 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
d12a3d345c
commit
28fc7df5c4
@ -574,8 +574,9 @@ class Issue < ActiveRecord::Base
|
||||
|
||||
# Returns the custom_field_values that can be edited by the given user
|
||||
def editable_custom_field_values(user=nil)
|
||||
read_only = read_only_attribute_names(user)
|
||||
visible_custom_field_values(user).reject do |value|
|
||||
read_only_attribute_names(user).include?(value.custom_field_id.to_s)
|
||||
read_only.include?(value.custom_field_id.to_s)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user