diff --git a/Cargo.lock b/Cargo.lock
index 96879f41..f7d08db4 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -3147,6 +3147,7 @@ dependencies = [
"openubl-common",
"openubl-entity",
"openubl-migration",
+ "openubl-storage",
"sea-orm",
"sea-query",
"serde",
@@ -3177,7 +3178,6 @@ name = "openubl-entity"
version = "0.1.0"
dependencies = [
"sea-orm",
- "serde",
]
[[package]]
diff --git a/openubl/api/Cargo.toml b/openubl/api/Cargo.toml
index 11fc59af..f7ad7861 100644
--- a/openubl/api/Cargo.toml
+++ b/openubl/api/Cargo.toml
@@ -9,6 +9,7 @@ edition = "2021"
openubl-entity = {path = "../entity"}
openubl-common = {path = "../common"}
openubl-migration = {path = "../migration"}
+openubl-storage = { path = "../storage" }
xsender = {path = "../../xsender"}
diff --git a/openubl/api/src/system/project.rs b/openubl/api/src/system/project.rs
index 24464323..fe7d8166 100644
--- a/openubl/api/src/system/project.rs
+++ b/openubl/api/src/system/project.rs
@@ -120,6 +120,22 @@ impl ProjectContext {
}
// Documents
+ pub async fn get_document(
+ &self,
+ id: i32,
+ tx: Transactional<'_>,
+ ) -> Result