moving add_table to add_logic modern architecture2
This commit is contained in:
@@ -154,15 +154,14 @@ pub async fn handle_dialog_event(
|
||||
DialogPurpose::ConfirmDeleteColumns => match selected_index {
|
||||
0 => {
|
||||
// "Confirm" button selected
|
||||
if let Page::Admin(state) = &mut router.current {
|
||||
let outcome_message =
|
||||
handle_delete_selected_columns(&mut state.add_table_state);
|
||||
if let Page::AddTable(page) = &mut router.current {
|
||||
let outcome_message = handle_delete_selected_columns(&mut page.state);
|
||||
app_state.hide_dialog();
|
||||
return Some(Ok(EventOutcome::Ok(outcome_message)));
|
||||
}
|
||||
return Some(Ok(EventOutcome::Ok(
|
||||
"Admin state not active".to_string(),
|
||||
)));
|
||||
"AddTable page not active".to_string(),
|
||||
)));
|
||||
}
|
||||
1 => {
|
||||
// "Cancel" button selected
|
||||
|
||||
Reference in New Issue
Block a user