Skip to content

Commit

Permalink
add position feature
Browse files Browse the repository at this point in the history
  • Loading branch information
Xiaobaishushu25 committed Nov 9, 2024
1 parent 67aca4a commit 9a773c6
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions src-tauri/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -214,24 +214,24 @@ async fn init_app() {
init_http().await;
// judge_market_open().await;
}
async fn update() {
match service::curd::update_all_day_k().await {
Ok(_) => {
info!("更新日线数据成功");
NOTICE
.lock()
.unwrap()
.replace("更新日线数据成功".to_string());
}
Err(e) => {
error!("更新日线数据失败:{}", e);
NOTICE
.lock()
.unwrap()
.replace(format!("更新日线数据失败:{}", e.to_string()));
}
};
}
// async fn update() {
// match service::curd::update_all_day_k().await {
// Ok(_) => {
// info!("更新日线数据成功");
// NOTICE
// .lock()
// .unwrap()
// .replace("更新日线数据成功".to_string());
// }
// Err(e) => {
// error!("更新日线数据失败:{}", e);
// NOTICE
// .lock()
// .unwrap()
// .replace(format!("更新日线数据失败:{}", e.to_string()));
// }
// };
// }
// ///判断是否开市,先发起一个请求,然后sleep 1秒,再发起一个请求,如果两个请求的返回值不一样,则证明开市了,否则证明闭市了。
// async fn judge_market_open() {
// let response1 = REQUEST.get().unwrap().get("https://qt.gtimg.cn/q=sz159992").await.unwrap();
Expand Down

0 comments on commit 9a773c6

Please sign in to comment.