pub struct AccountingPeriodUpdate {
pub client_id: i64,
pub end_date: NaiveDate,
pub increment_document_number: bool,
pub is_closed: bool,
pub start_date: NaiveDate,
pub balances: Option<AccountingPeriodBalanceTransfer>,
pub set_immutability: Option<bool>,
pub extra: Map<String, Value>,
}Expand description
Replacement period settings. All AccountingPeriodBase fields are required. Optional balance transfer and transaction immutability are applied after saving the period.
Fields§
§client_id: i64Finance client owning this period.
end_date: NaiveDateLast date of the period.
increment_document_number: boolWhether document numbers are incremented automatically. Required in both creation and update.
is_closed: boolWhether the period is closed for ordinary accounting changes. This flag alone does not make transactions immutable.
start_date: NaiveDateFirst date of the period. Used to match the previous period by subtracting exactly one year.
balances: Option<AccountingPeriodBalanceTransfer>Optional opening-balance transfer. Both an openingBalanceAccount and a nonempty from list are needed to start a transfer. The previous period must have the same client and a start date exactly one year earlier.
set_immutability: Option<bool>When isClosed=true, make currently mutable transactions in the period immutable. Ignored when isClosed=false. Reopening the period does not undo transaction immutability.
extra: Map<String, Value>Fields not described by the spec, e.g. instance-specific DB fields.