Merge pull request #2231 from biosistemika/SCI-4108-bug-at-report-generation

SCI-4108 Docx report error because of checklist does not have any item
This commit is contained in:
Miha Mencin 2019-11-25 17:33:20 +01:00 committed by GitHub
commit d74cad3b8c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -21,6 +21,7 @@ module Reports::Docx::DrawStepChecklist
text I18n.t('projects.reports.elements.step_checklist.user_time', text I18n.t('projects.reports.elements.step_checklist.user_time',
timestamp: I18n.l(timestamp, format: :full)), color: color[:gray] timestamp: I18n.l(timestamp, format: :full)), color: color[:gray]
end end
if items.any?
@docx.ul do @docx.ul do
items.each do |item| items.each do |item|
li do li do
@ -30,4 +31,5 @@ module Reports::Docx::DrawStepChecklist
end end
end end
end end
end
end end