diff --git a/kernel-d-file/file-api/src/main/java/cn/stylefeng/roses/kernel/file/FileInfoApi.java b/kernel-d-file/file-api/src/main/java/cn/stylefeng/roses/kernel/file/FileInfoApi.java index e3e871380..a3436ca7a 100644 --- a/kernel-d-file/file-api/src/main/java/cn/stylefeng/roses/kernel/file/FileInfoApi.java +++ b/kernel-d-file/file-api/src/main/java/cn/stylefeng/roses/kernel/file/FileInfoApi.java @@ -30,4 +30,15 @@ public interface FileInfoApi { */ String getFileAuthUrl(Long fileId); + /** + * 获取文件的下载地址(带鉴权的),生成外网地址 + * + * @param fileId 文件id + * @param token 用户的token + * @return 外部系统可以直接访问的url + * @author fengshuonan + * @date 2020/10/26 10:40 + */ + String getFileAuthUrl(Long fileId, String token); + } diff --git a/kernel-d-file/file-business/src/main/java/cn/stylefeng/roses/kernel/file/modular/service/impl/SysFileInfoServiceImpl.java b/kernel-d-file/file-business/src/main/java/cn/stylefeng/roses/kernel/file/modular/service/impl/SysFileInfoServiceImpl.java index 16578eebd..be8dd5f4c 100644 --- a/kernel-d-file/file-business/src/main/java/cn/stylefeng/roses/kernel/file/modular/service/impl/SysFileInfoServiceImpl.java +++ b/kernel-d-file/file-business/src/main/java/cn/stylefeng/roses/kernel/file/modular/service/impl/SysFileInfoServiceImpl.java @@ -372,6 +372,15 @@ public class SysFileInfoServiceImpl extends ServiceImpl