diff --git a/common/proto/accounting.proto b/common/proto/accounting.proto index be33939a..4003240d 100644 --- a/common/proto/accounting.proto +++ b/common/proto/accounting.proto @@ -433,16 +433,18 @@ message OpeningBalanceAccountMapping { string created_by_user_id = 14; } -// A predecessor account still holding value that no mapping carries into the -// target period. Closing the target period drops these balances silently, so -// each one is either an account left to map or one deliberately closed out. -message UnmappedSourceAccount { +// A portion of a predecessor account's value that no mapping carries into the +// target period. Closing the target period drops this value, so each entry must +// either be covered by a broader mapping or deliberately closed out. +message UnmappedSourceBalance { int64 source_period_id = 1; string source_profile_name = 2; repeated string source_account_segments = 3; string currency = 4; - // Signed balance uses the debit-positive convention, and is never zero. - string closing_balance = 5; + // Signed portion not covered by a mapping, using the debit-positive + // convention. This is never zero and may be less than the account's + // aggregate closing balance when descendants are mapped separately. + string unmapped_balance = 5; OpeningBalanceStatus status = 6; } @@ -453,5 +455,5 @@ message ListOpeningBalanceAccountsResponse { // account path. Populated once the period carries balances by explicit // mapping only, which happens when the predecessor belongs to another // profile or when the period has at least one mapping of its own. - repeated UnmappedSourceAccount unmapped_source_accounts = 2; + repeated UnmappedSourceBalance unmapped_source_balances = 2; } diff --git a/common/src/proto/descriptor.bin b/common/src/proto/descriptor.bin index e9e23e75..0f01c031 100644 Binary files a/common/src/proto/descriptor.bin and b/common/src/proto/descriptor.bin differ diff --git a/common/src/proto/komp_ac.accounting.rs b/common/src/proto/komp_ac.accounting.rs index 65a336ea..49894310 100644 --- a/common/src/proto/komp_ac.accounting.rs +++ b/common/src/proto/komp_ac.accounting.rs @@ -476,11 +476,11 @@ pub struct OpeningBalanceAccountMapping { #[prost(string, tag = "14")] pub created_by_user_id: ::prost::alloc::string::String, } -/// A predecessor account still holding value that no mapping carries into the -/// target period. Closing the target period drops these balances silently, so -/// each one is either an account left to map or one deliberately closed out. +/// A portion of a predecessor account's value that no mapping carries into the +/// target period. Closing the target period drops this value, so each entry must +/// either be covered by a broader mapping or deliberately closed out. #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)] -pub struct UnmappedSourceAccount { +pub struct UnmappedSourceBalance { #[prost(int64, tag = "1")] pub source_period_id: i64, #[prost(string, tag = "2")] @@ -491,9 +491,11 @@ pub struct UnmappedSourceAccount { >, #[prost(string, tag = "4")] pub currency: ::prost::alloc::string::String, - /// Signed balance uses the debit-positive convention, and is never zero. + /// Signed portion not covered by a mapping, using the debit-positive + /// convention. This is never zero and may be less than the account's + /// aggregate closing balance when descendants are mapped separately. #[prost(string, tag = "5")] - pub closing_balance: ::prost::alloc::string::String, + pub unmapped_balance: ::prost::alloc::string::String, #[prost(enumeration = "OpeningBalanceStatus", tag = "6")] pub status: i32, } @@ -506,7 +508,7 @@ pub struct ListOpeningBalanceAccountsResponse { /// mapping only, which happens when the predecessor belongs to another /// profile or when the period has at least one mapping of its own. #[prost(message, repeated, tag = "2")] - pub unmapped_source_accounts: ::prost::alloc::vec::Vec, + pub unmapped_source_balances: ::prost::alloc::vec::Vec, } #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] #[repr(i32)]