completely changed system of how are tables linked together

This commit is contained in:
filipriec
2025-03-08 19:35:26 +01:00
parent 9396a08af0
commit ba672098c2
5 changed files with 108 additions and 67 deletions

View File

@@ -10,12 +10,18 @@ service TableDefinition {
rpc DeleteTable (DeleteTableRequest) returns (DeleteTableResponse);
}
message TableLink {
string linked_table_name = 1;
bool required = 2;
}
message PostTableDefinitionRequest {
string table_name = 1;
repeated ColumnDefinition columns = 2;
repeated string indexes = 3;
string profile_name = 4;
optional string linked_table_name = 5;
repeated TableLink links = 2;
repeated ColumnDefinition columns = 3;
repeated string indexes = 4;
string profile_name = 5;
optional string linked_table_name = 6;
}
message ColumnDefinition {

Binary file not shown.

View File

@@ -1,15 +1,24 @@
// This file is @generated by prost-build.
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct TableLink {
#[prost(string, tag = "1")]
pub linked_table_name: ::prost::alloc::string::String,
#[prost(bool, tag = "2")]
pub required: bool,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PostTableDefinitionRequest {
#[prost(string, tag = "1")]
pub table_name: ::prost::alloc::string::String,
#[prost(message, repeated, tag = "2")]
pub links: ::prost::alloc::vec::Vec<TableLink>,
#[prost(message, repeated, tag = "3")]
pub columns: ::prost::alloc::vec::Vec<ColumnDefinition>,
#[prost(string, repeated, tag = "3")]
#[prost(string, repeated, tag = "4")]
pub indexes: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
#[prost(string, tag = "4")]
#[prost(string, tag = "5")]
pub profile_name: ::prost::alloc::string::String,
#[prost(string, optional, tag = "5")]
#[prost(string, optional, tag = "6")]
pub linked_table_name: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, ::prost::Message)]