conversion stuff is now handled by the module
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
syntax = "proto3";
|
syntax = "proto3";
|
||||||
package komp_ac.accounting;
|
package komp_ac.accounting;
|
||||||
|
|
||||||
import "exchange_rates.proto";
|
import "common.proto";
|
||||||
|
|
||||||
// Mutable informational journals. A journal may contain only debits, only
|
// Mutable informational journals. A journal may contain only debits, only
|
||||||
// credits, or any non-zero balance. Balance is reported but never enforced.
|
// credits, or any non-zero balance. Balance is reported but never enforced.
|
||||||
@@ -170,9 +170,9 @@ message JournalLineInput {
|
|||||||
string account = 2;
|
string account = 2;
|
||||||
string amount = 3;
|
string amount = 3;
|
||||||
string description = 4;
|
string description = 4;
|
||||||
// Empty uses the profile provider's previous publication. Set this per line when the
|
// Omit to use the selected conversion module's posting policy.
|
||||||
// accountant needs a different rule, a saved custom rate, or a one-off rate.
|
// Explicit options are interpreted only by their named module.
|
||||||
optional komp_ac.exchange_rates.ExchangeRateSelection exchange_rate_selection = 5;
|
optional komp_ac.common.CurrencyConversionOptions conversion_options = 5;
|
||||||
}
|
}
|
||||||
|
|
||||||
message CloseJournalRequest {
|
message CloseJournalRequest {
|
||||||
@@ -325,6 +325,7 @@ message JournalLine {
|
|||||||
string original_amount = 16;
|
string original_amount = 16;
|
||||||
string original_currency = 17;
|
string original_currency = 17;
|
||||||
int64 conversion_evidence_id = 18;
|
int64 conversion_evidence_id = 18;
|
||||||
|
int64 conversion_table_definition_id = 19;
|
||||||
}
|
}
|
||||||
|
|
||||||
message Journal {
|
message Journal {
|
||||||
|
|||||||
@@ -9,3 +9,9 @@ message CountResponse {
|
|||||||
message PositionRequest {
|
message PositionRequest {
|
||||||
int64 position = 1;
|
int64 position = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Options interpreted only by the named currency-conversion module.
|
||||||
|
message CurrencyConversionOptions {
|
||||||
|
string module_id = 1;
|
||||||
|
string options_json = 2;
|
||||||
|
}
|
||||||
|
|||||||
@@ -3,7 +3,6 @@ syntax = "proto3";
|
|||||||
package komp_ac.tables_data;
|
package komp_ac.tables_data;
|
||||||
|
|
||||||
import "common.proto";
|
import "common.proto";
|
||||||
import "exchange_rates.proto";
|
|
||||||
import "google/protobuf/struct.proto";
|
import "google/protobuf/struct.proto";
|
||||||
|
|
||||||
// Read and write row data for user-defined tables inside profiles (schemas).
|
// Read and write row data for user-defined tables inside profiles (schemas).
|
||||||
@@ -166,7 +165,7 @@ map<string, google.protobuf.Value> data = 3;
|
|||||||
|
|
||||||
message PostAccountingTableDataRequest {
|
message PostAccountingTableDataRequest {
|
||||||
PostTableDataRequest row = 1;
|
PostTableDataRequest row = 1;
|
||||||
komp_ac.exchange_rates.ExchangeRateSelection exchange_rate_selection = 2;
|
komp_ac.common.CurrencyConversionOptions conversion_options = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Insert response.
|
// Insert response.
|
||||||
@@ -272,7 +271,7 @@ message PutTableDataRequest {
|
|||||||
|
|
||||||
message PutAccountingTableDataRequest {
|
message PutAccountingTableDataRequest {
|
||||||
PutTableDataRequest update = 1;
|
PutTableDataRequest update = 1;
|
||||||
komp_ac.exchange_rates.ExchangeRateSelection exchange_rate_selection = 2;
|
komp_ac.common.CurrencyConversionOptions conversion_options = 2;
|
||||||
bool confirmed = 3;
|
bool confirmed = 3;
|
||||||
repeated string expected_affected_profiles = 4;
|
repeated string expected_affected_profiles = 4;
|
||||||
}
|
}
|
||||||
|
|||||||
Binary file not shown.
@@ -72,11 +72,11 @@ pub struct JournalLineInput {
|
|||||||
pub amount: ::prost::alloc::string::String,
|
pub amount: ::prost::alloc::string::String,
|
||||||
#[prost(string, tag = "4")]
|
#[prost(string, tag = "4")]
|
||||||
pub description: ::prost::alloc::string::String,
|
pub description: ::prost::alloc::string::String,
|
||||||
/// Empty uses the profile provider's previous publication. Set this per line when the
|
/// Omit to use the selected conversion module's posting policy.
|
||||||
/// accountant needs a different rule, a saved custom rate, or a one-off rate.
|
/// Explicit options are interpreted only by their named module.
|
||||||
#[prost(message, optional, tag = "5")]
|
#[prost(message, optional, tag = "5")]
|
||||||
pub exchange_rate_selection: ::core::option::Option<
|
pub conversion_options: ::core::option::Option<
|
||||||
super::exchange_rates::ExchangeRateSelection,
|
super::common::CurrencyConversionOptions,
|
||||||
>,
|
>,
|
||||||
}
|
}
|
||||||
#[derive(serde::Serialize, serde::Deserialize)]
|
#[derive(serde::Serialize, serde::Deserialize)]
|
||||||
@@ -314,6 +314,8 @@ pub struct JournalLine {
|
|||||||
pub original_currency: ::prost::alloc::string::String,
|
pub original_currency: ::prost::alloc::string::String,
|
||||||
#[prost(int64, tag = "18")]
|
#[prost(int64, tag = "18")]
|
||||||
pub conversion_evidence_id: i64,
|
pub conversion_evidence_id: i64,
|
||||||
|
#[prost(int64, tag = "19")]
|
||||||
|
pub conversion_table_definition_id: i64,
|
||||||
}
|
}
|
||||||
#[derive(serde::Serialize, serde::Deserialize)]
|
#[derive(serde::Serialize, serde::Deserialize)]
|
||||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
|||||||
@@ -14,3 +14,12 @@ pub struct PositionRequest {
|
|||||||
#[prost(int64, tag = "1")]
|
#[prost(int64, tag = "1")]
|
||||||
pub position: i64,
|
pub position: i64,
|
||||||
}
|
}
|
||||||
|
/// Options interpreted only by the named currency-conversion module.
|
||||||
|
#[derive(serde::Serialize, serde::Deserialize)]
|
||||||
|
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
|
||||||
|
pub struct CurrencyConversionOptions {
|
||||||
|
#[prost(string, tag = "1")]
|
||||||
|
pub module_id: ::prost::alloc::string::String,
|
||||||
|
#[prost(string, tag = "2")]
|
||||||
|
pub options_json: ::prost::alloc::string::String,
|
||||||
|
}
|
||||||
|
|||||||
@@ -54,8 +54,8 @@ pub struct PostAccountingTableDataRequest {
|
|||||||
#[prost(message, optional, tag = "1")]
|
#[prost(message, optional, tag = "1")]
|
||||||
pub row: ::core::option::Option<PostTableDataRequest>,
|
pub row: ::core::option::Option<PostTableDataRequest>,
|
||||||
#[prost(message, optional, tag = "2")]
|
#[prost(message, optional, tag = "2")]
|
||||||
pub exchange_rate_selection: ::core::option::Option<
|
pub conversion_options: ::core::option::Option<
|
||||||
super::exchange_rates::ExchangeRateSelection,
|
super::common::CurrencyConversionOptions,
|
||||||
>,
|
>,
|
||||||
}
|
}
|
||||||
/// Insert response.
|
/// Insert response.
|
||||||
@@ -187,8 +187,8 @@ pub struct PutAccountingTableDataRequest {
|
|||||||
#[prost(message, optional, tag = "1")]
|
#[prost(message, optional, tag = "1")]
|
||||||
pub update: ::core::option::Option<PutTableDataRequest>,
|
pub update: ::core::option::Option<PutTableDataRequest>,
|
||||||
#[prost(message, optional, tag = "2")]
|
#[prost(message, optional, tag = "2")]
|
||||||
pub exchange_rate_selection: ::core::option::Option<
|
pub conversion_options: ::core::option::Option<
|
||||||
super::exchange_rates::ExchangeRateSelection,
|
super::common::CurrencyConversionOptions,
|
||||||
>,
|
>,
|
||||||
#[prost(bool, tag = "3")]
|
#[prost(bool, tag = "3")]
|
||||||
pub confirmed: bool,
|
pub confirmed: bool,
|
||||||
|
|||||||
2
server
2
server
Submodule server updated: 1da33d6562...f00542d009
Reference in New Issue
Block a user