init with react+axum+spacetimedb
Some checks failed
CI / verify (push) Has been cancelled

This commit is contained in:
2026-04-26 18:06:23 +08:00
commit cbc27bad4a
20199 changed files with 883714 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
use super::*;
impl SpacetimeClient {
pub async fn get_runtime_inventory_state(
&self,
runtime_session_id: String,
actor_user_id: String,
) -> Result<RuntimeInventoryStateRecord, SpacetimeClientError> {
let procedure_input =
build_runtime_inventory_state_query_input(runtime_session_id, actor_user_id)
.map_err(|error| SpacetimeClientError::Runtime(error.to_string()))?
.into();
self.call_after_connect(move |connection, sender| {
connection.procedures().get_runtime_inventory_state_then(
procedure_input,
move |_, result| {
let mapped = result
.map_err(|error| SpacetimeClientError::Procedure(error.to_string()))
.and_then(map_runtime_inventory_state_procedure_result);
send_once(&sender, mapped);
},
);
})
.await
}
}