knowledge: include library_id in photo_links response
The PhotoLinkDetail in /knowledge/entities/{id} was dropping the
library_id field, leaving consumers no way to construct a
content-routed thumbnail URL. Apollo's curation screen was falling
through to library=0 (the FastAPI default) and getting 400s.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -98,6 +98,7 @@ pub struct FactDetail {
|
||||
|
||||
#[derive(Serialize)]
|
||||
pub struct PhotoLinkDetail {
|
||||
pub library_id: i32,
|
||||
pub file_path: String,
|
||||
pub role: String,
|
||||
}
|
||||
@@ -105,6 +106,7 @@ pub struct PhotoLinkDetail {
|
||||
impl From<EntityPhotoLink> for PhotoLinkDetail {
|
||||
fn from(l: EntityPhotoLink) -> Self {
|
||||
PhotoLinkDetail {
|
||||
library_id: l.library_id,
|
||||
file_path: l.file_path,
|
||||
role: l.role,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user