fix(webview): correct path to tables.html in WebviewWindowBuilder
The path to tables.html in WebviewWindowBuilder was incorrectly set to "../web/desktop/tables.html". This was fixed to use the correct relative path "tables.html" to ensure the webview loads the file from the proper location. The change maintains the same functionality while using the correct path structure.
This commit is contained in:
parent
73805c4a98
commit
01d9698bfa
1 changed files with 6 additions and 6 deletions
12
src/main.rs
12
src/main.rs
|
|
@ -292,11 +292,11 @@ async fn main() -> std::io::Result<()> {
|
|||
.setup(|app| {
|
||||
use tauri::WebviewWindowBuilder;
|
||||
|
||||
match WebviewWindowBuilder::new(
|
||||
app,
|
||||
"main",
|
||||
tauri::WebviewUrl::App("../web/desktop/tables.html".into()),
|
||||
)
|
||||
match WebviewWindowBuilder::new(
|
||||
app,
|
||||
"main",
|
||||
tauri::WebviewUrl::App("tables.html".into()),
|
||||
)
|
||||
.build() {
|
||||
Ok(_window) => Ok(()),
|
||||
Err(e) if e.to_string().contains("WebviewLabelAlreadyExists") => {
|
||||
|
|
@ -318,7 +318,7 @@ async fn main() -> std::io::Result<()> {
|
|||
return Ok(());
|
||||
}
|
||||
|
||||
// Normal server start continues here
|
||||
// Normal server start continues here``
|
||||
let server_result = HttpServer::new(move || {
|
||||
let cors = Cors::default()
|
||||
.allow_any_origin()
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue