feat: migrate the printing from Attachment to Document model

This commit is contained in:
Ahmed Bouhuolia
2024-05-31 15:32:51 +02:00
parent 958f78e7a4
commit 08ad117331
2 changed files with 18 additions and 13 deletions

View File

@@ -5,4 +5,10 @@ export const PDF_FILE_EXPIRE_IN = 40; // ms
export const getPdfFilesStorageDir = (filename: string) => {
return path.join(PDF_FILE_SUB_DIR, filename);
}
};
export const getPdfFilePath = (filename: string) => {
const storageDir = getPdfFilesStorageDir(filename);
return path.join(global.__storage_dir, storageDir);
};