mirror of
https://github.com/catdevnull/preciazo.git
synced 2024-11-22 22:26:19 +00:00
solo hacer best selling una vez
This commit is contained in:
parent
e2eb3a1c3f
commit
cc0af3011a
1 changed files with 9 additions and 8 deletions
|
@ -355,14 +355,6 @@ impl Auto {
|
||||||
.await;
|
.await;
|
||||||
}
|
}
|
||||||
|
|
||||||
let best_selling = self
|
|
||||||
.inform_time(
|
|
||||||
"Downloaded best selling",
|
|
||||||
best_selling::get_all_best_selling(&self.pool),
|
|
||||||
)
|
|
||||||
.await?;
|
|
||||||
self.save_best_selling(best_selling).await?;
|
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -466,6 +458,15 @@ async fn auto_cli() -> anyhow::Result<()> {
|
||||||
.map(|s| tokio::spawn(auto.clone().download_supermercado(s.to_owned())))
|
.map(|s| tokio::spawn(auto.clone().download_supermercado(s.to_owned())))
|
||||||
.collect();
|
.collect();
|
||||||
future::try_join_all(handles).await?;
|
future::try_join_all(handles).await?;
|
||||||
|
|
||||||
|
let best_selling = auto
|
||||||
|
.inform_time(
|
||||||
|
"Downloaded best selling",
|
||||||
|
best_selling::get_all_best_selling(&auto.pool),
|
||||||
|
)
|
||||||
|
.await?;
|
||||||
|
auto.save_best_selling(best_selling).await?;
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
async fn cron_cli() -> anyhow::Result<()> {
|
async fn cron_cli() -> anyhow::Result<()> {
|
||||||
|
|
Loading…
Reference in a new issue