From 174ab2d93a009c740bb6e45f433f472adba087f2 Mon Sep 17 00:00:00 2001 From: Sam Date: Thu, 16 Nov 2017 15:13:58 +1100 Subject: [PATCH] minor, ensure ordering of custom fields is consistent --- app/models/concerns/has_custom_fields.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/concerns/has_custom_fields.rb b/app/models/concerns/has_custom_fields.rb index c6e929d8e0..519f8deb51 100644 --- a/app/models/concerns/has_custom_fields.rb +++ b/app/models/concerns/has_custom_fields.rb @@ -215,7 +215,7 @@ module HasCustomFields def refresh_custom_fields_from_db target = Hash.new - _custom_fields.pluck(:name, :value).each do |key, value| + _custom_fields.order('id asc').pluck(:name, :value).each do |key, value| self.class.append_custom_field(target, key, value) end @custom_fields_orig = target