download method
Implementation
Future<String> download(int documentId, int fileId,
{Function(int, int)? progress}) async {
final tempDir = await getTemporaryDirectory();
final fullPath = "${tempDir.path}/$fileId";
await dio.download('/attachments/$documentId/$fileId', fullPath,
onReceiveProgress: progress, queryParameters: {});
return fullPath;
}