Project

General

Profile

Patch #37057 » 37057.patch

Go MAEDA, 2022-04-30 09:48

View differences:

app/models/attachment.rb
:scope =>
proc do
select("#{Attachment.table_name}.*").
where(container_type: ['Version', 'Project']).
joins(
"LEFT JOIN #{Version.table_name} " \
"ON #{Attachment.table_name}.container_type='Version' " \
......
:scope =>
proc do
select("#{Attachment.table_name}.*").
where(container_type: 'Document').
joins(
"LEFT JOIN #{Document.table_name} " \
"ON #{Attachment.table_name}.container_type='Document' " \
(3-3/3)