mirror of
https://github.com/outbackdingo/optimclaw.git
synced 2026-09-02 17:49:20 +00:00
fix: web UI routines tab shows all routines regardless of creating channel (#391)
Routines created via Telegram (or any WASM channel) were invisible in the web UI because the routines list endpoint filtered by GATEWAY_USER_ID, which didn't match the Telegram user's ID stored on the routine. Add list_all_routines() to the RoutineStore trait (both libSQL and PostgreSQL backends) and use it in the web dashboard handlers so all routines are visible regardless of which channel created them. Co-authored-by: Claude Opus 4.6 (1M context) <[email protected]>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
ddd01a628c
commit
a65b282066
@@ -23,7 +23,7 @@ pub async fn routines_list_handler(
|
||||
))?;
|
||||
|
||||
let routines = store
|
||||
.list_routines(&state.user_id)
|
||||
.list_all_routines()
|
||||
.await
|
||||
.map_err(|e| (StatusCode::INTERNAL_SERVER_ERROR, e.to_string()))?;
|
||||
|
||||
@@ -41,7 +41,7 @@ pub async fn routines_summary_handler(
|
||||
))?;
|
||||
|
||||
let routines = store
|
||||
.list_routines(&state.user_id)
|
||||
.list_all_routines()
|
||||
.await
|
||||
.map_err(|e| (StatusCode::INTERNAL_SERVER_ERROR, e.to_string()))?;
|
||||
|
||||
|
||||
@@ -2146,7 +2146,7 @@ async fn routines_list_handler(
|
||||
))?;
|
||||
|
||||
let routines = store
|
||||
.list_routines(&state.user_id)
|
||||
.list_all_routines()
|
||||
.await
|
||||
.map_err(|e| (StatusCode::INTERNAL_SERVER_ERROR, e.to_string()))?;
|
||||
|
||||
@@ -2164,7 +2164,7 @@ async fn routines_summary_handler(
|
||||
))?;
|
||||
|
||||
let routines = store
|
||||
.list_routines(&state.user_id)
|
||||
.list_all_routines()
|
||||
.await
|
||||
.map_err(|e| (StatusCode::INTERNAL_SERVER_ERROR, e.to_string()))?;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user