feat: with backend
All checks were successful
continuous-integration/drone/push Build is passing

Signed-off-by: kjuulh <contact@kjuulh.io>
This commit is contained in:
2024-05-14 23:30:20 +02:00
parent 816869e6f9
commit 837caee5db
14 changed files with 1050 additions and 158 deletions

View File

@@ -7,8 +7,8 @@ use crate::{
command_parser::Commands,
commands::{
batch::BatchCommand, create_section::CreateSectionCommandExt,
toggle_item::ToggleItemCommandExt, update_graph::UpdateGraphCommandExt, Command,
IntoCommand,
open_update_item_dialog::OpenUpdateItemDialogCommandExt, toggle_item::ToggleItemCommandExt,
update_graph::UpdateGraphCommandExt, Command, IntoCommand,
},
components::movement_graph::GraphItemType,
models::{IOEvent, Msg},
@@ -272,13 +272,11 @@ impl<'a> GraphExplorer<'a> {
todo!("cannot edit section at the moment")
}
GraphItemType::Item { .. } => {
if let Some(item) = self.state.querier.get(&self.inner.root, path) {
if let GraphItem::Item { .. } = item {
return Ok(Some(
Msg::OpenEditItemDialog { item }.into_command(),
));
}
}
batch.with(
self.state
.open_update_item_dialog_command()
.command(&self.inner.root, path),
);
}
}
}