From 69a771a0cbcc1723c20a073ec3663ac486e21a9e Mon Sep 17 00:00:00 2001 From: jhc Date: Mon, 12 May 2025 15:28:55 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkg/router/router.go | 2 +- pkg/service/bundle/bundleOrder.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/router/router.go b/pkg/router/router.go index d2aa0f1..0e53fcb 100644 --- a/pkg/router/router.go +++ b/pkg/router/router.go @@ -103,7 +103,7 @@ func NewRouter() *gin.Engine { } //้™ๆ€ๆ–‡ไปถ - r.StaticFS("/static", http.Dir("./runtime")) + r.StaticFS("/api/static", http.Dir("./runtime")) r.NoRoute(func(c *gin.Context) { c.JSON(http.StatusNotFound, gin.H{ "status": 1, diff --git a/pkg/service/bundle/bundleOrder.go b/pkg/service/bundle/bundleOrder.go index e691d7c..6ddde62 100644 --- a/pkg/service/bundle/bundleOrder.go +++ b/pkg/service/bundle/bundleOrder.go @@ -426,7 +426,7 @@ func ExportOrderInfo(c *gin.Context) { } } - var exportUrl = strings.Replace(strings.Replace(filePath, ".", fmt.Sprintf("%s://%s", httpType, c.Request.Host), 1), "runtime", "static", 1) + var exportUrl = strings.Replace(strings.Replace(filePath, ".", fmt.Sprintf("%s://%s", httpType, c.Request.Host), 1), "runtime", "api/static", 1) //var exportUrl = fmt.Sprintf("%s%s/%s", httpType, c.Request.Host, dirPath + path) fmt.Println("exportUrl : ", exportUrl) service.Success(c, &bundleModel.ExportResponse{ExportUrl: exportUrl})