(c *gin.Context)
| 58 | } |
| 59 | |
| 60 | func ToIndexHtml(c *gin.Context) { |
| 61 | c.Writer.Header().Set("Content-Type", "text/html; charset=utf-8") |
| 62 | c.Writer.WriteHeader(http.StatusOK) |
| 63 | data, err := web.IndexHtml.ReadFile("index.html") |
| 64 | if err != nil { |
| 65 | c.String(http.StatusInternalServerError, "index.html not found") |
| 66 | return |
| 67 | } |
| 68 | _, _ = c.Writer.Write(data) |
| 69 | c.Writer.Flush() |
| 70 | } |
| 71 | |
| 72 | func isEntrancePath(c *gin.Context) bool { |
| 73 | entrance := service.NewIAuthService().GetSecurityEntrance() |
no test coverage detected