Spaces:
Sleeping
Sleeping
| from reportlab.platypus import Paragraph | |
| from reportlab.lib.styles import getSampleStyleSheet | |
| def build_litigation_appendix(results): | |
| styles = getSampleStyleSheet() | |
| content = [] | |
| content.append(Paragraph("FOIA Litigation Appendix", styles["Title"])) | |
| for i, r in enumerate(results, 1): | |
| content.append( | |
| Paragraph( | |
| f"<b>Exhibit {i}</b><br/>" | |
| f"Agency: {r['source']}<br/>" | |
| f"Title: {r['title']}<br/>" | |
| f"FOIA Exemptions: {', '.join(r.get('exemptions', []))}<br/>" | |
| f"Citation: {r['citation']}", | |
| styles["Normal"], | |
| ) | |
| ) | |
| return content |