separate page
This commit is contained in:
@@ -358,6 +358,24 @@ impl AddLogicFormState {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn new_with_table(
|
||||
editor_config: &EditorConfig,
|
||||
profile_name: String,
|
||||
table_id: Option<i64>,
|
||||
table_name: String,
|
||||
) -> Self {
|
||||
let mut state = AddLogicState::new(editor_config);
|
||||
state.profile_name = profile_name;
|
||||
state.selected_table_id = table_id;
|
||||
state.selected_table_name = Some(table_name);
|
||||
let editor = FormEditor::new(state.clone());
|
||||
Self {
|
||||
state,
|
||||
editor,
|
||||
focus_outside_canvas: false,
|
||||
}
|
||||
}
|
||||
|
||||
pub fn from_state(state: AddLogicState) -> Self {
|
||||
let editor = FormEditor::new(state.clone());
|
||||
Self {
|
||||
|
||||
Reference in New Issue
Block a user