このコミットが含まれているのは:
2026-10-28 20:57:22 +09:00
コミット 614a12e7aa
18個のファイルの変更、175行の追加、107行の削除
+12
ファイルの表示
@@ -29,6 +29,18 @@ class CountsDefaults
end
end.join(' ')
end
if ['posts', 'tags'].include?(resource)
fields = CountsResourceDefinition.new(resource).output_fields
selected = details.fetch('columns').split(' ')
details['columns'] = fields.map { _1[:key] }.select { selected.include?(_1) }.join(' ')
order = lambda do |items, prefix|
items.flat_map do |field|
path = [prefix, field[:key]].compact.join('.')
[path, *order.call(field.fetch(:children, []), path)]
end
end
details['order'] = order.call(fields, nil).join(' ')
end
['latest', 'history'].each do |definition|
result << { definition:, mode: 'details', params: details }
end