277 |
277 |
pdf.alias_nb_pages
|
278 |
278 |
pdf.footer_date = format_date(Date.today)
|
279 |
279 |
pdf.AddPage
|
|
280 |
|
|
281 |
i = 0
|
|
282 |
pdf.SetFontStyle('',9)
|
|
283 |
issue.ancestors.each do |ancestor|
|
|
284 |
if i == 0
|
|
285 |
pdf.RDMMultiCell(190,5,(i>=1?" " * i + ">":"") + "#{ancestor.project} - #{ancestor.tracker} # #{ancestor.id}: #{ancestor.subject} (#{ancestor.status.to_s})", "0", 1 )
|
|
286 |
else
|
|
287 |
pdf.RDMMultiCell(190,5,(i>=1?" " * i + ">":"") + "#{ancestor.project} - #{ancestor.tracker} # #{ancestor.id}: #{ancestor.subject} (#{ancestor.status.to_s})", "0", 1 )
|
|
288 |
end
|
|
289 |
i += 1
|
|
290 |
end
|
|
291 |
|
280 |
292 |
pdf.SetFontStyle('B',11)
|
281 |
|
pdf.RDMMultiCell(190,5,
|
|
293 |
pdf.RDMMultiCell(190,5, (i>=1?" " * (i+1) + ">":"") +
|
282 |
294 |
"#{issue.project} - #{issue.tracker} # #{issue.id}: #{issue.subject}")
|
283 |
295 |
pdf.Ln
|
284 |
296 |
|
... | ... | |
341 |
353 |
pdf.RDMCell(35+155, 5, l(:field_description), "LRT", 1)
|
342 |
354 |
pdf.SetFontStyle('',9)
|
343 |
355 |
pdf.RDMMultiCell(35+155, 5, issue.description.to_s, "LRB")
|
|
356 |
|
|
357 |
i = 0
|
|
358 |
issue_list(issue.descendants.sort_by(&:lft)) do |child, level|
|
|
359 |
if i == 0
|
|
360 |
pdf.SetFontStyle('B',9)
|
|
361 |
pdf.RDMCell(35,5, l(:label_subtask_plural) + ":", "LT")
|
|
362 |
pdf.SetFontStyle('', 9)
|
|
363 |
pdf.RDMCell(125,5,(level>=1?" " * level + ">":"") + "#{child.project} - #{child.tracker} # #{child.id}: #{child.subject}".first(80)+"...", "T")
|
|
364 |
pdf.SetFontStyle('B',9)
|
|
365 |
pdf.RDMCell(30,5, "#{child.status.to_s}", "RT",0,"L")
|
|
366 |
pdf.Ln
|
|
367 |
else
|
|
368 |
pdf.SetFontStyle('B',9)
|
|
369 |
pdf.RDMCell(35,5, "", "L")
|
|
370 |
pdf.SetFontStyle('', 9)
|
|
371 |
pdf.RDMCell(125,5,(level>=1?" " * level + ">":"") + "#{child.project} - #{child.tracker} # #{child.id}: #{child.subject}".first(80)+"...", "0")
|
|
372 |
pdf.SetFontStyle('B',9)
|
|
373 |
pdf.RDMCell(30,5, "#{child.status.to_s}", "R",0,"L")
|
|
374 |
pdf.Ln
|
|
375 |
end
|
|
376 |
i += 1
|
|
377 |
end
|
|
378 |
|
|
379 |
j = 0
|
|
380 |
issue.relations.select { |r| r.other_issue(issue).visible? }.each do |relation|
|
|
381 |
if j == 0
|
|
382 |
pdf.SetFontStyle('B',9)
|
|
383 |
pdf.RDMCell(35,5, l(relation.label_for(issue)) + ":", "LT")
|
|
384 |
pdf.SetFontStyle('', 9)
|
|
385 |
pdf.RDMCell(125,5, "#{relation.other_issue(issue).project} - #{relation.other_issue(issue).tracker} # #{relation.other_issue(issue).id}: #{relation.other_issue(issue).subject}".first(80) + "...", "T")
|
|
386 |
pdf.SetFontStyle('B',9)
|
|
387 |
pdf.RDMCell(30,5, "#{relation.other_issue(issue).status.to_s}", "RT",0,"L")
|
|
388 |
pdf.Ln
|
|
389 |
else
|
|
390 |
pdf.SetFontStyle('B',9)
|
|
391 |
pdf.RDMCell(35,5, l(relation.label_for(issue)) + ":", "L")
|
|
392 |
pdf.SetFontStyle('', 9)
|
|
393 |
pdf.RDMCell(125,5, "#{relation.other_issue(issue).project} - #{relation.other_issue(issue).tracker} # #{relation.other_issue(issue).id}: #{relation.other_issue(issue).subject}".first(80) + "...", "0")
|
|
394 |
pdf.SetFontStyle('B',9)
|
|
395 |
pdf.RDMCell(30,5, "#{relation.other_issue(issue).status.to_s}", "R",0,"L")
|
|
396 |
pdf.Ln
|
|
397 |
end
|
|
398 |
j += 1
|
|
399 |
end
|
|
400 |
|
|
401 |
pdf.RDMCell(190,5, "", "T",0)
|
344 |
402 |
pdf.Ln
|
345 |
403 |
|
346 |
404 |
if issue.changesets.any? &&
|