Skip to main content

next_contract_number

Function next_contract_number 

Source
pub fn next_contract_number(
    conn: &Connection,
    issuer: &Issuer,
    year: i32,
    kind: &str,
) -> Result<String>
Expand description

Generate the next contract number for an issuer/year/kind triple. Uses the shared number_series table with kind = "contract.<kind>" so contract sequences live separately from invoice/credit-note sequences.