two-pack / redmine_xlsx_format_issue_exporter

This is Redmine plugin which exports issue list to XLSX format file.
GNU General Public License v2.0
58 stars 26 forks source link

Custom field with full layout setting not exported #98

Closed boki69 closed 2 years ago

boki69 commented 2 years ago

Hi two-pack!

First of all, I have to thank you for this great plugin!

I think, I found a bug with Redmine 5.

Test scenario for reproduce the wrong behaviour:

  1. Create a custom field like in this picture with Full Width layout setting: kép
  2. Create an issue with this custom field: kép
  3. Filter issues like on the picture (If you check to show this column, it appears under the issue. Cannot select in Available Columns): kép
  4. Cannot set to export in modal window and it is not exported to downloaded xls. kép kép

I make a modification in app/views/hooks/_xlsx_export_dialog_on_issues_index.erb after line 20, and it works for me:

` <% @query.available_columns.each do |c| if !c.inline? and !['last_notes','description'].include?(c.name.to_s) %>


<% end %> <% end %> ` And the end of line 17 and 19 insert this code: `
` Test results: 1. Modal window: ![kép](https://user-images.githubusercontent.com/3695756/196445050-e7318122-bfb4-40fe-b338-fb234f6243a5.png) 2. It is the last column in exported xls: ![kép](https://user-images.githubusercontent.com/3695756/196445260-62ab6fbd-1685-499b-8511-6fe20536a70e.png) Best regards!
two-pack commented 2 years ago

Thank you for reporting the issue. I think this problem is like following csv exporting bug of Redmine. https://www.redmine.org/issues/33169 So how to fix it is like that too.

Can you make a pull request? I don't have enough time to fix it now😓

two-pack commented 2 years ago

We have begun to correct this problem. I am trying to fix it to work with Redmine 4.2.x or later, as the process for older versions is getting in the way and making it difficult to fix. This is going to take long time as it is going to require a major fix.

two-pack commented 2 years ago

@boki69 , I have fixed this issue and pushed it to the next branch. But I have not yet fully tested it, but we encourage you to give it a try. https://github.com/two-pack/redmine_xlsx_format_issue_exporter/tree/issue98

boki69 commented 2 years ago

@two-pack ,

I've tested these scenarios (issue and timelog parts of Redmine):

  1. Export only selected columns and the fulll layout custom field.
  2. Export all columns with the fulll layout custom field.
  3. Export datas when the fulll layout custom field was checked before I start export dialog

Everything is fine. Good job, thank you!

two-pack commented 2 years ago

Thanks @boki69 ‼️ I'll merge this fix after more tests.

two-pack commented 2 years ago

I'm testing it, and got two bugs,

I continue to fix them and test it.

two-pack commented 2 years ago

I fixed this problem and merged. Thanks @boki69 for reporting it☺