pub struct TransactionPurposeUpdate {
pub account_ids: Vec<i64>,
pub cost_center_id: Option<Option<i64>>,
pub is_income: bool,
pub name: String,
pub purpose_account_id: i64,
pub sort_key: i64,
pub extra: Map<String, Value>,
}Expand description
Replacement preset, including the complete accountIds selection. Omitted costCenterId clears the linked cost center.
Fields§
§account_ids: Vec<i64>Accounts offered for the other side of the posting. Duplicate IDs are collapsed; unknown IDs are currently omitted by the lookup. Supply existing accounts.
cost_center_id: Option<Option<i64>>Optional cost center. Omitted or null removes it, including on update. If supplied, its period must match the fixed account and all resolved accountIds.
None leaves the field out, Some(None) sends null.
is_income: boolTrue for income presets, false for expense presets. Determines which side of a transaction uses purposeAccountId.
name: StringTrimmed display name. Names are not required to be unique.
purpose_account_id: i64Fixed ledger account: the contra account for income, or the account for expenses. Its period must be open.
sort_key: i64Ascending display order. Required in creation and update.
extra: Map<String, Value>Fields not described by the spec, e.g. instance-specific DB fields.