diff --git a/client b/client index 99a464fe..bbf636fb 160000 --- a/client +++ b/client @@ -1 +1 @@ -Subproject commit 99a464febbb7e333b4dba7f865199dedc4d2510b +Subproject commit bbf636fbeff1fe929f3dfdeef986c50fa1a52cd5 diff --git a/client-gui2 b/client-gui2 index 9839994e..ae472514 160000 --- a/client-gui2 +++ b/client-gui2 @@ -1 +1 @@ -Subproject commit 9839994ea55eb2b441b196eeb62cf15623de18ff +Subproject commit ae4725144becf6920f4a03b976125ede2aa4863f diff --git a/common/proto/table_definition.proto b/common/proto/table_definition.proto index 3755d503..3a03f9ec 100644 --- a/common/proto/table_definition.proto +++ b/common/proto/table_definition.proto @@ -542,8 +542,8 @@ message ColumnBehavior { // This is not an authorization boundary; data APIs still expose the column. bool hidden_from_forms = 6; - // Current public aliases for stable option values. Identity aliases equal the - // canonical value. Once renamed, public writes must use the current alias. + // Current public option names. For a renamed option, both fields contain its + // alias; the stored value is never disclosed. Public writes use the alias. repeated OptionValueAlias option_value_aliases = 7; } @@ -581,7 +581,8 @@ message SetColumnPresentationResponse { int64 row_version = 4; } -// One stable machine value and its optional user-visible/input alias. +// One public option name. `value` identifies the option by its current public +// alias and `alias` is its desired public alias; stored values remain internal. message OptionValueAlias { string value = 1; string alias = 2; diff --git a/common/src/proto/descriptor.bin b/common/src/proto/descriptor.bin index ff1141c9..83f911b8 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.table_definition.rs b/common/src/proto/komp_ac.table_definition.rs index 587bda7d..8df59103 100644 --- a/common/src/proto/komp_ac.table_definition.rs +++ b/common/src/proto/komp_ac.table_definition.rs @@ -563,8 +563,8 @@ pub struct ColumnBehavior { /// This is not an authorization boundary; data APIs still expose the column. #[prost(bool, tag = "6")] pub hidden_from_forms: bool, - /// Current public aliases for stable option values. Identity aliases equal the - /// canonical value. Once renamed, public writes must use the current alias. + /// Current public option names. For a renamed option, both fields contain its + /// alias; the stored value is never disclosed. Public writes use the alias. #[prost(message, repeated, tag = "7")] pub option_value_aliases: ::prost::alloc::vec::Vec, } @@ -621,7 +621,8 @@ pub struct SetColumnPresentationResponse { #[prost(int64, tag = "4")] pub row_version: i64, } -/// One stable machine value and its optional user-visible/input alias. +/// One public option name. `value` identifies the option by its current public +/// alias and `alias` is its desired public alias; stored values remain internal. #[derive(serde::Serialize, serde::Deserialize)] #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)] pub struct OptionValueAlias { diff --git a/komp-app/src/grpc.rs b/komp-app/src/grpc.rs index 6e96be03..8e0f1d49 100644 --- a/komp-app/src/grpc.rs +++ b/komp-app/src/grpc.rs @@ -37,6 +37,7 @@ use common::proto::komp_ac::table_definition::{ GetTableCatalogResponse, ListColumnTypesResponse, PostTableDefinitionRequest, ProfileTreeResponse, PutTableDefinitionRequest, PutTableDefinitionResponse, SetColumnFormVisibilityRequest, SetColumnFormVisibilityResponse, + SetColumnOptionAliasesRequest, SetColumnOptionAliasesResponse, SetColumnPresentationRequest, SetColumnPresentationResponse, TableDefinitionResponse, table_definition_client::TableDefinitionClient, }; @@ -567,6 +568,19 @@ impl GrpcClient { Ok(response.into_inner()) } + pub async fn set_column_option_aliases( + &mut self, + request: SetColumnOptionAliasesRequest, + ) -> Result { + let tonic_request = self.authenticated_request(request)?; + let response = self + .table_definition_client + .set_column_option_aliases(tonic_request) + .await + .context("gRPC SetColumnOptionAliases call failed")?; + Ok(response.into_inner()) + } + pub async fn set_column_form_visibility( &mut self, request: SetColumnFormVisibilityRequest, diff --git a/server b/server index 0c5ecac6..83300228 160000 --- a/server +++ b/server @@ -1 +1 @@ -Subproject commit 0c5ecac63df242c8d31359a506c0bec7f01017e9 +Subproject commit 83300228fd4c51fc90445fa486344965bf7dc527