Bug #2359
Extended fields plugin breaks PDF export
90%
Description
PDF export of issue list doesn’t work after installation of extended fields plugin.
Environment info¶
Environment: Redmine version 2.5.1.stable Ruby version 1.9.3-p231 (2012-05-25) [i386-mingw32] Rails version 3.2.17 Environment production Database adapter Mysql2 SCM: Subversion 1.8.8 Git 1.9.0 Filesystem Redmine plugins: extended_fields 0.2.3 redmine_all_files 0.0.3 redmine_codebutton 0.0.1 redmine_screenshot_paste 2.1.0 redmine_tags 2.1.0 sidebar_hide 0.0.7
Logs¶
NoMethodError (undefined method `find_custom_field_template' for #<IssuesController:0x3704490>): lib/redmine/export/pdf.rb:302:in `block in calc_col_width' app/helpers/issues_helper.rb:29:in `block in issue_list' app/helpers/issues_helper.rb:25:in `each' app/helpers/issues_helper.rb:25:in `issue_list' lib/redmine/export/pdf.rb:300:in `calc_col_width' lib/redmine/export/pdf.rb:428:in `issues_to_pdf' app/controllers/issues_controller.rb:93:in `block (2 levels) in index' app/controllers/issues_controller.rb:86:in `index'
Related issues
Associated revisions
History
#1 Updated by Sergey B almost 10 years ago
Any ideas how to fix it?
#2 Updated by Jacek Pasternak almost 10 years ago
You can find quick-fix here: http://projects.andriylesyuk.com/issues/2098#note-22 and here http://projects.andriylesyuk.com/issues/2098#note-24
#3 Updated by Sergey B almost 10 years ago
Jacek Pasternak wrote:
You can find quick-fix here: http://projects.andriylesyuk.com/issues/2098#note-22 and here http://projects.andriylesyuk.com/issues/2098#note-24
After applying this fix PDF export fails with Undefined method 'link_to’.
#4 Updated by Jacek Pasternak almost 10 years ago
- File extended_fields.zip added
I’ve tested it on Redmine 2.5.3. Maybe the next problem is with Redmine 2.5.1. Try attached version.
#5 Updated by Sergey B almost 10 years ago
The difference was in extended_issues_controller_patch.rb and extended_fields_helper_patch.rb. After I copied your version, I got the following:
NoMethodError (undefined method `link_to' for #<IssuesController:0x36618a8>): lib/redmine/field_format.rb:157:in `block in formatted_value' lib/redmine/field_format.rb:157:in `map' lib/redmine/field_format.rb:157:in `formatted_value' lib/redmine/field_format.rb:146:in `formatted_custom_value' app/helpers/application_helper.rb:187:in `format_object' lib/redmine/export/pdf.rb:302:in `block in calc_col_width' app/helpers/issues_helper.rb:29:in `block in issue_list' app/helpers/issues_helper.rb:25:in `each' app/helpers/issues_helper.rb:25:in `issue_list' lib/redmine/export/pdf.rb:300:in `calc_col_width' lib/redmine/export/pdf.rb:428:in `issues_to_pdf' app/controllers/issues_controller.rb:93:in `block (2 levels) in index' app/controllers/issues_controller.rb:86:in `index'
I suppose, in 2.5.3 there must be a method link_to in IssuesController which is absent in 2.5.1.
#6 Updated by Jacek Pasternak over 9 years ago
It’s defined in [Redmine root]\lib\redmine\views\other_formats_builder.rb (in 2.5.3 of course). If you don’t have it, maybe it’s time to upgrade.
#7 Updated by Andriy Lesyuk about 9 years ago
- Status changed from New to Open
- Assignee set to Andriy Lesyuk
- Target version set to 0.2.4
#8 Updated by Andriy Lesyuk about 8 years ago
- Duplicates Bug #2318: Issues as pdf added
#9 Updated by Andriy Lesyuk about 8 years ago
- Related to Bug #2261: issues PDF view and descriptions added
#10 Updated by Andriy Lesyuk about 8 years ago
- Related to Bug #2098: Failure in XLS Export (undefined method `find_custom_field_template' for #<XlsExportController) added
#11 Updated by Andriy Lesyuk about 8 years ago
- Related to Bug #1936: Undefined method `find_custom_field_template' added
#12 Updated by Andriy Lesyuk about 8 years ago
Sergey, your patched version contains Polish locale. I wonder, if you would let me to include it into the repository? Is the translation complete and fine to be published?
#13 Updated by Andriy Lesyuk about 8 years ago
- Status changed from Open to In Progress
- % Done changed from 0 to 90
I think this issue (and similar) should be fixed with r124. Please check and let me know.
#14 Updated by Sergey B about 8 years ago
Andrey, the patch is not mine. It’s attached by Jacek Pasternak.
#15 Updated by Andriy Lesyuk about 8 years ago
#16 Updated by Jacek Pasternak about 8 years ago
Andriy Lesyuk wrote:
I’m using this translations in production environment and Polish is my native language, so ... they are ready to publish (plase do this). It’s based on English translatioins (I don’t knon Russian), but should be ok.
Btw. is there any chance to make Extedted Fileds plugin working in Redmine 3.0.x? It’s causing bugs in issues list.
#17 Updated by Andriy Lesyuk about 8 years ago
Jacek Pasternak wrote:
Btw. is there any chance to make Extedted Fileds plugin working in Redmine 3.0.x? It’s causing bugs in issues list.
Working on this right now. It’s quite possible, that the latest version in the repository already works fine under Redmine 3.0. Can’t guarantee for the moment though...
You can share bugs in the issue list in #2365.
And, thanks for the Polish translation - will use it.
#18 Updated by Jacek Pasternak about 8 years ago
Andriy Lesyuk wrote:
Jacek Pasternak wrote:
Working on this right now. It’s quite possible, that the latest version in the repository already works fine under Redmine 3.0. Can’t guarantee for the moment though...
It’s not fixed yet. I’m attching my patch to several bugs found in 0.2.3. Some are fixed in nerwest release and some not. It’s mostly based on my patched version which is attached to this issue. Hope it will be useful.
#19 Updated by Andriy Lesyuk about 8 years ago
Jacek Pasternak wrote:
It’s not fixed yet. I’m attching my patch to several bugs found in 0.2.3. Some are fixed in nerwest release and some not. It’s mostly based on my patched version which is attached to this issue. Hope it will be useful.
Are you saying, that you are still getting undefined method `find_custom_field_template'
? Or now there are errors related to nil
?
#20 Updated by Jacek Pasternak about 8 years ago
Andriy Lesyuk wrote:
Are you saying, that you are still getting
undefined method `find_custom_field_template'
? Or now there are errors related tonil
?
No. Just this patch worked for me. Maybe some issues was handled in different way and parts of this patch are not necessary now. I’ve tested current version just against “double # column” bug. Waiting for fixing this to make other testing.