fix:合图调整

This commit is contained in:
momo
2023-09-19 14:55:26 +08:00
161 changed files with 4621 additions and 1502 deletions

1
server/upload/.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
upload

View File

@@ -32,7 +32,7 @@ func NewUploadQrcodeLogic(ctx context.Context, svcCtx *svc.ServiceContext) *Uplo
func (l *UploadQrcodeLogic) UploadQrcode(req *types.UploadQrcodeReq, userinfo *auth.UserInfo) (resp *basic.Response) {
if userinfo.GetIdType() != auth.IDTYPE_User {
return resp.SetStatusWithMessage(basic.CodeServiceErr, "please login first")
return resp.SetStatusWithMessage(basic.CodeServiceErr, "please sign in first")
}
if req.Url == "" {
resp.SetStatus(basic.CodeApiErr, "param url is empty")

View File

@@ -9,6 +9,7 @@ import (
"fusenapi/server/upload/internal/handler"
"fusenapi/server/upload/internal/svc"
"fusenapi/utils/auth"
"fusenapi/utils/fsconfig"
"github.com/zeromicro/go-zero/core/conf"
"github.com/zeromicro/go-zero/rest"
@@ -19,8 +20,9 @@ var configFile = flag.String("f", "etc/upload.yaml", "the config file")
func main() {
flag.Parse()
cfgContent := fsconfig.StartNacosConfig(*configFile, nil)
var c config.Config
conf.MustLoad(*configFile, &c)
conf.LoadConfigFromYamlBytes([]byte(cfgContent), &c)
server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) {