This commit is contained in:
fengchuanhn@gmail.com
2026-05-21 01:47:16 +08:00
parent 3b0a8d777c
commit 54f080fbc1
22 changed files with 1106 additions and 36 deletions

View File

@@ -17,6 +17,8 @@ pub mod ffmpeg;
pub mod http;
pub mod js_runtime;
pub mod nodejs;
pub mod oem_context;
pub mod oem_id;
pub mod oss;
pub mod publish_db;
pub mod publish_store;
@@ -36,6 +38,13 @@ pub fn run() {
.manage(publish_store::PublishStore::new())
.setup(|app| {
let handle = app.handle().clone();
let oem_id = handle
.path()
.app_data_dir()
.map(|dir| oem_id::read_oem_id_file(&dir.join(oem_id::OEM_FILE_NAME)))
.unwrap_or(oem_id::DEFAULT_OEM_ID);
app.manage(oem_context::OemContext { oem_id });
tauri::async_runtime::block_on(async move {
let app_config = handle.state::<app_config::AppConfig>();
let avatar_store = handle.state::<avatar_store::AvatarStore>();
@@ -68,6 +77,7 @@ pub fn run() {
.plugin(tauri_plugin_dialog::init())
.invoke_handler(tauri::generate_handler![
commands::api::api_request,
commands::software_info::get_software_info,
commands::auth::sync_auth_session,
commands::app_config::get_app_config,
commands::app_config::get_app_config_last_message,