Files
wanderbooks/crates/ledger-import/src/lib.rs
T
swaitsandMuse Wonder 1.0 a414462be7 refactor(display): one rounding for presentation
Move format_amount's rounding half (half away from zero, never a negative zero) into ledger-import::format::round_display, through the kernel's round_places. format_amount, amount_parts, the PDF percent column, xlsx's exact_f64 and ledger-package's text padding all call it, so a display change never changes a booked figure.

Co-Authored-By: Muse Wonder 1.0
2026-11-09 18:54:17 -07:00

51 lines
2.0 KiB
Rust

//! QuickBooks-compatible import/export for wanderbooks.
//!
//! - [`bank_csv`]: parse QBO bank/credit-card upload CSVs.
//! - [`chart_csv`]: parse chart-of-accounts CSVs.
//! - [`iif`]: generate IIF journal entries for QuickBooks Desktop.
//! - [`report`]: the statement layout every renderer draws from.
//! - [`xlsx`]: generate XLSX reports.
//! - [`pdf`]: generate PDF financial statements (CPA handoff).
//! - [`asset_register`]: the fixed asset register as XLSX and PDF.
//! - [`labels`]: print asset label sheets with QR codes.
//! - [`invoice_pdf`](mod@invoice_pdf): an invoice as PDF.
//! - [`fonts`]: the bundled fonts the PDFs and the viewer share.
//!
//! All money stays `Decimal`; no floats in money paths.
pub mod asset_register;
pub mod bank_csv;
pub mod chart_csv;
/// The one reader, now the `ledger-reader` crate (D-61), kept at its old path.
pub use ledger_reader as extract;
pub mod fonts;
pub mod format;
pub mod iif;
pub mod invoice_pdf;
pub mod labels;
pub mod pdf;
pub mod report;
pub mod templates;
pub mod workpaper;
pub mod xlsx;
pub use asset_register::{asset_register_pdf, asset_register_xlsx};
pub use bank_csv::{BankCsvError, BankTransaction, DateOrder, parse_bank_csv, parse_bank_csv_with};
pub use chart_csv::{ChartRow, parse_chart_csv};
pub use extract::{ExtractError, page_count, page_png, pdf_lines, pdf_text, text_of, xlsx_text};
pub use format::round_display;
pub use iif::{
Iif, IifAccount, IifChange, IifClass, IifError, IifField, LeftOut, MEMO_MAX, NAME_MAX,
NUMBER_MAX, QbAccountType, iif_accounts, iif_classes, journal_to_iif,
};
pub use invoice_pdf::{
InvoiceDoc, InvoiceItem, InvoiceParty, InvoiceStamp, InvoiceVersion, PaymentMethodDoc,
invoice_pdf,
};
pub use labels::{AssetLabel, LabelSheet, asset_labels_pdf};
pub use pdf::{PdfError, statement_pdf};
pub use report::{Member, ReportMeta, Row, RowKind, Statement, YearEarnings, format_amount};
pub use templates::{ChartTemplate, EntityType, chart_template};
pub use workpaper::{Workpaper, WorkpaperCheck, WorkpaperFinding, workpaper_pdf};
pub use xlsx::{XlsxReport, report_to_xlsx};