|
@@ -12,16 +12,11 @@ import (
|
|
|
)
|
|
|
|
|
|
func Upload(r *GinRouter) {
|
|
|
- r.POST("/upload/pkg", UploadPkg)
|
|
|
+ r.POSTJWT("/upload/pkg", UploadPkg)
|
|
|
}
|
|
|
|
|
|
var LocalHost = "http://localhost:8085/cr/pkg"
|
|
|
|
|
|
-// type UploadReq struct {
|
|
|
-// Version string
|
|
|
-// Name string
|
|
|
-// }
|
|
|
-
|
|
|
func UploadPkg(c *gin.Context, apictx *ApiSession) (interface{}, error) {
|
|
|
|
|
|
version := c.PostForm("version")
|