chore: bump client api (#5217)

* chore: bump client api

* chore: fix compile

* chore: fix compile
This commit is contained in:
Nathan.fooo
2024-04-27 21:55:12 +08:00
committed by GitHub
parent d4278a7549
commit 044dad1d3e
31 changed files with 597 additions and 428 deletions

View File

@ -139,7 +139,7 @@ pub struct UserWorkspace {
pub created_at: DateTime<Utc>,
/// The database storage id is used indexing all the database views in current workspace.
#[serde(rename = "database_storage_id")]
pub workspace_database_object_id: String,
pub database_indexer_id: String,
#[serde(default)]
pub icon: String,
}
@ -150,7 +150,7 @@ impl UserWorkspace {
id: workspace_id.to_string(),
name: "".to_string(),
created_at: Utc::now(),
workspace_database_object_id: Uuid::new_v4().to_string(),
database_indexer_id: Uuid::new_v4().to_string(),
icon: "".to_string(),
}
}

View File

@ -73,7 +73,7 @@ impl<'de> Visitor<'de> for SessionVisitor {
name: "My Workspace".to_string(),
created_at: Utc::now(),
// For historical reasons, the database_storage_id is constructed by the user_id.
workspace_database_object_id: STANDARD.encode(format!("{}:user:database", user_id)),
database_indexer_id: STANDARD.encode(format!("{}:user:database", user_id)),
icon: "".to_owned(),
})
}