ecb conversions with corrections2

This commit is contained in:
Priec
2026-08-13 11:41:28 +02:00
parent 8f8b5b4601
commit 774c9a3ce0
9 changed files with 569 additions and 112 deletions

View File

@@ -3,6 +3,7 @@ syntax = "proto3";
package komp_ac.tables_data;
import "common.proto";
import "ecb.proto";
import "google/protobuf/struct.proto";
// Read and write row data for user-defined tables inside profiles (schemas).
@@ -23,6 +24,11 @@ service TablesData {
// - If the physical table is missing but the definition exists, returns INTERNAL
rpc PostTableData(PostTableDataRequest) returns (PostTableDataResponse);
// Insert an ACCOUNTING-enabled source row with an explicit exchange-rate
// treatment for the journal line created from it.
rpc PostAccountingTableData(PostAccountingTableDataRequest)
returns (PostTableDataResponse);
// Insert multiple rows by applying PostTableData behavior to each row.
//
// Behavior:
@@ -46,6 +52,8 @@ service TablesData {
// - Binds values with correct SQL types; rejects invalid formats/ranges
// - Updates the row and returns the id; queues search indexing (best effort)
rpc PutTableData(PutTableDataRequest) returns (PutTableDataResponse);
rpc PutAccountingTableData(PutAccountingTableDataRequest)
returns (PutTableDataResponse);
// Performs a PUT after the user explicitly accepted changing a referenced version.
rpc PutTableDataConfirmed(PutTableDataConfirmedRequest) returns (PutTableDataResponse);
@@ -139,6 +147,11 @@ message PostTableDataRequest {
map<string, google.protobuf.Value> data = 3;
}
message PostAccountingTableDataRequest {
PostTableDataRequest row = 1;
komp_ac.ecb.ExchangeRateSelection exchange_rate_selection = 2;
}
// Insert response.
message PostTableDataResponse {
// True if the insert succeeded.
@@ -210,6 +223,14 @@ message PutTableDataRequest {
// Required. Revision returned when this row was loaded or last saved.
int64 expected_revision = 5;
}
message PutAccountingTableDataRequest {
PutTableDataRequest update = 1;
komp_ac.ecb.ExchangeRateSelection exchange_rate_selection = 2;
bool confirmed = 3;
repeated string expected_affected_profiles = 4;
}
message PutTableDataConfirmedRequest {