Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

avoid loading custom field data for attributesByTimestamp WP

ulferts88457715b8ca
diff --git a/lib/api/v3/work_packages/eager_loading/historic_attributes.rb b/lib/api/v3/work_packages/eager_loading/historic_attributes.rb
index c559e835285..c8d79c2990d 100644
--- a/lib/api/v3/work_packages/eager_loading/historic_attributes.rb
+++ b/lib/api/v3/work_packages/eager_loading/historic_attributes.rb
@@ -109,5 +109,15 @@ module API::V3::WorkPackages::EagerLoading
def timestamp
new_record? ? @timestamp : __getobj__.timestamp
end
+
+ # Since custom fields are currently never displayed in the attributesByTimestamp,
+ # for which this object is used, simply short circuit the loading of the custom field information.
+ def available_custom_fields
+ WorkPackageCustomField.none
+ end
+
+ def define_all_custom_field_accessors
+ nil
+ end
end
end