feat: Implement summary field for database row (#5246)

* chore: impl summary field

* chore: draft ui

* chore: add summary event

* chore: impl desktop ui

* chore: impl mobile ui

* chore: update test

* chore: disable ai test
This commit is contained in:
Nathan.fooo
2024-05-05 22:04:34 +08:00
committed by GitHub
parent 999ffeba21
commit a69e83c2cb
83 changed files with 1802 additions and 628 deletions

View File

@ -55,7 +55,7 @@ impl UserWorkspaceService for UserWorkspaceServiceImpl {
) -> FlowyResult<()> {
self
.database_manager
.track_database(ids_by_database_id)
.update_database_indexing(ids_by_database_id)
.await?;
Ok(())
}

View File

@ -14,7 +14,9 @@ use tracing::debug;
use collab_integrate::collab_builder::{
CollabCloudPluginProvider, CollabPluginProviderContext, CollabPluginProviderType,
};
use flowy_database_pub::cloud::{CollabDocStateByOid, DatabaseCloudService, DatabaseSnapshot};
use flowy_database_pub::cloud::{
CollabDocStateByOid, DatabaseCloudService, DatabaseSnapshot, SummaryRowContent,
};
use flowy_document::deps::DocumentData;
use flowy_document_pub::cloud::{DocumentCloudService, DocumentSnapshot};
use flowy_error::FlowyError;
@ -267,6 +269,23 @@ impl DatabaseCloudService for ServerProvider {
.await
})
}
fn summary_database_row(
&self,
workspace_id: &str,
object_id: &str,
summary_row: SummaryRowContent,
) -> FutureResult<String, Error> {
let workspace_id = workspace_id.to_string();
let server = self.get_server();
let object_id = object_id.to_string();
FutureResult::new(async move {
server?
.database_service()
.summary_database_row(&workspace_id, &object_id, summary_row)
.await
})
}
}
impl DocumentCloudService for ServerProvider {