not working
This commit is contained in:
@@ -28,11 +28,14 @@ pub async fn run_ui() -> Result<(), Box<dyn std::error::Error>> {
|
||||
app_state.profile_tree = profile_tree;
|
||||
|
||||
// Now create admin panel with profiles from app_state
|
||||
let profiles = app_state.profile_tree.profiles
|
||||
.iter()
|
||||
.map(|p| p.name.clone())
|
||||
.collect();
|
||||
let mut admin_panel_state = AdminPanelState::new(profiles);
|
||||
if intro_state.selected_option == 1 {
|
||||
app_state.ui.show_admin = true;
|
||||
app_state.admin_profiles = app_state.profile_tree.profiles
|
||||
.iter()
|
||||
.map(|p| p.name.clone())
|
||||
.collect();
|
||||
app_state.admin_selected_item = 0;
|
||||
}
|
||||
|
||||
// Fetch table structure at startup (one-time)
|
||||
let table_structure = grpc_client.get_table_structure().await?;
|
||||
@@ -75,7 +78,6 @@ pub async fn run_ui() -> Result<(), Box<dyn std::error::Error>> {
|
||||
&event_handler.command_message,
|
||||
&app_state,
|
||||
&intro_state,
|
||||
&mut admin_panel_state,
|
||||
);
|
||||
})?;
|
||||
|
||||
@@ -94,7 +96,6 @@ pub async fn run_ui() -> Result<(), Box<dyn std::error::Error>> {
|
||||
total_count,
|
||||
&mut current_position,
|
||||
&mut intro_state,
|
||||
&mut admin_panel_state,
|
||||
).await?;
|
||||
|
||||
app_state.current_position = current_position;
|
||||
|
||||
Reference in New Issue
Block a user