From 6bbb78e871db4845a92bbfa80d93e19b4566f40b Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Wed, 18 Dec 2024 10:03:59 +0800 Subject: [PATCH] =?UTF-8?q?style:=20=E6=96=87=E4=BB=B6=E4=B8=8A=E4=BC=A0ur?= =?UTF-8?q?l=E5=9C=B0=E5=9D=80=E7=94=A8//=E8=A1=A8=E7=A4=BA=E4=B8=8D?= =?UTF-8?q?=E5=B8=A6=E5=8D=8F=E8=AE=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/common/controller/file.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/common/controller/file.go b/src/modules/common/controller/file.go index 6dc67b7d..0b1391b3 100644 --- a/src/modules/common/controller/file.go +++ b/src/modules/common/controller/file.go @@ -95,7 +95,7 @@ func (s *FileController) Upload(c *gin.Context) { newFileName := upFilePath[strings.LastIndex(upFilePath, "/")+1:] c.JSON(200, result.OkData(map[string]string{ - "url": "http://" + c.Request.Host + upFilePath, + "url": "//" + c.Request.Host + upFilePath, "fileName": upFilePath, "newFileName": newFileName, "originalFileName": formFile.Filename, @@ -160,7 +160,7 @@ func (s *FileController) ChunkMerge(c *gin.Context) { newFileName := mergeFilePath[strings.LastIndex(mergeFilePath, "/")+1:] c.JSON(200, result.OkData(map[string]string{ - "url": "http://" + c.Request.Host + mergeFilePath, + "url": "//" + c.Request.Host + mergeFilePath, "fileName": mergeFilePath, "newFileName": newFileName, "originalFileName": body.FileName,