Implementing auto refresh
This commit is contained in:
parent
4f9ced3e29
commit
2819df185e
7 changed files with 27 additions and 23 deletions
|
|
@ -28,6 +28,7 @@ pub struct DashboardViewState {
|
|||
pub monitors: Vec<MonitorViewState>,
|
||||
pub is_loading: bool,
|
||||
pub error_message: Option<String>,
|
||||
pub auto_refresh_interval: u32,
|
||||
}
|
||||
|
||||
impl DashboardViewState {
|
||||
|
|
@ -38,6 +39,7 @@ impl DashboardViewState {
|
|||
monitors: Vec::new(),
|
||||
is_loading: true,
|
||||
error_message: None,
|
||||
auto_refresh_interval: 300,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -91,6 +93,7 @@ impl DashboardViewState {
|
|||
monitors,
|
||||
is_loading: false,
|
||||
error_message: None,
|
||||
auto_refresh_interval: data.audo_refresh_interval,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue