Use the full name of the node as the id in tree view.
This commit is contained in:
parent
2e2795f994
commit
e19a1341fd
|
|
@ -22,7 +22,7 @@ pub struct TreeView {
|
||||||
|
|
||||||
#[derive(Clone, Serialize, Deserialize)]
|
#[derive(Clone, Serialize, Deserialize)]
|
||||||
struct TreeViewNode {
|
struct TreeViewNode {
|
||||||
id: usize,
|
id: String,
|
||||||
status: DiagnosticStatus,
|
status: DiagnosticStatus,
|
||||||
children: Vec<TreeViewNode>,
|
children: Vec<TreeViewNode>,
|
||||||
}
|
}
|
||||||
|
|
@ -39,7 +39,7 @@ impl TreeView {
|
||||||
for child in children {
|
for child in children {
|
||||||
let status = graph.value_of(&child)?;
|
let status = graph.value_of(&child)?;
|
||||||
let node = TreeViewNode {
|
let node = TreeViewNode {
|
||||||
id: child.clone(),
|
id: graph.full_name_from_key(&child)?,
|
||||||
status: status,
|
status: status,
|
||||||
children: Self::get_nodes(&child, &graph)?,
|
children: Self::get_nodes(&child, &graph)?,
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue