Patch #37350
closedDo not load attachments in query list with description and last_notes
0%
Description
Currently if you enable description and last notes inline columns in issue list, textilizable loads not required attachments. Attachments are not displayed in this list => it is not required to load it.
This behaviour create lot of not required database queries like:
Attachment Load (0.4ms) SELECT `attachments`.* FROM `attachments` WHERE `attachments`.`container_id` = 62115 AND `attachments`.`container_type` = 'Issue' ORDER BY attachments.created_on ASC, attachments.id ASC /*application:RedmineApp,controller:issues,action:index*/ ↳ app/helpers/application_helper.rb:940:in `+' Attachment Load (0.4ms) SELECT `attachments`.* FROM `attachments` WHERE `attachments`.`container_id` = 62114 AND `attachments`.`container_type` = 'Issue' ORDER BY attachments.created_on ASC, attachments.id ASC /*application:RedmineApp,controller:issues,action:index*/ ↳ app/helpers/application_helper.rb:940:in `+' Attachment Load (0.4ms) SELECT `attachments`.* FROM `attachments` WHERE `attachments`.`container_id` = 62113 AND `attachments`.`container_type` = 'Issue' ORDER BY attachments.created_on ASC, attachm
The attachment patch solves this problem.
Files
Updated by Mischa The Evil over 2 years ago
- Status changed from New to Needs feedback
Alexander Meindl wrote:
... Attachments are not displayed in this list => it is not required to load it...
This is not true. If image attachments are included in either the description or journals using the respective wiki syntax (!!
), the images are rendered in the inline columns in the issue list. See e.g. this query on redmine.org.
This change breaks this behavior.
Updated by Alexander Meindl over 2 years ago
Hi Mischa The Evil,
you are right! This issue can be closed, sorry for this needless noise.
Updated by Marius BĂLTEANU over 2 years ago
- Status changed from Needs feedback to Closed
Closing, thanks for your feedback.