From 89af49af614c7ee67c928f046bed34aa8ab2c0b6 Mon Sep 17 00:00:00 2001 From: Takayuki Maeda Date: Sat, 9 Oct 2021 13:49:53 +0900 Subject: [PATCH] update record_table --- src/app.rs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/app.rs b/src/app.rs index 1a5ed63..7fcc0e1 100644 --- a/src/app.rs +++ b/src/app.rs @@ -224,6 +224,15 @@ impl App { if key == self.config.key_config.enter && self.databases.tree_focused() { if let Some((database, table)) = self.databases.tree().selected_table() { + self.record_table.reset(); + let (headers, records) = self + .pool + .as_ref() + .unwrap() + .get_records(&database, &table, 0, None) + .await?; + self.record_table + .update(records, headers, database.clone(), table.clone()); self.properties .update(database.clone(), table.clone(), self.pool.as_ref().unwrap()) .await?;