feat(tags): add set_tags/list_tags commands; extend list_meetings (T8.3, FR-SEARCH-2)
This commit is contained in:
@@ -996,10 +996,44 @@ pub async fn resume_transcription(
|
||||
pub async fn list_meetings(
|
||||
state: State<'_, AppState>,
|
||||
query: Option<String>,
|
||||
tag: Option<String>,
|
||||
participant_id: Option<String>,
|
||||
from: Option<i64>,
|
||||
to: Option<i64>,
|
||||
) -> WaResult<Vec<MeetingListItem>> {
|
||||
state
|
||||
.store
|
||||
.list_meetings(query)
|
||||
.list_meetings(crate::storage::MeetingFilter {
|
||||
query,
|
||||
tag,
|
||||
participant_id,
|
||||
from,
|
||||
to,
|
||||
})
|
||||
.await
|
||||
.map_err(|e| WaError::new("storage", e.to_string()))
|
||||
}
|
||||
|
||||
/// Replaces a meeting's complete tag set (Phase 8, FR-SEARCH-2).
|
||||
#[tauri::command]
|
||||
pub async fn set_tags(
|
||||
state: State<'_, AppState>,
|
||||
meeting_id: MeetingId,
|
||||
tags: Vec<String>,
|
||||
) -> WaResult<()> {
|
||||
state
|
||||
.store
|
||||
.set_tags(&meeting_id, &tags)
|
||||
.await
|
||||
.map_err(|e| WaError::new("storage", e.to_string()))
|
||||
}
|
||||
|
||||
/// All known tag names, sorted, for filter/autocomplete UI (Phase 8, FR-SEARCH-2).
|
||||
#[tauri::command]
|
||||
pub async fn list_tags(state: State<'_, AppState>) -> WaResult<Vec<String>> {
|
||||
state
|
||||
.store
|
||||
.list_tags()
|
||||
.await
|
||||
.map_err(|e| WaError::new("storage", e.to_string()))
|
||||
}
|
||||
@@ -1726,6 +1760,7 @@ mod tests {
|
||||
notes_markdown: "**Alice:** Let's plan the sprint.".to_string(),
|
||||
summary: None,
|
||||
calendar_event_id: None,
|
||||
tags: Vec::new(),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user